- 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
<script type="text/javascript">
$(function(){
(function(win, doc, sdk_url){
if(win.snaptr) return;
var tr=win.snaptr=function(){
tr.handleRequest? tr.handleRequest.apply(tr, arguments):tr.queue.push(arguments);
};
tr.queue = [];
var s='script';
var new_script_section=doc.createElement(s);
new_script_section.async=!0;
new_script_section.src=sdk_url;
var insert_pos=doc.getElementsByTagName(s)[0];
insert_pos.parentNode.insertBefore(new_script_section, insert_pos);
})(window, document, 'https://sc-static.net/scevent.min.js');
(function(){
var request = {
// This is the callback function
onComplete : function(info) {
var $emailInputBox = $('#input-wrapper input[type=text]:eq(0)');
// Use the data returned from the app
if('email' in info) $emailInputBox.val(info['email']);
},
// These are the requested fields (email only)
fields : ['email']
};
snaptr('autofill', request);
})();
});
</script>