Help ~ drop-down menu problem ~ please_html/css_WEB-ITnose

WBOY
Release: 2016-06-24 12:08:51
Original
1062 people have browsed it

Dear experts, how do you enable the browsed menu to display browsing traces, so that browsing the second-level menu can also be reflected on the first-level menu?
In the css I wrote, only the first-level menu can display browsing traces, and it will always be displayed. If you click on something else, the browsing traces will still be displayed. Only clearing the cache can restore the original state.
The function I want to achieve is to click on which one to see visited, and the others will be normal. Then click on another one, and the other one will show visited, and the previous one will return to its original state. How should you implement it?
The code is as follows




Untitled Document





                                                                         ;/li> & Lt; li & gt; & lt; a href = "2" & gt; 2222 & lt;/a & gt;
& lt;/li & gt;
& lt; li gt; & lt; a href = "3" & gt; 3333 & lt; /a>
         
        

  • 4444 
            
  •  
            
  • 55555 
            
       
              
    • 55551111
    •  
              
    • 55552222
    •  
              
    • 55553333
    •  
              
     
            
  •  
            
  • 66666
            
  •  
            
  • 7777  
            
       
              
    • 77771111
    •  
              
    • 77772222

    •         
    • 77773333
    •  
              
     
            
  •  
            
            





    回复讨论(解决方案)

    那你只能用JS控制了的。a的伪类没有那么智能的。

    而起你这样不能动态的从数据库获得,只是死的

    哦哦 非常感谢

    用js或者jquery控制最方便了

    用js或者jquery控制最方便了
    ...

    source:php.cn
    Statement of this Website
    The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
    Popular Recommendations
    Popular Tutorials
    More>
    Latest Downloads
    More>
    Web Effects
    Website Source Code
    Website Materials
    Front End Template