Override Admin menu icon

One way is to use the admin_menu hook to insert CSS with your selection of menu icons (which use the DashIcons). The googles show this recent result: https://swapnil.blog/2018/06/25/how-to-change-wordpress-admin-icons/ . Here’s some code from there; you’ll just need to figure out the CSS for each menu item – use your Developer inspection tools (F12, usually) to … Read more

Add a field into a shortcode of an extension

to customise the complete result of the shortcode, you can try this code which redefine the shortcode : add_action(“plugins_loaded”, function () { if (!isset($GLOBALS[“shortcode_tags”][“wpneo_crowdfunding_form”])) { return; } $original_callback = $GLOBALS[“shortcode_tags”][“wpneo_crowdfunding_form”]; add_shortcode( “wpneo_crowdfunding_form” , function ($attr, $content, $tag) use ($original_callback) { $original_result = $original_callback($attr, $content, $tag); // customise the HTML result of the form $original_result = … Read more

Ip2location plugin in my template header?

I’m assuming you’re using “IP2Location Tag WordPress Plugin”. In main file of IP2Location plugin, the class instance is created and assigned to the variable. $ip2location_tags = new IP2LocationTags(); To use the plugin in theme, just use the global variable $ip2location_tags. Remember to make sure that the class IP2LocationTags exists first and use global keyword. if … Read more

Get posts in taxonomy randomly

You have syntax error in tax_query. ‘tax_query’ => array( array ( ‘taxonomy’ => $term->taxonomy, ‘field’ => ‘term_id’, // this is default value, so can be ommited ‘terms’ => $term->term_id, ) ) As you can read in Codex, possible values for field parameter are: term_id (default), name, slug or term_taxonomy_id. In this question you can read … Read more

Page Templates not using functions.php

Your enqueued css should work for all page template if there is no condition applied. could you please share it how you enqueued? Another thing you can check. In header.php, can you please check that wp_head(); function has been called properly in the page template’s head tag. if not exists in the header.php between the … Read more

The wordpress website is showing ‘w’ while it loads and in the footer

If you view the source you will see a w right before the DOCTYPE w <!DOCTYPE html> <!–[if IE 7]> <html class=”ie ie7″ lang=”en-US” prefix=”og: http://ogp.me/ns#”> <![endif]–> <!–[if IE 8]> <html class=”ie ie8″ lang=”en-US” prefix=”og: http://ogp.me/ns#”> <![endif]–> <!–[if IE 9]> <html class=”ie ie9″ lang=”en-US” prefix=”og: http://ogp.me/ns#”> <![endif]–> <!–[if (gt IE 9)|!(IE)]><!–> <html lang=”en-US” prefix=”og: http://ogp.me/ns#”> … Read more