Zaloguj | Zarejestruj | FAQ
Anonymous

Problem with Redirect to anther page or web site

+ Odpowiedz

Posty: 2 Strona 1 z 1


Problem with Redirect to anther page or web site

przez annyphp » Pn maja 23, 2011 10:02 am

Tutorial on PHP redirect to be redirected to anther page or web site.
For this tutorial lets suppose you have moved your web site to another domain and want your visitors to be redirected to your new domain you can use PHP for this purpose.
Here is the code to redirect a user:
<?php>
header ('Location: 'http://www.daveismyname.co.uk');
?>
Here's a breakdown of the code.
The<?php tells the browser to expect to receive php.
header('Location:'http://www.daveismyname.co.uk'); tells the browser to redirect to the address given in the code and ?> tells the browser to finishi expecting PHP.
More free php redirection scripts you can check out the page!
Avatar użytkownika

annyphp

  • Posty: 5
  • Dołączył(a): Cz gru 02, 2010 12:39 am

Re: Problem with Redirect to anther page or web site

przez HTML.net » Pn maja 23, 2011 11:11 am

Thanks for the tutorial and link. But please respect in future that the forums are for questions and discussions regarding web development - not for promotion of websites.

But you are of couse welcome to answer questions / participates in disussion in the forums and then add a signature to you profile with a link to your website.

- Andreas, HTML.net
Avatar użytkownika

HTML.net
Site Admin

  • Posty: 1194
  • Dołączył(a): So wrz 11, 2010 11:24 am
--
Show some love for HTML.net on Twitter, Facebook and Google: Use the buttons on top of all pages.


+ Odpowiedz

Strona 1 z 1