1 beano Aug 14, 2008 16:42
3 waltercruz Aug 14, 2008 21:54
I think that it should work :)
4 beano Aug 15, 2008 12:23
Ok, I've done almost the same thing with my RSS2 feed and it seems to work.
Actual changes made:
Your first change (line 108) made as suggested.
if( $feed_content == 'excerpt' )
becomes
if( $feed_content == 'excerpt' && !empty($Item->excerpt) )
On your second change I did it slightly differently. Mine was a few lines further down from 145 (think I'd made changes to this skin before). I'm sure your way would work fine too, I just wanted to make it more explicit for what I want it to do.
elseif( $feed_content == 'normal'
|| $feed_content == 'full' )
becomes
elseif( $feed_content == 'normal'
|| $feed_content == 'full'
|| ($feed_content == 'excerpt' && empty($Item->excerpt)) )
Also changed the setting in Blog Settings -> Features to Excerpt (now that it falls back instead of posting empty excerpts that's fine).
Result is at: http://www.everythingulster.com/blog/index.php?tempskin=_rss2
5 beano Aug 15, 2008 12:30
OK, sorry, that's not exactly what I wanted.
Because of the way the code's written (not a mistake/bug, just a consequence): if there's no excerpt that solution gives the full post, not the "standard" or "normal" or whatever its called where it stops at the "Read More" link.
To solve that find the 2 lines just below the second change that say:
if( $feed_content == 'normal' )
and change them both to
if( $feed_content == 'normal' || ($feed_content == 'excerpt' && empty($Item->excerpt)))
6 waltercruz Aug 15, 2008 15:32
Your feed returned a error 500 right now!
7 yabba Aug 15, 2008 16:31
<?php
$feed_content = ( empty( $Item->excerpt ) ? 'normal' : 'excerpt' );
?>
¥
8 beano Aug 15, 2008 16:52
Walter wrote:
Your feed returned a error 500 right now!
Works fine for me :\
9 beano Aug 15, 2008 16:53
¥åßßå wrote:
<?php $feed_content = ( empty( $Item->excerpt ) ? 'normal' : 'excerpt' ); ?>
¥
That would've made sense too, obviously! Where's the "D'oh!" smiley when you need it? Thanks!
10 yabba Aug 15, 2008 17:09
No worries ;)
¥
You can edit rss or atom skin and add something like this
For example in rss2 skin edit the followig on line 108
and you should also edit lines 145,150 to just else
It's not tested, but should work ;)