Computers |
|
| | #3 (permalink) |
| Monster Techie | If you don't want to use the "refresh"...here's some other ways... with PHP: <?php header("Location: index.html"); ?> or <?php header("Location: http://wwwyoursite.com/index.html"); ?> note: must be BEFORE any <html> statements are called with Java Script: put in your HEAD tag... <SCRIPT LANGUAGE="JavaScript"> window.location="http://www.yourdomain.com/"; </script> OR put this in your body tag... <SCRIPT LANGUAGE="JavaScript"> <!-- location.replace("http://www.yahoo.com"); --> </script> or if you want to redirect after a specified time: Redirect After Specified Time: **************Place in HEAD tag************** <script language="JavaScript"> <!--hide from old browsers var time = null function move() { window.location = 'http://www.yourdomain.com' } //--> </script> **************Place in BODY tag************** <body onload="timer=setTimeout('move()',2000)"> note: 2000 = 2 seconds...change it to whatever you want. All of those work ![]() |
| | |
| | #5 (permalink) |
| Monster Techie Join Date: Jul 2004 Location: Manchester, UK
Posts: 1,910
| a very simple 1 line code in javascript that is: <script language="javascript" type="text/javascript"> window.location="www.google.com" </script> and you are done, you can as well mention ur own file, like "mypage.html" instead of www.google.com
__________________ AMD Athlon X2 4400+ (Toledo) Asus A8V Deluxe E-VGA 7800GS 256MB AGP 4 X 512MB DDR400 Kingston Value 2 X 160 ATA133 H/D 2 X DVD Drives Antec Sonata II (with 480W PSU) 21.3" Viewsonic VP211b TFT. |
| | |