• Page 3 of 3
  • «
  • 1
  • 2
  • 3
Forum moderator: bigblog  
uCoz Community » For Webmasters » Custom Solutions » How to Make Custom Path Redirection for Various Modules (A 7-step short tutorial.)
How to Make Custom Path Redirection for Various Modules
CoffeeCone
Posts: 687
Reputation: 41

Message # 1 | 8:04 AM
Have you ever had that certain instance where you want http://your-ucoz-site.com/stuff to also be accessible via http://your-ucoz-site.com/onlinegames? Well good news, here's a tutorial that will help you add redirections to virtually any URL you want. Be it inside your website or to external links, e.g.; http://your-ucoz-site.com/facebook will redirect users to http://www.facebook.com/your-ucoz-site-page.

Things you'll need:
- Any plain text editor. (You can't use Microsoft Word or any rich text editor.)
- Access to your uCoz website's File Manager.

Things to do:
1. Open up your text editor (e.g. notepad) and type or copy the code below.

Quote
<html>
<head><title>Redirecting...</title></head>
<meta http-equiv="refresh" content="1;url=http://your-new-url/">
<body>
<p>Please wait while you are redirected...</p>
<script>window.location.replace('http://your-new-url/');</script>
</body>
</html>

On the code above, replace http://your-new-url/ with the one you want.

2. Save your file to index.html.

3. On your website's File Manager, create a new folder name it whatever you want, e.g.; onlinegames.

4. Inside your newly created folder, upload your index.html file.

5. Make sure that the file is named index.html.

6. Test out your new url redirection by visiting http://your-ucoz-site/yournewfolder.

7. If you followed everything correctly that should work and you will be redirected to the URL you specified.

This concludes this simple set of instructions on how to set up redirection on your uCoz website.

Conclusion:
You probably already knew how the above tutorial would work. You might just have overlooked it. smile

Demo Video
For those of you having trouble following the instructions above, here's a quick video demo on how to do it.


"Friends don't let friends use Internet Explorer 6." - Microsoft || Join the cause. Help your friends.


Post edited by shadowslash - Wednesday, 2011-02-23, 6:21 AM
Datecity
Posts: 40
Reputation: 0

Message # 31 | 7:03 PM
CoffeeCone, did you first test this code?

Code
<html>
<head><title>Redirecting...</title></head>
<meta http-equiv="refresh" content="1;url=http://your-new-url/">
<body>
<p>Please wait while you are redirected...</p>
<script>window.location.replace('http://your-new-url/');</script>
</body>
</html>


The right code should be

Code
<html>
<head><title>Redirecting...</title></head>
<meta http-equiv="refresh" content="1;url=your-new-url/">
<body>
<p>Please wait while you are redirected...</p>
<script>window.location.replace('/your-new-url/');</script>
</body>
</html>


The http:// prefix should not be included plus the site address eg http://ucoz.com/forum you exclude http://ucoz.com and include only /forum.
joexyz
JOE-vascript
Posts: 1737
Reputation: 78

Message # 32 | 7:14 PM
Datecity, there is nothing wrong with the original code. Also, you're replying to an ages old thread, this solution isn't even relevant anymore since the SEO module allows you to have total control over the links on your site.
hey i'm joe and i do not work for the company anymore, sorry for the late replies
icon by ch-chau

I'm still here for some godforsaken reason
uCoz Community » For Webmasters » Custom Solutions » How to Make Custom Path Redirection for Various Modules (A 7-step short tutorial.)
  • Page 3 of 3
  • «
  • 1
  • 2
  • 3
Search: