How to add a custom class in the wordpress navigation menu

Source: Internet
Author: User

Wordpress navigation menu calls generally use the built-in wp_nav_menu () function. After using the function, we find that this function does not provide us with the function of adding custom class interfaces to each navigation menu!

After searching, I finally found a solution provided by wordpress in an article by a foreigner! Well, wordpress is still very powerful...

The method is simple:

Choose "wordpress background"> "appearance"> "menu", and click "Display options" in the upper right corner of the page. We can see that "css class" is available in "display menu advanced properties, select it, and check that there is an additional css class input box in the menu item. The entered content is the custom class value of the navigation menu item !! Once again, I have seen the power of wordpress. Shake it, cool !! Haha...

 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.