WP rss Feed issue

Status
Not open for further replies.

crunchi

pr0n master
Jun 28, 2006
183
2
0
Las Vegas
www.crunchi.net
Hello everyone..

the problem: wp-rss.php doesn't show content of post
why: content is html
what i've done: i changed /includes/feed-rss.php and replace excerpt with the_content
what happened: wp-rss.php was in html format not rss, it actually showed tables and images

can anyone help me? and fast please

Take care guys
 


Do you have an example we can take a look at? Why not just go back to the original wp-rss.php?

This is default:

Code:
<?php
header('Content-type: text/xml; charset=' . get_option('blog_charset'), true);
$more = 1;
?>
<?php echo '<?xml version="1.0" encoding="'.get_option('blog_charset').'"?'.'>'; ?>
<!-- generator="wordpress/<?php echo $wp_version ?>" -->
<rss version="0.92">
<channel>
<title><?php bloginfo_rss('name'); wp_title_rss(); ?></title>
<link><?php bloginfo_rss('url') ?></link>
<description><?php bloginfo_rss('description') ?></description>
<lastBuildDate><?php echo mysql2date('D, d M Y H:i:s +0000', get_lastpostmodified('GMT'), false); ?></lastBuildDate>
<docs>http://backend.userland.com/rss092</docs>
<language><?php echo get_option('rss_language'); ?></language>
<?php do_action('rss_head'); ?>
<?php while (have_posts()) : the_post(); ?>
<item>
<title><?php the_title_rss() ?></title>
<?php if (get_option('rss_use_excerpt')) { ?>
<description><![CDATA[<?php the_excerpt_rss() ?>]]></description>
<?php } else { // use content ?>
<description><?php the_content_rss('', 0, '', get_option('rss_excerpt_length')) ?></description>
<?php } ?>
<link><?php permalink_single_rss() ?></link>
<?php do_action('rss_item'); ?>
</item>
<?php endwhile; ?>
</channel>
</rss>

This is my version:


Code:
<?php
header('Content-type: text/xml; charset=' . get_option('blog_charset'), true);
$more = 1;
?>
<?php echo '<?xml version="1.0" encoding="'.get_option('blog_charset').'"?'.'>'; ?>
<!-- generator="wordpress/<?php echo $wp_version ?>" -->
<rss version="0.92">
<channel>
<title><?php bloginfo_rss('name'); wp_title_rss(); ?></title>
<link><?php bloginfo_rss('url') ?></link>
<description><?php bloginfo_rss('description') ?></description>
<lastBuildDate><?php echo mysql2date('D, d M Y H:i:s +0000', get_lastpostmodified('GMT'), false); ?></lastBuildDate>
<docs>http://backend.userland.com/rss092</docs>
<language><?php echo get_option('rss_language'); ?></language>
<?php do_action('rss_head'); ?>
<?php while (have_posts()) : the_post(); ?>
<item>
<title><?php the_title_rss() ?></title>
<?php if (get_option('rss_use_excerpt')) { ?>
<description><?php the_content() ?></description>
<?php } ?>
<link><?php permalink_single_rss() ?></link>
<?php do_action('rss_item'); ?>
</item>
<?php endwhile; ?>
</channel>
</rss>

Original version problem: there's nothing between description tags when post is html
My version problem: It's not in rss form anymore, it's html, it showes images and stuff in html
 
Well, isn't whenever the_content is pulled, it pulls html?

If I understand correctly, you changed your rss_feed and now it is showing the content as html and you don't want that?
Yours:
PHP:
 <description><?php the_content() ?></description>

Default:
PHP:
 <description><?php the_content_rss('', 0, '', get_option('rss_excerpt_length'))</description>

(Notice that one is the_content_rss and the other is the_content)

I guess I am trying to get my head around what you are trying to do......what do you want the end result to be?
 
Well, isn't whenever the_content is pulled, it pulls html?

If I understand correctly, you changed your rss_feed and now it is showing the content as html and you don't want that?
Yours:
PHP:
 <description><?php the_content() ?></description>

Default:
PHP:
 <description><?php the_content_rss('', 0, '', get_option('rss_excerpt_length'))</description>

(Notice that one is the_content_rss and the other is the_content)

I guess I am trying to get my head around what you are trying to do......what do you want the end result to be?

yeah html should be pulled but showed as text not as html
 
yeah html should be pulled but showed as text not as html

I'm confused here are you saying that you want your RSS feed to display code and not the rendered image at the end for instance you want it to show code like below.

Code:
<p>This is some text wrapped in paragraph tags</p>

So you want people to see the actual P tags?

If so you need to use HTML special characters, other then that I don't get why your trying to change your RSS feed, why didn't you switch it over to FeedBurner anyway?
 
Status
Not open for further replies.