New plugin: summary (aka extended entry)

David Ascher <[email protected]>
Newsgroups gmane.comp.web.pyblosxom.user
Message-ID <[email protected]>
http://www.ascher.ca/software/pyblosxom/summary.py

I use this plugin to create index pages which show just a paragraph
representative of a full story, instead of showing the entire story on
the index page.

This plugin creates (in cb_postformat) a $summary variable which
corresponds to the parse of a highlighted part of the entry indicated
by matching '(((' and ')))' tokens on lines by themselves. 

It also contains the logic to use a 'summary' flavour, which you
should create, using the new $summary variable, when displaying index
pages.

Sample entry:

    Title of the entry
    
    (((
    This is the summary of the entry.  It can
    be formatted however your entries are normally formatted.
    )))
    
    This is the body of the entry as it will be reflected in the
    $body variable
    
This plugin works with entry parsers as long as the ((( and ))) tokens
stay on a single line in the parsed output (and aren't merged with
preceding or following lines). I've tested it with the plain parser
and txtl parser.

Enjoy.

--david

PS: Thanks to Will for the help!


-------------------------------------------------------
SF.Net email is sponsored by Shop4tech.com-Lowest price on Blank Media
100pk Sonic DVD-R 4x for only $29 -100pk Sonic DVD+R for only $33
Save 50% off Retail on Ink & Toner - Free Shipping and Free Gift.
http://www.shop4tech.com/z/Inkjet_Cartridges/9_108_r285
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.