Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 5 of 5
  1. #1
    New Coder
    Join Date
    Jul 2004
    Posts
    26
    Thanks
    0
    Thanked 0 Times in 0 Posts

    javascript keep triggering mouseout :(

    i am trying to implement a mouse over / mouse out effect(just to make a body of text dissaprear) on a html table. the problem is i have a javascript dropdown in that table. every time i hover hover over the menu my mouse over / mouse out keeps flicking on and off. although my cursor is still in the table, each option in the menu keeps registering as a mouse out. ive tried to overcome this using an invisible gif on top of the drop down. that didnt work has anyone dealt with this problem before...? thank in advance. Katie

  • #2
    Senior Coder
    Join Date
    Aug 2002
    Location
    UK
    Posts
    2,789
    Thanks
    2
    Thanked 14 Times in 14 Posts
    You may be able to use event.cancelBubble

    Can you post your code?
    The silent one.

    The most dangerous thing in the world is an idea.
    The most dangerous person in the world is the one with an idea.

  • #3
    New Coder
    Join Date
    Mar 2005
    Posts
    33
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Why not use CSS for that? Hide the text with display: none; and create a pseudoclass with :hover, where you set the display to block, inline or whatever you wish to use.

  • #4
    New Coder
    Join Date
    Jul 2004
    Posts
    26
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Quote Originally Posted by Mr J
    You may be able to use event.cancelBubble

    Can you post your code?

    here are my function for setting visibility of the text box


    function MM_HideLayersOver() {
    document.all.testvisible.style.visibility="hidden";
    self.setTimeout('subfunction()', 1000)
    }

    function MM_HideLayersOut() {
    self.setTimeout('subfunction()', 1000)
    document.all.testvisible.style.visibility="visible";
    }

    here is my current call

    <a href = "www.google.com" onMouseOver="MM_HideLayersOver()" onMouseOut="MM_HideLayersOut()">
    <img src="http://admin.digitalriver.com/v2.0-img/operations/symcorp/image/g/h/o/ghost.gif" id="centeredimage">
    </a>

    here is the kind of this going on im my dropdown. all my catagories and the dropdow for the first category. hope this helps??

    ,"<div align=\"left\">TEST TEXT<img src='spacer.gif' height='1' width='48'>&gt;</div>","show-menu=isec",,,0 // "Description Text", "URL", "Alternate URL", "Status", "Separator Bar"
    ,"<div align=\"left\">TEST TEXT <img src='spacer.gif' height='1' width='50'>&gt;</div>","show-menu=virus",,,0 // "Description Text", "URL", "Alternate URL", "Status", "Separator Bar"
    ,"<div align=\"left\">TEST TEXT <img src='spacer.gif' height='1' width='50'>&gt;</div>","show-menu=problem",,,0 // "Description Text", "URL", "Alternate URL", "Status", "Separator Bar"
    ,"<div align=\"left\">TEST TEXT <img src='spacer.gif' height='1' width='55'>&gt;</div>","show-menu=communication",,,0 // "Description Text", "URL", "Alternate URL", "Status", "Separator Bar"
    ,"<div align=\"left\">TEST TEXT <img src='spacer.gif' height='1' width='43'>&gt;</div>","show-menu:diskman",,,0 // "Description Text", "URL", "Alternate URL", "Status", "Separator Bar"
    ])

    addmenu(menu=["isec",
    ,,177,1,,pullDownStyle,,,pullDownEffect,,,,,,,,,,,,
    ,"TEST TEXT","ec_MAIN.Entry10?V1=646659&PN=1&SP=10023&xid=27684&CID=185854&DSP=&CUR=826",,,0
    ,"TEST TEXT","ec_MAIN.Entry10?V1=646655&PN=1&SP=10023&xid=27684&CID=185854&DSP=&CUR=826",,,0
    ])

  • #5
    Senior Coder
    Join Date
    Aug 2002
    Location
    UK
    Posts
    2,789
    Thanks
    2
    Thanked 14 Times in 14 Posts
    Unfortunately the code you have posted does not help.

    I do not see the code for the table or how you have implimented the call to hide/show the text.

    If the call is made by this

    <a href = "www.google.com" onMouseOver="MM_HideLayersOver()" onMouseOut="MM_HideLayersOut()">
    <img src="http://admin.digitalriver.com/v2.0-img/operations/symcorp/image/g/h/o/ghost.gif" id="centeredimage">
    </a>


    then it should not affect anything else in the table, I was assuming that you had put the call in the opening table tag.

    Also the functions for hiding and showing will only work in IE and you would be better with the following

    function MM_HideLayersOver() {
    document.getElementById("testvisible").style.visibility="hidden";
    self.setTimeout('subfunction()', 1000)
    }

    function MM_HideLayersOut() {
    document.getElementById("testvisible").style.visibility="visible";
    self.setTimeout('subfunction()', 1000)
    }

    Can you post the url to your actual page?
    The silent one.

    The most dangerous thing in the world is an idea.
    The most dangerous person in the world is the one with an idea.


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •