Results 1 to 7 of 7

Thread: CUrsor Remains When Using a Form in ANylink

  1. #1
    Join Date
    Jun 2005
    Posts
    4
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Cursor Remains When Using a Form in Anylink

    AnyLink Drop Down Menu
    http://www.dynamicdrive.com/dynamici...pmenuindex.htm

    Hello,

    I am using the AnyLink script to pull down a search form on my forums. It works great and I am brushing up on my CSS to get it to look just like I want it to. So, thank you for the script

    Since I am using a text field, when the block disappears, it leaves behind a blinking cursor. Can somebody tell me how to clear it?

    Thanks in advance for any help!
    Last edited by DrthVictor; 06-10-2005 at 02:13 PM.

  2. #2
    Join Date
    Mar 2005
    Location
    SE PA USA
    Posts
    30,495
    Thanks
    82
    Thanked 3,449 Times in 3,410 Posts
    Blog Entries
    12

    Default

    Dealing with a lingering cursor type can be tough at times. Generally though, the first line of attack is to determine what function executed last before you were left with the undesirable cursor. Then just tack on some code to that function to change the cursor style to whatever you want (default is usually good). Sometimes the target element must be one that has just departed, other times it needs to be the body or whatever element the cursor is on at that moment. If this condition does not persist say, it reverts to a normal cursor after you move it about a bit, I wouldn't worry over it. If you want more specific advice . . .

    PLEASE: Include the URL to your problematic webpage that you want help with.
    - John
    ________________________

    Show Additional Thanks: International Rescue Committee - Donate or: The Ocean Conservancy - Donate or: PayPal - Donate

  3. #3
    Join Date
    Jun 2005
    Posts
    4
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Quote Originally Posted by jscheuer1
    If you want more specific advice . . .

    PLEASE: Include the URL to your problematic webpage that you want help with.
    Thanks for the quick reply. Since it is a part of a forum, here is a link to a thread that uses the script:

    http://www.adversitysg.com/viewtopic.php?t=548

    Steps to Reproduce:

    1. In the upper right, click the link at the top of the first post that reads "Search Within Topic"
    2. When the form drops down, click inside the text field.
    3. Move your mouse away so the dropdown disappears.
    4. Note leftover cursor where the form used to be.
    Last edited by DrthVictor; 06-10-2005 at 02:13 PM.

  4. #4
    Join Date
    Mar 2005
    Location
    SE PA USA
    Posts
    30,495
    Thanks
    82
    Thanked 3,449 Times in 3,410 Posts
    Blog Entries
    12

    Default

    Boy, what an involved page! And, this is not the actual cursor but, a phantom one. No matter. First off, this only seems to happen in Mozilla (FF NS and perhaps other Gecko based browsers). Second, if you click on any other part of the document, this phantom insertion cursor goes away. Third, the actual cursor is unaffected. All this considered, I would leave it alone but, there is a method that pops to mind. The part in the script that makes the drop down disappear after the mouse has moved over it and then away is contained in this section of the script:
    Code:
    if (ie4||ns6)
    document.write('<div id="dropmenudiv" style="visibility:hidden;width:'+menuwidth+';background-color:'+menubgcolor+'" onMouseover="clearhidemenu()" onMouseout="dynamichide(event)"></div>')
    Change it to look like this:
    Code:
    if (ie4||ns6)
    document.write('<div id="dropmenudiv" style="visibility:hidden;width:'+menuwidth+';background-color:'+menubgcolor+'" onMouseover="clearhidemenu()" onMouseout="dynamichide(event);this.blur()"></div>')
    That might not get it but, it is the most innocent way of getting it. Next method is change it to this:
    Code:
    if (ie4||ns6)
    document.write('<div id="dropmenudiv" style="visibility:hidden;width:'+menuwidth+';background-color:'+menubgcolor+'" onMouseover="clearhidemenu()" onMouseout="dynamichide(event);if (ns6){this.parentNode.focus()}"></div>')
    and finally, if that won't do:
    Code:
    if (ie4||ns6)
    document.write('<div id="dropmenudiv" style="visibility:hidden;width:'+menuwidth+';background-color:'+menubgcolor+'" onMouseover="clearhidemenu()" onMouseout="dynamichide(event);if (ns6){this.parentNode.parentNode.focus()}"></div>')
    If none of that gets it we will probably have to resort to reloading the page, which seems unacceptable to me for a page of this nature. I have one other idea involving the display property but, try these first.
    - John
    ________________________

    Show Additional Thanks: International Rescue Committee - Donate or: The Ocean Conservancy - Donate or: PayPal - Donate

  5. #5
    Join Date
    Jun 2005
    Posts
    4
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Quote Originally Posted by jscheuer1
    Boy, what an involved page!
    I hope that's a compliment My game group likes it, though it is a bit heavy on the code. Flow and navigation are still under heavy development.

    Anyway, thanks for the tips. I'll give them a try when I get home. If the only solution is reloading the page, then I will probably live with it as is. We have a member with a 300k sig(!) and I can't very well tell him to change it, since it's his hosting we are using. So, due to this, reloading the page could be painful for slower connections.

  6. #6
    Join Date
    Jun 2005
    Posts
    4
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    I tried all three methods and none worked. I can live with the ghost cursor. Just figured that if it was possible to remove it, I would. But I can live with it. Thank you for the help

  7. #7
    Join Date
    Mar 2005
    Location
    SE PA USA
    Posts
    30,495
    Thanks
    82
    Thanked 3,449 Times in 3,410 Posts
    Blog Entries
    12

    Default

    Well if you are still game, we could try substituting display:none for visibility:hidden but, this is a little more complicated. It requires also substituting display for visibility everywhere it is used in the script and substituting none for hidden everywhere and substituting block for visible everywhere. If you want to try it but want more detailed instructions, let me know. If you just do a global search and replace on:

    visibility (replace all with) display
    hidden (replace all with) none
    visible (replace all with) block

    That should get it, assuming my idea will work. Keep a back up of the page, just in case this causes other problems. And make sure to replace all occurrences of each word, including in the html for this script, if any.
    - John
    ________________________

    Show Additional Thanks: International Rescue Committee - Donate or: The Ocean Conservancy - Donate or: PayPal - Donate

Bookmarks

Posting Permissions

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