Redirects - Printable Version +- SEO MotionZ Forum (https://seomotionz.com) +-- Forum: Digital Workplace (https://seomotionz.com/forumdisplay.php?fid=10) +--- Forum: Blog Management & Promotion (https://seomotionz.com/forumdisplay.php?fid=26) +--- Thread: Redirects (/showthread.php?tid=2203) |
Redirects - danni - 02-23-2017 Here are some common redirects that are used almost often my webmasters and site owners. So, decided to provide the codes of them. PHP Single Page Redirect You have to insert this code in index.php file. Quote:<?php PHP Canonical Redirect This add or removes the 'www' prefix of your domain. Quote:<?php .htaccess Singe Page Redirect Insert this code in your .htaccess file Quote:Redirect 301 /old/oldpage.htm /new/http://www.domain.com/newpage.htm .htaccess Canonical Redirect Quote:Options +FollowSymlinks Re: Redirects - bpatel - 02-25-2017 Nice post and thanks. I needed the .htaccess updates. Re: Redirects - adam_jones - 02-28-2017 Great information about redirects.Thanks. Re: Redirects - richardmsmith - 07-06-2018 Thanks for sharing redirects code in php. Please share types of redirects in php or how many way can we write code for redirects. |