PDA

View Full Version : Easing Popup windows...


vkidv
09-23-2002, 07:05 PM
say i wanted to have more than one pop-up windows in one page, and do not want to define a function to each one....
i think the script might look somthing like this...


function open_mywin(url,height,width) {
window.open(url,height,width)
}


later on in the page... (example)

<a href="javascript:open_mywin(help.htm,200,200)"> Help </a>

basicaly, i want to define each link to create a popup window without making a seperate function for each and every single pop up window i want in my page
im sure ive done this thing wrong:

window.open(url,height,width)

is this supposed do be displayed as a variable?
like:

open_the_window=window.open(url,height,width)

hope you can help
thanx

vkidv
09-23-2002, 07:11 PM
ahhh just what i need, a smiley appears in the middle of the script

its supposed to be like
javascript:open_mywin(url,height,width)


another thing, to hide the onmouseover , when you put your mouse over the link...the status bar would display somthing like:

javascript:open_mywin(url,height,width)

which might scare some visitors...is it possible to apply apply a onMouseOver effect which changes it to somthing i want like:

onMouseover=staus='click here for help'

im not sure, i cant remember....
please help both cases



thanx

edit SMILEY's KEEP APPEARING IN MY CODE ! PLEASE HELP

ACJavascript
09-23-2002, 07:12 PM
instead of (help.htm,200,200) put ('help.html','200','200')
put single quotation marks between each variable..

for the onMouseOver you could do this

function open_mywin(url,height,width) {
window.open(url,height,width)
}
function status(s){
window.status=s
}

<a href="onclick ect..." onMouseOver="status('Help')">



Hope this helps :D:D