Support Forums

Full Version: Making default domain redirect to forums
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
Okay so I have a host and a domain, but my forums are located at www.domain.com/forums, however obviously www.domain.com will direct to my default index page. Since I'm not done with my index page how can I make it redirect to www.domain.com/forums?

Thanks.
You can do it with PHP
Code:
header("Location: forums/index.php");
Quote:<html>
<script>
location = "http://www.paulpotts.com.au";
</script>
</html>

Source: http://inspiredesign.com.au/Redirect-Script
Weird... when I go to http://www.domain.com/index.html the redirect works, but when I go to http://www.domain.com it doesn't..

Anyone know what to do?
(10-05-2009, 08:13 PM)Jake Wrote: [ -> ]Weird... when I go to http://www.domain.com/index.html the redirect works, but when I go to http://www.domain.com it doesn't..

Anyone know what to do?

post up the source...

and try putting the redirect command into a function and then call it on body load
Code:
<body onload="function()">
Well, sorry I don't really know PHP.. I'm just trying to make a simple redirect.

Can someone just post a code snippet of a full index.html page that simply redirects?

Thanks.
(10-05-2009, 08:22 PM)Jake Wrote: [ -> ]Well, sorry I don't really know PHP.. I'm just trying to make a simple redirect.

Can someone just post a code snippet of a full index.html page that simply redirects?

Thanks.

Code:
<?php
header("Location: http://yourdomain.com/forums/index.php");
?>

save the above as index.php and change the path after "Location:" to the one you want it to redirect
Edit: got it working. Thanks.
(10-05-2009, 08:26 PM)Jake Wrote: [ -> ]Edit: got it working. Thanks.

no problem man if you have any questions about php/javascript/html/css I'm here for you..

ps:
Thank you Blackhat
Pages: 1 2