WordPress Recent Posts – Loop

Add this function in your functions.php for specific size of thumbnail add_image_size( ‘custom-size’, 220, 180 ); and fetch custom-size image. For excerpt length use this function. function wp_example_excerpt_length( $length ) { return 30; } add_filter( ‘excerpt_length’, ‘wp_example_excerpt_length’);

Filtering markers on google map by WordPress category[SOLVED]

Solved, the problem was in filterMarkers() function filterMarkers = function (category) { var markers = gmarkers[i]; for (var i = 0; i < gmarkers.length; i++) { // If is same category or category not picked if (gmarkers[i].category == category || category.length === 0) { gmarkers[i].setVisible(true); } // Categories don’t match else { gmarkers[i].setVisible(false); } } … Read more

Use WP Cron to Clear a Page Cache?

Yes, using WP-CRON will work for this well. One way to do it, is to set a new cron for immediately with every page load. Do not give the job a unique name. By default, WP-CRON will only take an action once every ten minutes. So in the case where your site is being hit … Read more

Difference between “Walker_Nav_menu” and “walker”

Walker_Nav_menu extends walker and includes all the markup for a menu. walker by itself doesn’t have any markup, it just handles walking the tree, and needs to be extended to add markup. See the documentation: Extend the Walker class to use it, see examples below. Child classes do not need to implement all of the … Read more