To create a url redirect with a simple php script.
1. Go into the directory where you want to place the redirect. (Normally your html folder)
2. Create index.php file
3. Edit the file with whatever text editor you prefer. (I use nano, as i find it easier to use)
4. Use the script below. Of course change the URL to wherever you want it to go.
<?php //* This is this basic code needs for a url redirect * // header( 'Location: http://google.co.uk/' ) ; ?>
Note: that you will have to use the full URL, if you don’t the redirect will not work
Once you have saved and exited, you will be able to browser to your domain and you will see that you have been redirected to Google UK