mouseover - how to...

Discussion in 'Javascript' started by Bad_Kid, Jul 1, 2004.

  1. Bad_Kid

    Bad_Kid Guest

    I have text (in table cell) and 1 picture (in other table cell)
    is there a javascript that does this: when i move mouse over that cell with
    text -> picture get border (or some other effect, picture resizes, ...)??
    thnx!
     
    Bad_Kid, Jul 1, 2004
    #1
    1. Advertising

  2. Bad_Kid

    Ivo Guest

    "Bad_Kid" <> wrote in message
    news:cc0u88$nbd$...
    > I have text (in table cell) and 1 picture (in other table cell)
    > is there a javascript that does this: when i move mouse over that cell

    with
    > text -> picture get border (or some other effect, picture resizes, ...)??
    > thnx!


    For example:
    <table><tr>
    <td><a href=""
    onmouseover="document.images.pic.border=1"
    onmouseout="document.images.pic.border=0"
    >text</a></td>

    <td><img id="pic" src="yourpic.gif"></td>
    </tr></table>

    Modern browsers allow onmouseover and onmouseout to be set directly in the
    <td> opening tag, for older browsers you need to wrap the text in an <a> tag
    (which can be made to look like ordinary text) as shown above.
    HTH
    Ivo
     
    Ivo, Jul 1, 2004
    #2
    1. Advertising

  3. Bad_Kid

    Grant Wagner Guest

    Bad_Kid wrote:

    > I have text (in table cell) and 1 picture (in other table cell)
    > is there a javascript that does this: when i move mouse over that cell with
    > text -> picture get border (or some other effect, picture resizes, ...)??
    > thnx!


    Yes, there is Javascript that will do that.

    --
    | Grant Wagner <>

    * Client-side Javascript and Netscape 4 DOM Reference available at:
    *
    http://devedge.netscape.com/library/manuals/2000/javascript/1.3/reference/frames.html

    * Internet Explorer DOM Reference available at:
    *
    http://msdn.microsoft.com/workshop/author/dhtml/reference/dhtml_reference_entry.asp

    * Netscape 6/7 DOM Reference available at:
    * http://www.mozilla.org/docs/dom/domref/
    * Tips for upgrading JavaScript for Netscape 7 / Mozilla
    * http://www.mozilla.org/docs/web-developer/upgrade_2.html
     
    Grant Wagner, Jul 2, 2004
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Vidar Petursson

    Re: LinkButtons and MouseOver

    Vidar Petursson, Jul 8, 2003, in forum: ASP .Net
    Replies:
    1
    Views:
    1,257
    sramruttun
    Jul 9, 2003
  2. wazoo
    Replies:
    2
    Views:
    5,430
    wazoo
    Oct 24, 2003
  3. Steve Chatham

    ASP dotnet question - mouseover

    Steve Chatham, Nov 17, 2003, in forum: ASP .Net
    Replies:
    1
    Views:
    433
    Chris Jackson
    Nov 17, 2003
  4. Morten
    Replies:
    2
    Views:
    702
    Morten
    Dec 19, 2003
  5. TJS
    Replies:
    1
    Views:
    3,298
    =?Utf-8?B?QW5hbmQgTW9oYW4=?=
    Feb 17, 2004
Loading...

Share This Page