Click to See Complete Forum and Search --> : URL Masking?


Jick
08-30-2003, 12:23 AM
Hi guys I'm back. I have a quick question. Ok so I have this site with a link for example like this:

http://www.host123.home.com/media/mysite/mypage.html

And I registered a domain for example:

http://www.mysite.com/

When ever I go to my "mysite.com" site it redirects but it also shows the long link in my address bar. I want to make it so when I go to my "mysite.com" it will show "mysite.com". I have heared of a thing called URL Masking. I wanted to know if someone could please provide me with the required code to make this thing called URL Masking work on my site so it always shows "mysite.com". Thanks. :D

Da Warriah
08-30-2003, 08:50 AM
i believe that people usually use frames to do this (tho if theres a method using PHP, id really like to know ;) ), what you do is make your main frameset page your index page (at mysite.com), and then put in a frame that targets your actual page that you want to show...

GavinPearce
08-30-2003, 09:56 AM
normally the company you brought your domain name from willl do it for you

Jick
08-30-2003, 10:14 PM
I had someone give me this code which they said will work if you insert it on every page of your website:
<script TYPE="text/javascript">
<!--
if (parent.location.href == self.location.href)

{
if (window.location.replace)
{
window.location.replace('http://www.kr1st.com/index.htm');
}
else
{
window.location.href = 'http://www.kr1st.com/index.htm';
}
}
// -->

And also insert this code too:
< BASE HREF="http://www.kr1st.com/">
If someone could reccomend a better code in php or just convert this code to php for me I would greatly appreciate it! The resin I want to convert it is so it will work for users with javascript disabled. :D

Jick
09-01-2003, 12:02 PM
I have been looking all over places such as hotscripts but have found no such script. So either this is not possible with php or I'm just not looking in the right places. Can someone please help me out here? I really need this script because the domain registar that I'm using is cheap but also dosn't have masking avalible. From the look of this thred I think who ever were to help me would also be helping some other people who need something like this too. Thank you very much to who ever is kind enough to help me solve this problem that has me very confused. :(