Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. Web Development
  3. ASP.NET
  4. menu parent backcolor when hovering child menu

menu parent backcolor when hovering child menu

Scheduled Pinned Locked Moved ASP.NET
tutorialcss
4 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • J Offline
    J Offline
    janetb99
    wrote on last edited by
    #1

    Have a menu control working fine, but need a couple tweaks. Example (assumes background white, hover background gray, also using css) Anybody know how or a tutorial that will show me how to do two things: 1. When hovering over "Collie", have the background of Dog be the hover color. 2. When hovering on "Collie" item but not on "Collie", have the entire item background be gray. Right now, if the text is short, and you hover to the right of the text within the item, the background remains white behind the text. I would like for the background to turn gray on the parent item, and the entire single item now matter where the mouse appears. Thanks so much, Janet

    N 1 Reply Last reply
    0
    • J janetb99

      Have a menu control working fine, but need a couple tweaks. Example (assumes background white, hover background gray, also using css) Anybody know how or a tutorial that will show me how to do two things: 1. When hovering over "Collie", have the background of Dog be the hover color. 2. When hovering on "Collie" item but not on "Collie", have the entire item background be gray. Right now, if the text is short, and you hover to the right of the text within the item, the background remains white behind the text. I would like for the background to turn gray on the parent item, and the entire single item now matter where the mouse appears. Thanks so much, Janet

      N Offline
      N Offline
      Not Active
      wrote on last edited by
      #2

      You'll need to use another control or write some custom javascript to handle these actions. The menu control is rendered as a html table with the items as anchor tags in the cells. You would need to write some javascript to handle the onmouseover event of each anchor tag and adjust the colors as appropriate.


      only two letters away from being an asset

      J 1 Reply Last reply
      0
      • N Not Active

        You'll need to use another control or write some custom javascript to handle these actions. The menu control is rendered as a html table with the items as anchor tags in the cells. You would need to write some javascript to handle the onmouseover event of each anchor tag and adjust the colors as appropriate.


        only two letters away from being an asset

        J Offline
        J Offline
        janetb99
        wrote on last edited by
        #3

        When you say "use another control" - can you suggest one that would do as I would like? Or, would they all have the same rendering problem? And/or, do you know of a control or someone who has written the onmouseover for the menu control as you have described? Perhaps one you could recommend for a fee? The main thing I'm looking for is the parent to retain the 'hover' color when on it's child. jb

        N 1 Reply Last reply
        0
        • J janetb99

          When you say "use another control" - can you suggest one that would do as I would like? Or, would they all have the same rendering problem? And/or, do you know of a control or someone who has written the onmouseover for the menu control as you have described? Perhaps one you could recommend for a fee? The main thing I'm looking for is the parent to retain the 'hover' color when on it's child. jb

          N Offline
          N Offline
          Not Active
          wrote on last edited by
          #4

          Another third party control may provide better a experience for you. Without knowing your complete requirements or architecture I can't really recommend one. If you want ot contact me offline we can discuss it further.


          only two letters away from being an asset

          1 Reply Last reply
          0
          Reply
          • Reply as topic
          Log in to reply
          • Oldest to Newest
          • Newest to Oldest
          • Most Votes


          • Login

          • Don't have an account? Register

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • World
          • Users
          • Groups