Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

<div id="ABname"</div> I need help... 1

Status
Not open for further replies.

e1k4l3cs

MIS
Nov 11, 2002
56
SG
Can someone help explain the following HTML code to me ???<div id=&quot;ABname&quot; style=&quot;visibility:hidden;position:absolute&quot;></div>

Thx...

Kelvin
 
Other than no content between the div tags it's OK. I added some text between the tags and it was hidden. What is your issue?
<div id=&quot;ABname&quot; style=&quot;visibility:hidden;position:absolute&quot;>Some Hidden Text</div>


DeZiner
Never be afraid to try something new.
Remember that amateurs built the Ark.
Professionals built the Titanic
 
Ermmm... I do not understand the codes I mentioned above...
Can explain abit ??? Got example better...

Thanks...

Kelvin
 
Sorry - Missed the part about needing an explanation.

<div id=&quot;ABname&quot; <-- Sets a block with an id that can be referenced in javascript or style tags.style= <-- sets a style to be applied &quot;visibility:hidden;<-- This says make anything in this block hidden (not visible on the screen)position:absolute&quot;<--- This sets the position of the block>Some Hidden Text</div>
DeZiner
Never be afraid to try something new.
Remember that amateurs built the Ark.
Professionals built the Titanic
 
Ermm... Can I have some examples... Like in what circumtances will I use such codes ???

Thanks in advance...

Kelvin
 
You will often use that if you want to hide text or do show-hide-mouseover-thingys with javascript. Try this example:

<a href=&quot;#&quot; onmouseover=&quot;document.getElementById('ABname').style.visibility='';&quot; onmouseout=&quot;document.getElementById('ABname').style.visibility='hidden';&quot;></a>

<div id=&quot;ABname&quot; style=&quot;visibility:hidden;position:absolute&quot;>Some Hidden Text</div>

Rick
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top