Baabu Posted March 4, 2008 Share Posted March 4, 2008 <script> setTimeout("location='index.php'", 3000); // Execute the statement location='index.php' after 3000 miliseconds (3 seconds) </script> well how can i put $url="http://www.somesite.com" in place of index.php in the above script Link to comment https://forums.phpfreaks.com/topic/94282-how-to-put-a-php-from-variable-in-java/ Share on other sites More sharing options...
aebstract Posted March 4, 2008 Share Posted March 4, 2008 setTimeout("location=$url", 3000); ? Link to comment https://forums.phpfreaks.com/topic/94282-how-to-put-a-php-from-variable-in-java/#findComment-482915 Share on other sites More sharing options...
Baabu Posted March 4, 2008 Author Share Posted March 4, 2008 well this worked but how should i make it work for a php variable <script> $url="http://mysite.com" setTimeout("location=$url", 3000); // Execute the statement location='index.php' after 3000 miliseconds (3 seconds) </script> i want to know how to use it with this form <?php $url="http://mysite.com" ?> <script> setTimeout("location='$url'", 3000); // Execute the statement location='index.php' after 3000 miliseconds (3 seconds) </script> Link to comment https://forums.phpfreaks.com/topic/94282-how-to-put-a-php-from-variable-in-java/#findComment-482926 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.