Product categories WordPress codex
How to get current product category slug?
global $wp_query; echo $wp_query->query_vars['product_cat'];
How to get current product category slug?
global $wp_query; echo $wp_query->query_vars['product_cat'];
How check if current user has pmpro_hasMembershipLevel? Copy and paste the code below to your custom template. // $levelID is can be name or ID of the membership level // $userID is the ID of the current user pmpro_hasMembershipLevel( $levelID, $userID ); // Example if(pmpro_hasMembershipLevel(’12’)){ } if(pmpro_hasMembershipLevel(‘Gold’)){ } if(pmpro_hasMembershipLevel(array(’12’,’14’,’Gold’))){ }
Question: How to use WDES Responsive popup in revolution slider? Answer: You can add a new layer in revslider and put the “[wdes-popup-title id=”popup_id”] ” inside the new layer. Place the “[wdes-popup-content id=”569″]” in the footer or in the page editor.
Custom and simple jQuery tabs, no library needed. This example is very easy and light to your page. Follow and copy the codes below. DEMO Tab 1 Tab 2 Tab 3 Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry’s standard dummy text ever since the…
How to check if there is an ajax running on your page? Here’s a code below that can help you figure it out. jQuery( document ).ready(function($) { $(document).ajaxStart( function() { console.log(‘ajax true’ ); }).ajaxStop( function() { console.log(‘ajax false’ ); }); });
Uncaught (in promise) TypeError: Illegal invocation error using jQuery ajax code. I don’t understand how this ajax JS parameters works but digging a deep research about the error shows me some correct solution. Here’s the code of mine that has `Uncaught (in promise) TypeError: Illegal invocation` error. JS code that has `Uncaught (in promise) TypeError:…
Codes below will show you the how to get the current number of post shows from and to results in a page. Example : Showing 01 – 10 post of blog category Showing 11 – 20 post of blog category Showing 21 – 29 post of blog category /*——————————————————————— * $current_page_number default is 1. Example…