What is the name of the JavaScript code that on mouseover pops up a pop up window (NOT A NEW WINDOW, BUT A WINDOW WITHIN THE CURRENT WINDOW)? I cannot find it anywhere yet I have seen it done.
Also, would it be possible to echo things inside this pop up?
Thanks,
Jared
PHP/JavaScript Question
Moderator: General Moderators
-
thefreebielife
- Forum Contributor
- Posts: 126
- Joined: Thu Apr 26, 2007 2:59 pm
Its not a single code.
Most of the time it is a hidden(visibility=hidden) <div>, then onclick it would simply set the style of the div to visible.
Now with this div you can do anything you want, make its position absolute, make it blue, width of 40% etc etc and put any images/text in it.
Most of the time it is a hidden(visibility=hidden) <div>, then onclick it would simply set the style of the div to visible.
Code: Select all
<div style="visibility:hidden" id="hiddendiv"> Hello World</div>
<a href="javascript:void(0)" onclick="document.getElementById('hiddendiv').style.visibility=(document.getElementById('hiddendiv').style.visibility=='hidden')? 'visible' : 'hidden';">Show/Hide</a>