<!DOCTYPE html>
<html>
<head>
<meta name="viewport"
content="width=device-width, initial-scale=1.0, maximum-scale=1.0" />
<script>
var xmlhttp = new XMLHttpRequest();
function openApp() {
window.location = 'intent://test/#Intent;scheme=externalappscheme;end';
};
function xhrOnReadyStateChange() {
if (xmlhttp.readyState==4 && xmlhttp.status==200) {
setTimeout(openApp, 100);
}
};
function xhrAndOpenApp() {
xmlhttp.onreadystatechange = xhrOnReadyStateChange;
xmlhttp.open("GET", 'hello.html' , true);
xmlhttp.send();
};
</script>
</head>
<body style='height:10000px;' onclick='xhrAndOpenApp();'>
Click page to open App!!
</body>
</html>