Go Back   Webmaster Malaysia Forum » Website Design & Development » Website Design

Reply
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
  #1 (permalink)  
Old 21-05-2003, 03:40 AM
Novice Webmaster
 
Join Date: Jan 2002
Posts: 22
Rep Power: 0
kelly001 is on a distinguished road
redirecting users coming from a specific site only?

Is there a way using JavaScript or something to redirect users coming to a page on my site from a specific website? Basically, another site out there has linked an odd page on my site and their users enter my site this way. I'd like to force anyone coming from that specific site and using that link to be redirected to my index page? Is this feasible???

Thanks for your help!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 21-05-2003, 09:19 AM
aiweller's Avatar
Novice Webmaster
 
Join Date: Nov 2002
Posts: 33
Rep Power: 0
aiweller is on a distinguished road
Send a message via ICQ to aiweller
The only thing I can think of right now is to upload a .htaccess file into the directory where the link is. The .htaccess should contain something like DirectoryIndex /
. This would allow any visitors that go to a page that does not exist to be redirected to your main index page.

If you have another index file inside that directory, then you will have to add it into the .htaccess file also. Like, DirectoryIndex / index.html index.php


Another way is to setup a 404 error to redirect to the main page.
__________________
Ashley Weller
Host247.com
KLGlobal.NET
Not Just Ordinary Features

Last edited by aiweller; 21-05-2003 at 10:30 AM.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 21-05-2003, 08:51 PM
Novice Webmaster
 
Join Date: Jan 2002
Posts: 22
Rep Power: 0
kelly001 is on a distinguished road
well, the page they are accessing is not an error page, it's a valid page on the site but they shouldn't be hitting it without going through the entrance of the site.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4 (permalink)  
Old 21-05-2003, 09:39 PM
aiweller's Avatar
Novice Webmaster
 
Join Date: Nov 2002
Posts: 33
Rep Power: 0
aiweller is on a distinguished road
Send a message via ICQ to aiweller
aha... I understand now!! Here's the code for .htaccess to do this;

RewriteEngine On
RewriteCond %{HTTP_REFERER} ^http://www.referingurl.com/
RewriteRule /* http://www.yoursite.com/ [R,L]
__________________
Ashley Weller
Host247.com
KLGlobal.NET
Not Just Ordinary Features
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #5 (permalink)  
Old 21-05-2003, 11:01 PM
Novice Webmaster
 
Join Date: Jan 2002
Posts: 22
Rep Power: 0
kelly001 is on a distinguished road
hey, thanks! I'll try that too. I actually found a work around in the meantime. The site linking us does it within a frameset so I just place a script on my page forcing the page to reload (to my index page) if it originally is loaded from within a frameset. That seems to work fine at least until they stop linking me from within a frameset.

If anyone needs a script like I described try this;

<script>

if (window!= top)
top.location.href=document.location.href = 'index.html';

</script>
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
Zidonline.Net Coming to You zidonline Paid Hosting Discussion Forum 2 02-01-2007 10:11 AM
Streamyx users Ainuddin Mamak Stall 1 01-02-2006 05:13 PM
redirecting rix Website Programming 2 17-06-2004 05:06 PM
A site specially made for malaysian broadband users.. NeoKirana Mamak Stall 9 10-02-2004 11:10 PM
What do you want before New Year's coming? klmc Mamak Stall 1 12-11-2003 05:48 PM



All times are GMT +8. The time now is 07:40 PM. Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO 3.1.0 vBulletin skin by ForumMonkeys.com.


WebmasterMalaysia.com is Proudly Hosted by Exabytes Semi Dedicated Server.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59