P
petev
Hello, can anyone help me out?? Maybe its a bit complicated, maybe not
I'll try to explain. Am not a programmer so have patience!
[SITUATION]
I have a website whose url looks like this:
http://home.provider.nl/~mybusiness/
Shortly I have a registered a domain name:
http://www.mybusiness.nl
.... that is now "hosted" by another provider: the only thing it does is
sending a visitor of www.mybusiness.nl to
http://home.provider.nl/~mybusiness/ (this is called "webforwarding" or
routing)
You don't see that you are sent to the actual URL of my website;
www.mybusiness.nl remains displayed in the URL-bar. This is achieved because
www.mybusiness.nl displays http://home.provider.nl/~mybusiness/ in a frame:
<HTML>
<HEAD>
....
</HEAD>
<FRAMESET CELLPADDING="0" CELLSPACING="0" BORDER="0" ROWS="100%,*">
<FRAME SRC="http://home.provider.nl/~mybusiness/" NAME="qwerty" NORESIZE
SCROLLING="AUTO">
<FRAME SRC="/empty.html" NORESIZE>
</FRAMESET>
</HTML>
Because my site also has frames, I had to change all "target=_top" to
"target=qwerty" to make internal navigation work correctly while being at
www.mybusiness.nl . That was no problem.
[2 - PROBLEM]
My problem is to rewrite the javascript I made (well.. the usual
copy/paste/adapt actions) for all content pages. When found by a search
engine and clicked, the correct frames are forced around that "orphaned"
page. It works as long as you navigate at
http://home.provider.nl/~mybusiness/ (not via www.mybusiness.nl ).
NOW I guess the script needs to send you first to www.mybusiness.nl and THEN
force the found page+parent frame(s) in the new "qwerty" top-frame. How the
hell should I do that? A tried some things, but cant get it right.
The javascript I have now and needs to be changed looks like this (with
onLoad="framecheck()" in body tag) :
<SCRIPT LANGUAGE="JavaScript">
<!--
function framecheck()
{var parentframe = 'page.html';
// check if orphan
if (parent.location.href == self.location.href)
{var current = window.self.location.pathname;
window.location.replace (parentframe + '?' + current);
}
};
//-->
</SCRIPT>
Anyone an idea how to change it??
Many thnx in andvance for any suggestion..
PV
I'll try to explain. Am not a programmer so have patience!
[SITUATION]
I have a website whose url looks like this:
http://home.provider.nl/~mybusiness/
Shortly I have a registered a domain name:
http://www.mybusiness.nl
.... that is now "hosted" by another provider: the only thing it does is
sending a visitor of www.mybusiness.nl to
http://home.provider.nl/~mybusiness/ (this is called "webforwarding" or
routing)
You don't see that you are sent to the actual URL of my website;
www.mybusiness.nl remains displayed in the URL-bar. This is achieved because
www.mybusiness.nl displays http://home.provider.nl/~mybusiness/ in a frame:
<HTML>
<HEAD>
....
</HEAD>
<FRAMESET CELLPADDING="0" CELLSPACING="0" BORDER="0" ROWS="100%,*">
<FRAME SRC="http://home.provider.nl/~mybusiness/" NAME="qwerty" NORESIZE
SCROLLING="AUTO">
<FRAME SRC="/empty.html" NORESIZE>
</FRAMESET>
</HTML>
Because my site also has frames, I had to change all "target=_top" to
"target=qwerty" to make internal navigation work correctly while being at
www.mybusiness.nl . That was no problem.
[2 - PROBLEM]
My problem is to rewrite the javascript I made (well.. the usual
copy/paste/adapt actions) for all content pages. When found by a search
engine and clicked, the correct frames are forced around that "orphaned"
page. It works as long as you navigate at
http://home.provider.nl/~mybusiness/ (not via www.mybusiness.nl ).
NOW I guess the script needs to send you first to www.mybusiness.nl and THEN
force the found page+parent frame(s) in the new "qwerty" top-frame. How the
hell should I do that? A tried some things, but cant get it right.
The javascript I have now and needs to be changed looks like this (with
onLoad="framecheck()" in body tag) :
<SCRIPT LANGUAGE="JavaScript">
<!--
function framecheck()
{var parentframe = 'page.html';
// check if orphan
if (parent.location.href == self.location.href)
{var current = window.self.location.pathname;
window.location.replace (parentframe + '?' + current);
}
};
//-->
</SCRIPT>
Anyone an idea how to change it??
Many thnx in andvance for any suggestion..
PV