Jump to content


Photo

forwarding


  • Please log in to reply
3 replies to this topic

#1 techker

techker
  • Members
  • PipPipPip
  • Advanced Member
  • 748 posts

Posted 31 July 2006 - 06:37 PM

hey guys is there a way to forward a page to another automaticly?

cause the domain name that i got goes to the wrong site(i have 2 )i need to so when it goes to the wrong site it is sent to the good one?



#2 pedrobcabral

pedrobcabral
  • Members
  • PipPipPip
  • Advanced Member
  • 108 posts

Posted 31 July 2006 - 07:03 PM

<?php echo "<script>window.location='http://goodsite.com';</script>"; ?>

#3 SharkBait

SharkBait
  • Members
  • PipPipPip
  • Advanced Member
  • 845 posts
  • LocationMetro Vancouver, BC

Posted 31 July 2006 - 07:04 PM

You can use either a meta refresh.  Forget the exact HTML for it.

Or you can use PHP's header function to move them

<?php
// You can not have any text sent to the screen prior to using header();
header("Location: http://mynewsite.com");
exit();
?>


#4 techker

techker
  • Members
  • PipPipPip
  • Advanced Member
  • 748 posts

Posted 31 July 2006 - 07:20 PM

<?php echo "<script>window.location='http://goodsite.com';</script>"; ?>


thx bro works great.




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users