This script will open a new
window with the use of a text link or image.
Open
My Window
This script will allow you
to set page size and location of where on the screen it will pop up. You
can also set if you want scroll bars, status bars, menu bar, title bar,
tool bar.
IMPORTANT NOTE: To
be able to open links from the new window in the main window requires a
script in the new or remote window.
The in's and out's
of the remote window script.
Not as difficult as you
think really.
If
you are using frames: Just do the same as you would in normal frames.
( specify your target of the page you want your link to open in.)
EXAMPLE: <a href="yourpage.html"
target="main">YOUR
LINK</a>
If
you are not using frames: This requires a script.
This is it.
Inside
the <head> </head tags put this.
<script>
function remote(url){
window.opener.location=url
}
</script> |
First
thing inside the body tags.
<script>
function chgMainWinLoc( strPage ) {
parent.opener.document.location = strPage;
}
</script> |
and
lastly the link .
instead of your normal url,
replace it with this.
javascript:
chgMainWinLoc( 'your-page.html' )
EXAMPLE: <a href="javascript:
chgMainWinLoc( 'your-page.html' )">Your Link</A>
Change "your-page.html" to
the page you want open.
|