RE: FN-FORUM: Position of pup-up
date posted 9th March 2003 09:50
Sure,
Good script I have.
function openWindow(theURL,winName,features, myWidth, myHeight, =
isCenter) {=20
if(window.screen)if(isCenter)if(isCenter=3D=3D"true"){
var myLeft =3D (screen.width-myWidth)/2;
var myTop =3D (screen.height-myHeight)/2;
features+=3D(features!=3D'')?',':'';
features+=3D',left=3D'+myLeft+',top=3D'+myTop;
}
=20
window.open(theURL,winName,features+((features!=3D'')?',':'')+'width=3D'+=
myWidth
+',height=3D'+myHeight)=20
return
}
Put the above in the header.
onClick=3D"openWindow(this.href,'_NewWin','scrollbars=3Dyes,resizable=3Dn=
o,status=3D
no','450','300','true');return false"
And the above on any link and it will open it in a popup. You can =
probably
work out most of the settings in the onClick but the true var sets if it
should be centred or not.
Regards=20
=20
Sam Morgan=20
=20
WIREDEYES=20
t : 0845 644 6568 (Local Rate)=20
f : 0871 433 2278 (10p per min)=20
e : [EMAIL REMOVED]
w : http://www.wiredeyes.com=20
----=20
umop ap!sdn w,! aw dlaH=20
> -----Original Message-----
> From: [EMAIL REMOVED]
> [EMAIL REMOVED] On Behalf Of Kerry K-C
> Sent: 09 March 2003 08:01
> To: FN-FORUM / [EMAIL REMOVED]
> Subject: FN-FORUM: Position of pup-up
>=20
>=20
> I seem to recall this question arising before so I'm hoping=20
> someone out
> there can help.
>=20
> I have 'help' pop-ups opening for a site and I'd like to be=20
> able to have
> them open in a specific position by default (e.g.=20
> centre-screen). Can this
> be done?=20
>=20
> TIA
> Kerry
>=20
>=20
>=20
> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
>