This is purely a CSS question, and has nothing to do with WordPress, but the answer is simple enough. You need to use the child combinator:
.nav li.current-menu-item > a {}
Related Posts:
- Adding first / last CSS classes to menus
- wp nav menu: add attributes to menu items [duplicate]
- Hide Hamburger Menu On Specific Page (Front Page/Home Page)
- Menu Custom Data Attributes
- How to modify mobile nav menu text in theme
- Extend Menu Walker Output
- conditional: if is page, and all subpages
- wp nav menu: show submenu below li item
- Styling an “active” link outside of WordPress default menu
- how to changes mobile menu toggle breakpoint in WordPress
- dynamic php menu with hidden sub-categories only showing when the category name is clicked
- How to let mobile navigation menu close when link is clicked?
- Bring Font Awesome icons inside menu A tags
- Display specific main Sub Nav on Woocommerce product pages
- How limit the width of a fixed menu-bar on scroll?
- WP_Nav Highlight Parent Issue
- How to change the menu color
- start_lvl Ignored in Custom walker_nav_menu
- wp_delete_auto_drafts() deletes links in menus
- Check if a menu is empty?
- the_author_posts_link css class
- Walker class: Problems with understanding how walk() method can be called without error
- Replacing a specific menu item
- How can I access the “description” of a menu item?
- wp enqueue style and style sheet depth
- CSS saved & enqueued, but wordpress doesn’t load css text, only file
- WordPress loop specific thumbnail size
- Is it possible to use the featured image of a page as a css background without inlining?
- How to display a value from a radio button in the options menu in wordpress
- How should I best target dynamically served content?
- How to scale image with equal width and height without distortion?
- items_wrap not working
- Style wp_page_menu() items
- php syntax – how to concatenate properly – echo bloginfo(‘stylesheet_directory)
- Have CSS Class Added with `is_page()` WP function
- Problem adding class to body_class
- Run a filter when a walker runs
- Input type search in Menu
- Change list item content in menu navigation to add a child element with specific class
- Selectbox in admin panel function linking to CSS
- How to display pictures from database?
- Gravity form built in Captcha
- How does wp_enqueue_scripts work?
- Whats the proper way to use a php stylesheet in a wordpress theme? [duplicate]
- get_the_title() gets printed out twice
- WordPress style.css not updating, only after theme reload
- Adding logo to WordPress header
- height should be set to auto to avoid pixelation in the post thumbnail function
- Two menus show up
- Add Codepen animation as Preloader to WordPress
- Reduce size of responsive title
- Show About and Contact Us page when they’re clicked in the top menu.
- Clickable image link sends people to wrong URL
- Creating a mobile site by adding a new class to the body tag from functions.php
- Split site title and apply different classes
- Get css class of menu item in custom menu structure
- Dynamic CSS through PHP issue
- Assign Custom classes to every Excerpt
- Show login greeting above sub-menu links?
- Menu not styling. New menus functionality giving me a headache
- Adding a navigation page state to individual blog and portfolio pages
- Horizontal drop down category with hover effect working
- Inline CSS header style priority function.php Child (no enqueing I think)
- How to put search bar & logo in the “primary navigation” storefront theme?
- Providin exception to WordPress wp_nav_menu Custom CSS Classes
- How to add a CSS class to this php code [closed]
- Adding markup to sub menu based on class
- echo cutom css code to WordPress page template file ? is this safe?
- Problem with displaying CSS Stylesheets – Am I adding them correctly in my wordpress child theme?
- Trying to generate a CSS file in wordpress uploads folder
- WP Website is shown in HTML
- How to put 2 php codes in functions.php without site crashing
- I got big white screen when i attach main style sheet of Html in functions.php
- wp_get_nav_menu_items() with ACF
- register dependency css and js inside a plugin class
- How to switch between two primary menus (programatically0
- Used a code to revoke some dashboard menus for my contributors but for some reason it’s revoked me access to the editor [closed]
- Add a default style if no Featured image is selected
- How to give custom roles the capability to edit one Menu instead of every Menu
- Primary navigation menu with timed items from custom post type
- Styling a specific post after hovering over it
- custom field – changing an element or background of id div – different versions not working
- Fatal error when using array_diff() function inside of wp_update_nav_menu hook?
- CSS loading as empty file in Custom Theme
- Beyond widget side menu editing, with the php page, custom template
- Where to find the html for WordPress site? [closed]
- Two theme locations for two menus, but only one is showing up
- How to remove image on single product and get product to span page?
- widget: input the px value from user and use it as inline style in widget function
- Contact form field in wordpress menu
- How to call a certain object/menubar in a PHP file
- How to add a code for lastpostdate after/inside a specific menu link?
- How Can I Center the Logo in the Navigation Menu? [closed]
- WordPress adding in site URL to header links
- Can’t remove menu items added by plugin
- Nav Menu Display
- How to create and add js and css file when server is not on my PC?
- which php or css file has generated an inline style in WordPress that overwrites my css
- inner-wrap div pushing custom table far down on page
- Custom nav with bootstrap dropdown