...

View Full Version : Popup-Top of page



thickandthin
10-06-2003, 11:33 PM
Hi I want to use this code for a pop-up but I dont want it to go to the top of the page when you click on it thanks

<a href="#" onclick="openSizedWindow('step7.html');"><img src="step7.gif" width="100" height="100" border="0"></a>

beetle
10-07-2003, 06:28 AM
<a href="step7.html" onclick="openSizedWindow(this.href); return false;">
<img src="step7.gif" width="100" height="100" border="0">
</a>

Kor
10-07-2003, 10:33 AM
or



<a href="#" onclick="openSizedWindow('step7.html'); return false;">
<img src="step7.gif" width="100" height="100" border="0">
</a>



which is bassically the same thing. The key role is return false which prevent any scroll movement, as it would have been happen when using a href="#" .

you may use either:



<a href="javascript:void(openSizedWindow('step7.html'); return true;)">
<img src="step7.gif" width="100" height="100" border="0">
</a>



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum