Register

If this is your first visit, please click the Sign Up now button to begin the process of creating your account so you can begin posting on our forums! The Sign Up process will only take up about a minute of two of your time.

Results 1 to 5 of 5
  1. #1
    Junior Member
    Join Date
    Feb 2003
    Posts
    11
    Member #
    626
    Anyone know of a way to change the background color of a table field using mouseovers, but NOT using Javascript? I tried:

    Code:
    <TD class="tableField" onMouseOver="bgcolor:#FF0000">My Stuff</TD>
    ... but it didn't do anything. Any ideas?

    - skubik.

  2.  

  3. #2
    Senior Member filburt1's Avatar
    Join Date
    Jul 2002
    Location
    Maryland, US
    Posts
    11,774
    Member #
    3
    Liked
    21 times
    I don't believe there's any way to do it on a mouseover other than Javascript (or VBScript).
    filburt1, Web Design Forums.net founder
    Site of the Month contest: submit your site or vote for the winner!

  4. #3
    Junior Member
    Join Date
    Feb 2003
    Posts
    11
    Member #
    626
    Hmmm, well then, what would be the easiest way to do it in Javascript WITHOUT writing an entire function and calling it. I thought the code in my initial post would do it, but it didn't for some reason.

    - skubik.

  5. #4
    Senior Member filburt1's Avatar
    Join Date
    Jul 2002
    Location
    Maryland, US
    Posts
    11,774
    Member #
    3
    Liked
    21 times
    Code:
    onMouseOver="cellname.style.backgroundColor = 'whatever'
    ...and the same for onMouseOut, only a different color. That only works in IE, though.
    filburt1, Web Design Forums.net founder
    Site of the Month contest: submit your site or vote for the winner!

  6. #5
    WDF Staff smoseley's Avatar
    Join Date
    Mar 2003
    Location
    Boston, MA
    Posts
    9,729
    Member #
    819
    Liked
    205 times
    for IE and NS:
    Code:
    <td class="tableField" onmouseover="this.style.backgroundColor='#000000';" onmouseout="this.style.backgroundColor='#FFFFFF';">My Stuff</td>
    even better, you can change the CLASS on mouse event:
    Code:
    <td class="tableField" onmouseover="this.className='tableFieldOver';" onmouseover="this.className='tableField';">My Stuff</td>


Remove Ads

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
All times are GMT -6. The time now is 05:16 PM.
Powered by vBulletin® Version 4.2.3
Copyright © 2019 vBulletin Solutions, Inc. All rights reserved.
vBulletin Skin By: PurevB.com