[pmwiki-users] TextExtract (Search recipe) update

ABClf languefrancaise at gmail.com
Thu Oct 1 18:09:30 CDT 2009

Hi Hans,
My purpose here is to test if one can use TextExtract in place of
conventional Include with something like
(:pagelist .* regex=1 fmt=extract page=*.*#section#sectionend :)

On some pages I have an anchored todo section enclosed like this :


Then, I would like to use TextExtract new capabilities to extract all text
enclosed between the anchors [[#afaire]] & [[#finafaire]].
Here there are my tests and my trouble :

(:pagelist vérifier fmt=extract page=Argot.*#afaire#finafaire name=-Afaire
result : I got the lines where there is the word /vérifier/ in pages from
goup Argot, source limited to the section, nice.
But as I need everything is enclosed between anchors, I will use regex
option and /.*/ as searched pattern. I wish I'm right.

(:pagelist .* regex=1 fmt=extract page=Argot.*#afaire#finafaire name=-Afaire
Here is the trouble (see next test for comparing), result : Found no

(:pagelist .* regex=1 fmt=extract page=Argot.* name=-Afaire count=10:)
Works : give me all text from 10 pages.

So : if I use regex=1 and limited search in anchored sections, there is a
problem that disappear if I don't use anchored sections.

Test can be seen there :
(visible password)

Thank you for your interest,

2009/9/28 Hans <design5 at softflow.co.uk>

> Monday, September 28, 2009, 12:06:36 AM, Hans wrote:
> > And I need to think about point 2. if it is right to allow rows
> > which have no matches, because they have been removed in the process.
> Now available in latest release version 2009-09-28
> If snip='pattern' removes the match in a row, the row will still be
> passed as result output, and the match count will be tasaken from the
> row before the snipping, so you get a positive result number,
> even though no match is highlighted (because snip='pattern' removed it).
> usefult to get text extract by looking for keywords/markers in the
> text without showing these for instance.
>  ~Hans
> _______________________________________________
> pmwiki-users mailing list
> pmwiki-users at pmichaud.com
> http://www.pmichaud.com/mailman/listinfo/pmwiki-users

| A | de la langue française
| B | http://www.languefrancaise.net/
| C | languefrancaise at gmail.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.pmichaud.com/pipermail/pmwiki-users/attachments/20091002/e9d25a55/attachment.html 

More information about the pmwiki-users mailing list