Display specific main Sub Nav on Woocommerce product pages

Yes you can with conditional tags. https://docs.woocommerce.com/document/conditional-tags/ So depending on whether you wanted it to appear on all woocommerce pages (the listing page as well as the individual product pages) you could use is_woocommerce() if you wanted just on individual product pages you could use is_product() So you would use an if statement to check … Read more

display cart information within li of cart menu item

The items in the $fragments array will replace the html contents of the element you specify as the key. In your example $fragments[‘li.menu-item-type-woocommerce-cart’] = ‘some html’; some html will be inserted in the DOM element <li class=”menu-item-type-woocommerce-cart”> Here is the Javascript: $( ‘li.menu-item-type-woocommerce-cart’ ).replaceWith( ‘some html’ ); Is there already such an element in your … Read more

WordPress menu issue after update

Suggest going through all options of the Theme Customization to setup (and understand) everything. Check the Menu area to make sure that the theme is selecting the proper menu. Look at the Menus that are defined to ensure you are selecting the correct menu. Some themes use ‘widget areas’ to allow for different content (including … Read more

My connecting URL form in html to PHP does not work

I suspect the cause of your problems is here: $video = $_POST[‘subject’]; if ($video == true){ For example, if our subject is https://www.youtube.com/watch?v=dQw4w9WgXcQ then the check is: if ( ‘https://www.youtube.com/watch?v=dQw4w9WgXcQ’ == true ) And we know that true is not https://www.youtube.com/watch?v=dQw4w9WgXcQ, so the check here is incorrect. What we want is to check if $video … Read more

Parent link need to go first child submenu

I found solution here Create template for parent pages: <?php /* Template Name: Redirect To First Child */ if ( have_posts() ) { while ( have_posts() ) { the_post(); $pagekids = get_pages( “child_of=” . $post->ID . “&sort_column=menu_order” ); $firstchild = $pagekids[0]; wp_redirect( get_permalink( $firstchild->ID ) ); } } ?>

Sub Categories in drop down menu

You can use this function: the_widget( ‘WP_Widget_Categories’, ‘dropdown=1&hierarchical=1′ ); This function give you a select box and you will get all the parent categories and sub-categories. After applying this code inspect category select box, then you can manipulate your HTML code. And show your category as you wish. If you don’t want any select box, … Read more

Vertical Menu for one page only

You’ll want to search your theme files for the part of the page template that is controlling those classes, likely page.php would be a good place to start. Then once you find the part you think is controlling the output, try adding: if( is_page(24331) ) { echo ‘vertical-header’; } For example: <div id=”page” class=”layout-fullwidth <?php … Read more