• Hello,

    Would it be possible to add some hooks in code ?
    For example I’d like to modify the custom post output. I can change it by myself but no updates anymore ??

Viewing 1 replies (of 1 total)
  • Thread Starter nicolasrenard

    (@nicolasrenard)

    I changed in wp-sitemap-page.php :

    	// List all the results
    	if ( !empty($posts_cpt) ) {
    		foreach( $posts_cpt as $post_cpt ) {
    			$list_pages .= '<li><a href="'.get_permalink( $post_cpt->ID ).'"'.$attr_nofollow.'>'.$post_cpt->post_title.'</a></li>'."\n";
    		}
    	}
    

    in

    	// List all the results
    	if ( !empty($posts_cpt) ) {
    		foreach( $posts_cpt as $post_cpt ) {
    			$list_pages .= '<li><a href="'.get_permalink( $post_cpt->ID ).'"'.$attr_nofollow.'>'.apply_filters( 'wp_sitemap_page_cpt_label', $post_cpt->post_title, $post_cpt->ID ).'</a></li>'."\n";
    		}
    	}
    
    • This reply was modified 8 years, 3 months ago by nicolasrenard.
Viewing 1 replies (of 1 total)
  • The topic ‘Hooks addition’ is closed to new replies.