|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
onMouseOver CSS command: add a border via JS
How to I impliment a JS CSS command to include a border around "TEXT" (margin: 0px; border: solid 1px #00F7FF) WITHIN the following line, during the onMouseover:
<div Id="menuItem2_1" onMouseOver="JS CODE FOR BORDER">TEST</div> I can't add an <a> class because the script code doesn't work properly with it shawn ![]() Last edited by shawn gibson : April 6th, 2002 at 11:15 AM. |
|
#2
|
|||
|
|||
|
<div Id="menuItem2_1" onMouseOver="this.style.cssText='margin: 0px; border: solid 1px #00F7FF'">TEST</div>
|
|
#3
|
|||
|
|||
|
<style type="text/css">
.menudef { position: relative; left : 0px; padding: 1px; border-width: 0px; cursor: hand; } .menuOver { position: relative; left: -1px; padding: 1px; border: 1px #00f7ff solid; cursor: hand; } </style> <span id="menuItem2_1" class="menudef" onmouseover="this.className='menuOver'" onmouseout="this.className='menudef'"> TEST</span> |
|
#4
|
|||
|
|||
|
After the first post (thanks!!!), which worked on a single instance, but seemed to need id-ing (from the 'object undefined' I got for the rest of the 3 billion instances), I tried to 'class' the whole thing and put it into a span, and otherwise remove the inline coding (cuz that stuff drives me nuts). Thanks Mr. Feder. I'm sure this will work
![]() I wish I could think abstractly ![]() shawn |
![]() |
| Viewing: Dev Shed Forums > Web Design > CSS Help > onMouseOver CSS command: add a border via JS |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|