WordPress.org

Ready to get started?Download WordPress

Forums

GamePress
RSS - Custom Post Type with Featured Image (1 post)

  1. PB4L
    Member
    Posted 1 year ago #

    Hi guys,

    Does anyone have RSS working with Custom Post Types and Image?

    I currently have it showing RSS with Custom Post Type, but it doesn't show the featured image.

    Modify functions.php and added in line 333.

    /*------------------------------------------------------------------------------------------------------------*/
    /* Create custom post types RSS
    /* Source: http://www.ballyhooblog.com/add-custom-post-types-wordpress-main-feed/
    /*------------------------------------------------------------------------------------------------------------*/
    function myfeed_request($qv) {
    	if (isset($qv['feed']) && !isset($qv['post_type']))
    		$qv['post_type'] = get_post_types($args = array(
    	  		'public'   => true,
    	  		'_builtin' => false
    		));
    		array_push($qv['post_type'],'post');
    		return $qv;
    }
    add_filter('request', 'myfeed_request');

Topic Closed

This topic has been closed to new replies.

About this Theme

About this Topic

Tags

No tags yet.