Home / category / Remove title attribute from wp_list_categories
  • Remove title attribute from wp_list_categories


    Adding this snippet to the functions.php of your wordpress theme will remove the title=”” attribute from the anchor tag when using wp_list_categories().

    wordpress snippet : PHP

    function replace_wps_title_att($output) {
    	$output = preg_replace('` title="(.+)"`', '', $output); 
            return $output;

    ( WordPress codex functions, hooks, in this snippet. )

    wp_list_categories, add_action, wp,

Build a better with wpsnipp.com

Weekly snippets, themes, deals coupons roundup.

x No Thanks