Page 1 of 1

Fonction "Window Close"

PostPosted: Tue May 04, 2004 4:24 am
by michel_5169
Hello all,
I want to close my PBase window (from my website).
I made this:
<INPUT name="button" TYPE="button" onClick="parent.close()" value="Fermer - Close">
It's OK with that.

But I want this same action with a hypertext link ?
Any idea ?
Thanks !

PostPosted: Tue May 04, 2004 5:31 pm
by lord_of_the_badgers
didn't know you could do that!

well how about trying a graphic, making it the same size as the text.

where did you put this code - how did you get it in the page? (not that I wish to have the same, just curious!)

Re: Fonction "Window Close"

PostPosted: Tue May 04, 2004 8:37 pm
by arjunrc
michel_5169 wrote:Hello all,
I want to close my PBase window (from my website).
I made this:
<INPUT name="button" TYPE="button" onClick="parent.close()" value="Fermer - Close">
It's OK with that.

But I want this same action with a hypertext link ?
Any idea ?
Thanks !


This may work in IE:
<a href="javascript:window.close();">Kill Me</a>

However please note that browser window closing is not a standard operative and will not work in Mozilla as an example.


regds
arjun

PostPosted: Wed May 05, 2004 5:26 am
by michel_5169
I used not "javascript" but only the function.
Thanks for your advised help .
Now, I writed also Alt + F4 in the link.

PS: to "Lord"
I write this line at top of the description (edit gallery)