Last active
August 29, 2015 14:05
-
-
Save pdaire/1f71fa7c5d40b3b9350b to your computer and use it in GitHub Desktop.
welcome let's talk
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>Welcome to Let's Talk</title> | |
<style type="text/css"> | |
body { background-color: #fff; color: #666; text-align: center; font-family: arial, sans-serif; } | |
div.dialog { | |
width: 50%; | |
padding: 0 4em; | |
margin: 4em auto 0 auto; | |
border: 1px solid #ccc; | |
border-right-color: #999; | |
border-bottom-color: #999; | |
} | |
h1 { font-size: 100%; color: #f00; line-height: 1.5em; } | |
</style> | |
</head> | |
<body> | |
<!-- This file lives in public/welcome.html --> | |
<div class="dialog"> | |
<h1> | |
Great! Your account is now active. | |
Please <a href="http://letsta.lk" id='go_to_app'>go back to Let's Talk app</a> or wait 5 seconds and we'll do it for you. | |
</h1> | |
</div> | |
</body> | |
<script type="text/javascript"> | |
var isMobile = { | |
Android: function() { | |
return navigator.userAgent.match(/Android/i); | |
}, | |
BlackBerry: function() { | |
return navigator.userAgent.match(/BlackBerry/i); | |
}, | |
iOS: function() { | |
return navigator.userAgent.match(/iPhone|iPad|iPod/i); | |
}, | |
Opera: function() { | |
return navigator.userAgent.match(/Opera Mini/i); | |
}, | |
Windows: function() { | |
return navigator.userAgent.match(/IEMobile/i); | |
}, | |
any: function() { | |
return (isMobile.Android() || isMobile.BlackBerry() || isMobile.iOS() || isMobile.Opera() || isMobile.Windows()); | |
} | |
}; | |
if(isMobile.iOS()){ | |
document.getElementById("go_to_app").href='letstalk://'; | |
else if (isMobile.Android()) { | |
document.getElementById("go_to_app").href='letstalk://register/success'; | |
} | |
setTimeout(function() { | |
window.location.href = document.getElementById("go_to_app").href; | |
}, 5000); | |
</script> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment