-
is there a way to make any link that would leave a site open a new window, this is in reference to links that make the current browser window go to there site. this refers to a window that I don't know what the target will be.
-
Senior Member
I kind of half understand what you are saying. Looks like a simple question though.
Could you describe it a little better?
thanks
mg33
-
FK Catwoman
hi i think i know what you mean - you want to have a pop window when you click on the link -- you can do that with Javascript
here is the code just copy the coding into the HEAD of your HTML document and add the last code into the BODY of your HTML document -->
----------
This will opens a new popup window centered on the page according to the width and height of the user's screen. You can customize the width, height, and scrollbars on or off for each window you open -- Feel free to edit it!
----------
<!-- STEP ONE: Paste this code into the HEAD of your HTML document -->
<HEAD>
<SCRIPT LANGUAGE="JavaScript">
p://javascript.internet.com --><!-- Begin
function NewWindow(mypage, myname, w, h, scroll) {
var winl = (screen.width - w) / 2;
var wint = (screen.height - h) / 2;
winprops = 'height='+h+',width='+w+',top='+wint+',left='+winl +',scrollbars='+scroll+',resizable'
win = window.open(mypage, myname, winprops)
if (parseInt(navigator.appVersion) >= 4) { win.window.focus(); }
}
// End -->
</script>
</HEAD>
<!-- STEP TWO: Copy this code into the BODY of your HTML document -->
<BODY>
<!-- Put the URL inside the link's href="..." section, then carefully -->
<!-- change 'name' to a name for your popup window. The last three -->
<!-- items represent the popup window width, height, and scrollbars. -->
<a href="http://www.yahoo.com/" onclick="NewWindow(this.href,'name','400','400','y es');return false;">Popup Yahoo.com</a>
<p><center>
<font face="arial, helvetica" size="-2">Free JavaScripts provided<br>
by <a href="http://javascriptsource.com">The JavaScript Source</a></font>
</center><p>
this will give you centered pop windows that you can minipulate by editing the scipt (you 'll need to specify x_ and y_ positions for that)
Good luck - if you have any more qs I'd suggest that you post them in the Scripting & Backend forum
Cheers
A
[Edited by Aria on 12-24-2000 at 09:49 PM]
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|