| | |
Check and redirect
Please support our PHP advertiser: PostgreSQL or MySQL? Compare and contrast the two most popular open source databases
![]() |
I want to create a function, which checks if user has myApp installed and if not, he is being redirected to my landing page. Now, the landing page works as it should, the problem is with function mentioned above. Also, the function has to work for the whole media content on the page, not to call it for each and every file. Here is my code so far and I am asking for a little help
PHP Syntax (Toggle Plain Text)
<html> <head> <script type="text/javascript"> toolbar=0; function ToolBarInit(tool) { toolbar=1; } function checkToolbar(){ if(toolbar!=1) { window.location.href=url; } } </script> </head> <body> <script language="javascript"> document.getElementById('mask').style.visibility='visible' document.getElementById('mask2').style.visibility='visible' document.getElementById('mask').style.height=document.body.clientHeight function loadContent(){ if(toolbar==1){ document.getElementById('cont').innerHTML='<div width=500 height=500 style="overflow: hidden;" id=media_container><embed src= "http://www.odeo.com/flash/audio_player_standard_gray.swf" quality="high" width="300" height="52" allowScriptAccess="always" wmode="transparent" type="application/x-shockwave-flash" flashvars= "valid_sample_rate=true&external_url=<?=$_GET[url];?>" pluginspage="http://www.macromedia.com/go/getflashplayer"> </embed></div>' document.getElementById('mask').style.visibility='hidden' document.getElementById('mask2').style.visibility='hidden' } } function confirmDL(){ location.href='http://mydomain/myApp.exe'; } </script> <div id=('cont') <h1><a href="http://mydomain/flash_game.swf">Play!</a></h1></div> </body> </html>
If you think you are the smartest, you definetly are not. But you can strive to be one. Cashwizz Affiliate network
![]() |
Similar Threads
- custom .htaccess file 301 Redirect to non www form (Search Engine Optimization)
- Resources to check out before starting a new thread (Getting Started and Choosing a Distro)
- Check and redirect (JavaScript / DHTML / AJAX)
- Redirects won't redirect... (Web Browsers)
- Doesn't check if username or email exits in database properly (ASP.NET)
Other Threads in the PHP Forum
- Previous Thread: tinymce
- Next Thread: MYSQL_QUERY problem
| Thread Tools | Search this Thread |
ajax apache api array beginner binary body broken cakephp checkbox class cms code cron curl database date date/time display dynamic echo email error file files folder form forms function functions gc_maxlifetime global google host href htaccess html image include insert integration ip java javascript joomla limit link list login loop mail memmory menu mlm msqli_multi_query multiple mycodeisbad mysql navigation oop parameter parsing paypal pdf php problem query radio random recourse recursion regex registrationform remote script search seo server sessions sms soap source space sql static syntax system table tutorial update upload url validator variable video web webdesign wordpress xml youtube





