View Feed
group-icon
PHP Programmers
Community for PHP Programmers : Ask questions, doubts and help each other get better at PHP
222 Members
Join this group to post and comment.
pankaj.sharma
pankaj.sharma • Mar 18, 2008

PHP URL Redirect

Hi Kidakaka,

Do you have any idea about website URL redirect when the website is in PHP
Prasad Ajinkya
Prasad Ajinkya • Mar 18, 2008
Re: Good resources for programmers

Yeah .. sure.. when you are redirecting .. change the locations in the header section .. also ensure that the redirection is done before the HTML header files are sent .. ie before you output any HTML content on the page, you need to do your redirections.
Prasad Ajinkya
Prasad Ajinkya • Mar 19, 2008
Re: Good resources for programmers

Here is the sample script -
and heres where i copied it from PHP Redirect - Redirect Script - Redirect Web Page
header( 'Location: https://www.yoursite.com/new_page.html' ) ;
?>
bayazidahmed
bayazidahmed • Mar 19, 2008
You ma also use http_redirect() if you have PECL extension installed.

Share this content on your social channels -