-
Notifications
You must be signed in to change notification settings - Fork 0
/
survey.html
31 lines (26 loc) · 917 Bytes
/
survey.html
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
<html>
<head>
<title>Survey</title>
<script type="text/javascript" src="//test-ads.klickpush.com:3030/preview/2.js"></script>
</head>
<body>
<input id="email" type="text"></input>
Provide your email address and click <a id="submit" href="/success.html?email=__EMAIL__">here</a>
</body>
<script type="text/javascript">
function sender(){
var tmp_email = document.getElementById('email').value;
if(tmp_email.length > 0){
console.log('long enough')
var tmp_submit = document.getElementById('submit');
tmp_submit.href = tmp_submit.href.replace('__EMAIL__', encodeURIComponent(tmp_email));
}
}
var tmp_submit = document.getElementById('submit');
if (tmp_submit.addEventListener) {
tmp_submit.addEventListener('click', sender, false);
} else {
tmp_submit.attachEvent('onclick', sender);
}
</script>
</html>