<?include("includes/common.php");?><html><head></head><body><buttonid="install"> Install Domotika GUI on homescreen</button><script>(function(){functioninstall(ev){ev.preventDefault();// define the manifest URLvarport="";if(document.location.port)varport=":"+document.location.port;varmanifest_url=document.location.protocol+"//"+document.location.host+port+"<?=str_replace("/install.php","",$BASEGUIPATH)?>/manifest.webapp";// install the appvarmyapp=navigator.mozApps.install(manifest_url);myapp.onsuccess=function(data){// App is installed, remove button//this.parentNode.removeChild(this);console.log(this);};myapp.onerror=function(){// App wasn't installed, info is in this.error.nameconsole.log('Install failed, error: '+this.error.name);};};// get a reference to the button and call install() on clickvarbutton=document.getElementById('install');button.addEventListener('click',install,false);})();</script></body></html>