[pmwiki-users] (no subject)

Dave Cooke david at ellendee.co.uk
Wed Apr 11 16:46:25 CDT 2007


J. Meijer <commentgg <at> hotmail.com> writes:

> 
> 
> 
> You may try this:  # use {$FullTitle} in page;list templates
etc$FmtPV['$FullTitle'] = $FmtPV['$Title'];   # {$Title} is now for exclusive
use in pagelist, leading A & The stripped$FmtPV['$Title'] =
"preg_replace('^(A|The) ','',".$FmtPV['$Title'].")";What it does is substitute
{$Title} with a version that strips leading A & The. Pagelists will use this
value and therefore sort correctly. The original {$Title} is still available as
{$FullTitle}. Use this in pagelist templates and page text. Hope this helps,/jm
> On 4/11/07, david <at> ellendee.co.uk <david <at> ellendee.co.uk> wrote:I'm
putting together a couple of sites. One involves titles of books andthey both
involve peoples names. For the titles I need to ignore a leading'A' or 'The'
when sorting and for the names I'd like to sort on surname(last 'word' in
title).Are these possible?
> 
> 
> 
> 
> Take a break and play crossword puzzles - FREE! Play Now!
> 
> 
> _______________________________________________
> pmwiki-users mailing list
> pmwiki-users <at> pmichaud.com
> http://www.pmichaud.com/mailman/listinfo/pmwiki-users
> 

Thanks, but when I tried it all I got were repeating lines of Warning:
preg_replace(): No ending delimiter '^' found in
/home/ellendee/public_html/FolkLyrics/pmwiki.php(664) : eval()'d code on line 2





More information about the pmwiki-users mailing list