-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
163 lines (151 loc) · 6.9 KB
/
index.html
File metadata and controls
163 lines (151 loc) · 6.9 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<script src="https://cdn.optimizely.com/js/14803270007.js"></script>
<script>
//Segment Code
!function(){var analytics=window.analytics=window.analytics||[];if(!analytics.initialize)if(analytics.invoked)window.console&&console.error&&console.error("Segment snippet included twice.");else{analytics.invoked=!0;analytics.methods=["trackSubmit","trackClick","trackLink","trackForm","pageview","identify","reset","group","track","ready","alias","debug","page","once","off","on"];analytics.factory=function(t){return function(){var e=Array.prototype.slice.call(arguments);e.unshift(t);analytics.push(e);return analytics}};for(var t=0;t<analytics.methods.length;t++){var e=analytics.methods[t];analytics[e]=analytics.factory(e)}analytics.load=function(t,e){var n=document.createElement("script");n.type="text/javascript";n.async=!0;n.src="https://cdn.segment.com/analytics.js/v1/"+t+"/analytics.min.js";var a=document.getElementsByTagName("script")[0];a.parentNode.insertBefore(n,a);analytics._loadOptions=e};analytics.SNIPPET_VERSION="4.1.0";
analytics.load("K04qOslQsPu3fLgUGy8Yv3PE9QOnGMQh");
analytics.page();
}}();
</script>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Questionnaire Page</title>
<meta name="keywords" content="" />
<meta name="description" content="" />
<link href="http://fonts.googleapis.com/css?family=Source+Sans+Pro:200,300,400,600,700,900|Quicksand:400,700|Questrial" rel="stylesheet" />
<link href="default.css" rel="stylesheet" type="text/css" media="all" />
<link href="fonts.css" rel="stylesheet" type="text/css" media="all" />
</head>
<body>
<!-- Google Tag Manager (noscript) -->
<noscript><iframe src="https://www.googletagmanager.com/ns.html?id=GTM-MDZMM3W" height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript>
<!-- End Google Tag Manager (noscript) -->
<div id="header-wrapper">
<div id="header" class="container">
<div id="logo">
<h2>Segment Test Site</h2>
</div>
</div>
</div>
<div id="page-wrapper">
<div id="welcome" class="container">
<form name="travel" class="form label" onsubmit="identify(event); return false">
Name: <br><input name="name" size="80" type="text"/>
<br><br>
Email: <br><input name="email" size="80" type="email"/>
<br><br>
Destination: <br>
<input name="destination" size="80" type="text"/>
<br><br>
<input name="submit" class="button button-small" type="submit" value="submit"/>
</form>
<br><br><br><br>
<form name="travel2" class="form label" onsubmit="track(event); return false">
Name: <br><input name="name" size="75" type="text"/>
<br><br>
Company: <br><input name="company" size="75" type="text"/>
<br><br>
<input name="submit" class="button button-small" type="submit" id="submit" value="submit"/>
<br><br><br><br>
<button class="button button-small" type="button" onclick="myFunction(); return false">Sample Track Event</button>
</form>
<button class="button button-small" type="button" onclick="myFunction2(); return false">Identify User</button>
</div>
</div>
<script type="text/javascript">
function identify(e){
e.preventDefault();
var form = e.target;
var email = form["email"].value;
var name = form["name"].value;
var destination = form["destination"].value;
var user = {
email: email,
name: name,
destination: destination
};
analytics.identify({
email: email,
name: name
});
analytics.track('Destination Inquired', user, function() {
window.location.href = "";
});
}
function track(e){
e.preventDefault();
var submitType = document.getElementById("submit");
var form = e.target;
var name = form["name"].value;
var company = form["company"].value;
var user = {
name: name,
company: company
};
var today = new Date();
var date = today.getFullYear()+(today.getMonth()+1)+today.getDate();
var time = today.getHours()+today.getMinutes()+today.getSeconds();
var dateTime = date+time;
analytics.identify(dateTime, {
name: name
});
analytics.track('Signed Up', user, function() {
window.location.href = "";
});
analytics.track('Form Submitted', {
submissionType: submitType
});
}
function myFunction() {
analytics.track('Product Clicked', {
name: "User Friendly",
color: "10 - Dark Navy Tan Fade Front with Tan Temples",
size: "Average",
lens_type: "Readers",
lens_power: 1.0,
case: "None Selected",
total: "$89.00"
});
}
function myFunction2() {
var userId = '023bkj2131kj2h3125';
analytics.identify(userId, {
email: 'steve@segment.com'
},function(){window.appboy.changeUser(userId);});
}
</script>
<script>window.consentManagerConfig = function(exports) {
var React = exports.React
var bannerContent = ' ' //- requires a non-empty string to load.
var preferencesDialogTitle = 'Cookie Preferences'
var preferencesDialogContent = 'We use data collected by cookies and JavaScript libraries to improve the functionality of the Webflow Dashboard, deliver personalized advertisements, and increase the overall performance of our service.'
var cancelDialogTitle = 'Are you sure you want to cancel?'
var cancelDialogContent = React.createElement(
'span',
null,
'Your preferences have not been saved. By continuing to use our website, you՚re agreeing to our',
' ',
React.createElement(
'a',
{href: '/legal/cookie-policy', target: '_blank'},
'Cookie Policy'
),
'.'
)
var defaultDestinationBehavior = 'imply'
return {
container: '#consent-container',
writeKey: 'K04qOslQsPu3fLgUGy8Yv3PE9QOnGMQh',
shouldRequireConsent: function () { return false; },
bannerContent: bannerContent,
preferencesDialogTitle: preferencesDialogTitle,
preferencesDialogContent: preferencesDialogContent,
cancelDialogTitle: cancelDialogTitle,
cancelDialogContent: cancelDialogContent,
defaultDestinationBehavior: defaultDestinationBehavior
}
}
</script><script src="https://unpkg.com/@segment/consent-manager@1.1.1/standalone/consent-manager.js" crossorigin="anonymous" defer="defer"></script><div id="consent-container"></div></body></html>
</body>
</html>