Textpattern CMS support forum

You are not logged in. Register | Login | Help

#201 2011-01-07 08:04:30

laptophobo
Member
Registered: 2010-03-01
Posts: 216
Website

Re: [plugin] [ORPHAN] rss_auto_excerpt

Yes, that totally worked. Here is what my form looks like:

<txp:article status=“sticky” form=“static_text” limit=“1” />

<txp:article> <txp:if_article_list>

<h3><txp:permlink><txp:title /></txp:permlink></h3> <p><txp:posted format=”%m-%d-%Y” /></p>

<txp:excerpt /><p><a href=”<txp:permlink />” title=”<txp:title />”> Read More </a></p> <txp:else/>
<h2 class=“entry-title”><a href=”<txp:permlink />”><txp:title /></a></h2>

<txp:body /> </txp:if_article_list>
</txp:article>


Living the Location-Independent Life: www.NuNomad.com

Offline

#202 2011-01-07 10:44:38

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

Re: [plugin] [ORPHAN] rss_auto_excerpt

rss_auto_excerpt creates excerpts auomatically. Standard use is stand alone or inside an if_excerpt tag. if_excerpt answers ‘No’, well, rss_auto_excerpt can create an excerpt.

If you have excerpts and you want to show the full excerpt then rss_auto_excerpt is not needed.

but when I get the list to work as only excerpts, it carries that command over to the full article page.

Check your if/else logic. Somewhere along the way a <txp:body /> is missing :)

Edit: Laptophobo, pls. don’t start a txp:article if/else discussion here in this rss_auto_excerpt specific thread.

Last edited by merz1 (2011-01-07 10:51:33)


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

Offline

#203 2011-01-07 10:58:52

laptophobo
Member
Registered: 2010-03-01
Posts: 216
Website

Re: [plugin] [ORPHAN] rss_auto_excerpt

Hi Markus. Yup, that’s what I didn’t do. Hadn’t added the body tag. But, it seems okay now. I’ll also look into the plug-in option as well.

Thanks for helping!


Living the Location-Independent Life: www.NuNomad.com

Offline

#204 2011-01-11 21:52:49

hicks
Member
From: Portland, OR, USA (ex-UK)
Registered: 2009-05-08
Posts: 106
Website

Re: [plugin] [ORPHAN] rss_auto_excerpt

Is there a way to override the auto-excerption if the full body is only x words/whatever longer than it? There must be… seems silly to excerpt the first 100 words if the entire article is only 102, for example.
Thanks,
hicks.

Offline

#205 2011-01-12 08:00:39

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

Re: [plugin] [ORPHAN] rss_auto_excerpt

Hicks, the logic which comes to my mind is to publish/copy such short ‘bodies’ also inside the TXP excerpt field and to not override the TXP excerpt.

Last edited by merz1 (2011-01-12 08:03:28)


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

Offline

#206 2011-01-12 18:45:02

hicks
Member
From: Portland, OR, USA (ex-UK)
Registered: 2009-05-08
Posts: 106
Website

Re: [plugin] [ORPHAN] rss_auto_excerpt

Markus,

Good idea, thanks. Trouble is, I have been using the excerpt field for each posting’s footnotes. I was hoping I could do this thing automatically, but my only option might be to add a custom field called “no auto-excerpt” and have an if_custom_field.... set up in the article form to hit the RSS plug-in or else a bog-standard body tag.

If only there were a <txp:xxx_if_article_length characters="500"> or the like… I have the illustrious Stef Dawson’s smd_article_stats that can return the number of words, but there’s no way to get an “if” in there.

hicks.

Last edited by hicks (2011-01-12 18:55:20)

Offline

#207 2011-01-12 19:15:15

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

Re: [plugin] [ORPHAN] rss_auto_excerpt

What about using smd_article_stats inside of a txp:variable? Adding an appropriate if/else comes to my mind (II.)…

Edit: What about asking for a category like ‘short’?

Edit 2: I am sure plain PHP str_word_count can help too to define a variable (PHP count_chars won’t help).

Last edited by merz1 (2011-01-12 19:33:37)


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

Offline

#208 2011-01-12 19:25:50

johnstephens
Plugin Author
From: Woodbridge, VA
Registered: 2008-06-01
Posts: 981
Website

Re: [plugin] [ORPHAN] rss_auto_excerpt

Textile 2.2 supports footnotes, without requiring an extra field:

From the Textile 2.2 Reference Guide

Auto-numbered notes

When referencing or citing sources in body text you can employ footnotes. But these are explicitly numbered and if you therefore alter the order of the references (by inserting one or deleting/moving others) you must manually renumber all the footnotes in the article.

Using notes you can label references in your body text, set up a definition for each of those labels, and then display the list of references at a suitable place in your body text. Crucially, the numbers will be automatically assigned when you save the article and recalculated if necessary as you alter the document.

Also:

1. References from the main body may be hyperlinked to the references section or not — either globally or on a note-by-note basis
2. Notes listed in the references section can optionally backlink to the place(s) they were used. Again, you can globally control whether backrefs are employed and, if so, whether the backref is just the first occurrence of the reference or all cited references. You may also override the backrefs on a note-by-note basis

If you’re already running Textpattern 4.3.0, then Textile 2.2 is already included. You can also upgrade Textile independently by replacing classTextile.php with the new one in Textpattern’s lib/ directory.

If you absolutely require a separate field for footnotes— say, to present the footnotes without the body text in another context —it would be best to use a custom field rather than appropriating a purposeful native field in Textpattern. There’s nothing wrong with using the native Excerpt field for whatever data you want, but it might mean you run into situations like this where a kludge is required for functionality that assumes the native field is used for it’s intended purpose.

Edit: Fix a typo. Dang.

Last edited by johnstephens (2011-01-12 19:28:04)

Offline

#209 2011-01-12 19:41:04

hicks
Member
From: Portland, OR, USA (ex-UK)
Registered: 2009-05-08
Posts: 106
Website

Re: [plugin] [ORPHAN] rss_auto_excerpt

I can’t see a way of using the if_variable with a _morethan_-type condition. That would be nice, though.

glz_custom_fields could be a neat manual answer, but as I only want one little checkbox, given the fee demanded by glz I might look elsewhere.

hicks.

Offline

#210 2011-01-12 19:48:21

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

Re: [plugin] [ORPHAN] rss_auto_excerpt

Well, then you have to dive into Blokes smd_if: Generic multiple if condition tests. You have been warned :)


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

Offline

Board footer

Powered by FluxBB