Created
July 21, 2017 03:56
-
-
Save danielmcclure/cf33ea192543e005bf3a5f749a17e418 to your computer and use it in GitHub Desktop.
Remove Title from Custom Post Type Feeds
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// Remove Title from 'Status' Custom Post Type Feed | |
function remove_post_title_rss($title) { | |
global $post; | |
$post_type = get_post_type($post->ID); | |
if ($post_type == 'status') { | |
$title = ''; | |
} | |
return $title; | |
} | |
add_filter('the_title_rss', 'remove_post_title_rss'); | |
?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment