IndianWebPortal.com

Something Different In Linux

Home » Knowledge » Redirect by using php code

Redirect by using php code

Posted by Rishikesh Vispute Categories: Knowledge, PHP

How to redirect index.php page to another url by using php code.

If you want to redirect your index.php page to another URL or page then add the following code in your index.php page.

<?php
header( ‘Location: http://www.domain.com/new_page.html’ ) ;
?>

Note : Replace “http://www.domain.com/new_page.html” with exact URL on which you want to redirect you index page .


Popular Posts

remove index.php fro

How to remove index.php from url in magento Ans : If you ...

PHP-Java bridge on p

  What is php-java bridge? The php-java bridge is the php ...

Set expiration for y

If you want to set the expiration to your site ...

Warning: Parameter 1

Error: Warning: Parameter 1 to modMainMenuHelper::buildXML() expected to be a ...

domain pointing to e

If you domain uses external MX record and it is ...