Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#85 2007-04-16 02:52:10

wilshire
Plugin Author
From: Akron, Ohio
Registered: 2004-08-27
Posts: 656
Website

Re: [plugin] [ORPHAN] rss_auto_excerpt

rss_auto_excerpt 0.5

The latest version adds two new attributes to the plugin.

  1. wrapreadmore – wraps the read more link within the last closing tag of the auto-excerpt which has been requested many times including here earlier in this thread.
  2. stripbreakstabs – strips out line breaks and tabs when generating the auto-excerpt. This was added based on Nathan Smith’s idea of using the plugin to generate content for the meta description tag in his post Lazy Textpattern SEO

For example, place the read more link within the last closing tag with the read more link wrapped in a span tag:

<txp:rss_auto_excerpt length="30" ending="..." wrapreadmore="1" linkwraptag="span" />

Download rss_auto_excerpt

Offline

#86 2007-04-20 14:36:49

feragnoli
Member
From: the hague
Registered: 2005-02-10
Posts: 150

Re: [plugin] [ORPHAN] rss_auto_excerpt

hello Rob, very nice plugin.
I have one problem, though: I can’t manage to wrap the excerpt in a <span> rather than in <p>.
when I set excerptwraptag="span" he just spits: <span><p> . . . . . </p></span> .
Is it a bug or I’m missing something?

Thank you


what was that again…?

Offline

#87 2007-04-21 03:23:33

wilshire
Plugin Author
From: Akron, Ohio
Registered: 2004-08-27
Posts: 656
Website

Re: [plugin] [ORPHAN] rss_auto_excerpt

feragnoli wrote:

hello Rob, very nice plugin.
I have one problem, though: I can’t manage to wrap the excerpt in a <span> rather than in <p>.
when I set excerptwraptag="span" he just spits: <span><p> . . . . . </p></span> .
Is it a bug or I’m missing something?

The <p> tags are likely from textile. You can either turn textile off for your excerpts or use a custom field for your excerpt.

Offline

#88 2007-06-04 09:44:08

jonnott
New Member
Registered: 2007-06-04
Posts: 2

Re: [plugin] [ORPHAN] rss_auto_excerpt

I’m looking to implement something similar to rss_auto_excerpt’s paragraph functionality, but outside of txp – is there any way to get a peek at the source code without actually having txp and installing the plugin?

Offline

#89 2007-06-28 22:23:51

feragnoli
Member
From: the hague
Registered: 2005-02-10
Posts: 150

Re: [plugin] [ORPHAN] rss_auto_excerpt

hello, on a site I’m working on I’m using the excerpt field as an alternative version of the body text (read: body=first language; excerpt=second language).
since the plugin is able to excerpt from a custom field is there a way to make it excerpt from the excerpt field rather than the body?
thank you


what was that again…?

Offline

#90 2007-07-03 14:21:56

merz1
Member
From: Hamburg
Registered: 2006-05-04
Posts: 994
Website

Re: [plugin] [ORPHAN] rss_auto_excerpt

@feragnoli: Good idea! Vote +1


Get all online mentions of Textpattern via OPML subscription: TXP Info Sources: Textpattern RSS feeds as dynamic OPML

Offline

#91 2007-07-12 23:47:46

atbradley
Plugin Author
From: Rhode Island, US
Registered: 2007-02-15
Posts: 34
Website

Re: [plugin] [ORPHAN] rss_auto_excerpt

I’m having (I think) the same problem jusisan was having earlier:

This line:

<txp:rss_auto_excerpt skipparagraphs="1" paragraphs="9999" />

ought to skip the first paragraph and output the rest of the article, but it actually outputs the entire article. setting paragraphs to the number of paragraphs in the post gives me what I expect, (e.g. the post has six paragraphs, so:

<txp:rss_auto_excerpt skipparagraphs="1" paragraphs="6" />

But that isn’t very convenient (not all of my posts have six paragraphs).

Update: I think I’ve fixed this. Replace this line:

$doex = ($paragraphs) ? ($paragraphs < $pghcount) ? 1 : 0 : $doex;

with this:

$doex = ($paragraphs) ? ($paragraphs < $pghcount) ? 1 : $skipparagraphs : $doex;

Doing this may break something else, but it seems to be working as far as I can tell.

Last edited by atbradley (2007-07-13 00:17:31)

Offline

#92 2007-07-16 09:16:52

gemal
Member
From: Copenhagen, Denmark
Registered: 2007-01-09
Posts: 107
Website

Re: [plugin] [ORPHAN] rss_auto_excerpt

Love your plugin but I’m missing a “newlines to spaces” features.

If you have newlines in the text that you want to make an excerpt off the newlines are correctly killed by the excerpt looks weird.

Something like this:
“blablabla.blabla”

I would be nice if I could specify that newlines should be converted into space so that I got:
“blablabla. blabla”

Any chance for a new version with this option?

Offline

#93 2007-08-01 16:51:00

sparkybarkalot
Member
Registered: 2004-10-13
Posts: 43

Re: [plugin] [ORPHAN] rss_auto_excerpt

wilshire wrote:

Depends how you’re calling the plugin. Right now that attribute will only work when overrideexcerpt is not true and the excerpt field is not empty. So if an auto excerpt is generated, the excerpt wrap tag is not used. That should probably be corrected in the next version.

Thanks for a great plugin. It looks like this hasn’t been done yet, is that right? I’d love to have my auto excerpt wrapped in a p tag, followed by the read more link wrapped in a p tag.

Offline

#94 2007-09-05 12:51:08

jonnott
New Member
Registered: 2007-06-04
Posts: 2

Re: [plugin] [ORPHAN] rss_auto_excerpt

Hi,

I don’t currently have textpattern installed myself, but I’d quite like a look at the source code of this plugin.

If you have this plugin installed, could you drop me the source in an email.

It’s

jonnott
gmail
com

Thanks.

Offline

#95 2007-09-28 07:45:10

Timid&friendly
Member
From: The Netherlands
Registered: 2006-05-28
Posts: 252
Website

Re: [plugin] [ORPHAN] rss_auto_excerpt

How can i manually turn off the automatic generation of the read more link?

Occasionally I want to manually link to something else other than a full blown article, (i.e a category or different article). That’s easy.

Problem is that the read more link is still generated. How can I manually overide (at the article level) the automatic generation of the readmore link. Is there a custom field i could use perhaps?
I tried a work-around by using the showlinkwithbody="0" attribute, so that the link is not generated when the excerpt is less that 400 letters but it still output the readmore only this time outside the excerpt <p> ?

<txp:rss_auto_excerpt length="400" linkwraptag=""  
wrapreadmore=“1” linkclass=“morelink” showlinkwithbody=“0”  
ending="... " linktext="Lees meer" />

Another solution would be if you could manually set the url for the “read more” link

Any ideas how i can solve this?

______________________________________________

ANSWER
With Gocom’s help I was able to find a solution that works great for me.

It’s at this thread Overiding Article output at Article level

Last edited by Timid&friendly (2007-10-05 12:02:44)


I think, therefore I AM, … … er … I think :-?

Offline

#96 2007-10-02 20:35:31

marios
Archived Plugin Author
Registered: 2005-03-12
Posts: 1,253

Re: [plugin] [ORPHAN] rss_auto_excerpt

Hi,

Thanks to Rob first of all for puttung this code together.

I found a bug, where the plugin will strip off the closing bracket of a textile inserted break tag, on text strings with brackets(), if found and with Textile turned on.

Here is the test string in question for the article body:

The intent of this article, is to explain each category term with a short explanation.
(This is the article body)
These articles, are stored into the topics section for now.
(This is a child category) child

And this the output:

	<p>The intent of this article, is to explain each category term with a short explanation.<br />
(This is the article body)<br...</p>

with plugin set to words.

On a first look, this seems to happen if brackets are found.

regards, marios

Last edited by marios (2007-10-02 20:38:02)


⌃ ⇧ < ⌃ ⇧ >

Offline

Board footer

Powered by FluxBB