I have a website/CMS - "MySite" - with a World section at MySite/World.
On that page is an index of continents and oceans, each one linked to a
JavaScript pop-up windows that features links to each continent/ocean's
"children" (nations, states, etc.).
Each pop-up features the following JavaSript:
<td style="background: #fcc;">• <a href="javascript:;"
onclick="opener.location='/World/Canada/'">Canada</a></td>
It functions as sort of a remote control. Click on the link and the
pop-up remains unchanged, while the main page - MySite/World - is
forwarded to MySite/World/Canada.
I just learned that the following code accomplishes the same thing:
<input type="button" onClick="window.opener.location='/World/Canada/'">
(Is there a significant difference? In other words, is one code better
than the other?)
Now imagine a second website - MySite2 - that features an identical
World page at MySite2/World. The JavaScript pop-ups aren't just
identical - they're the same. There's just one set of JavaScript pop-ups
- on MySite. The World pages on several other web sites are linked to
these same pop-ups.
The problem is that they don't work cross website; click on a link and
nothing happens. I changed the link from /World/Canada to
http://MySite2/World/Canada,
but it didn't fix anything.
I'm confused, because I could have sworn it did work cross-site at one
time, and I can't figure out what I did to mess it up.
The obvious solution is to copy a set of pop-up windows to each website.
However, I hate to duplicate all those files if I can make a single set
work. Can anyone tell me how to make a JavaScript pop-up window based on
MySite control a page on MySite2?
Thanks.


|