[Pmwiki-users] Re: [[include: ... ]] part of a page

John Rankin john.rankin
Mon May 3 20:48:24 CDT 2004


On Tuesday, 4 May 2004 1:00 PM, Patrick R. Michaud <pmichaud at pobox.com> wrote:
>On Sat, Apr 17, 2004 at 04:05:54PM +0200, Christian Ridderstr?m wrote:
>> 
>> which we want to give a meaning. Now, I like the notation
>> 
>> 	[[para:PageName#anchor]]
>> 
>> which allows me to include only a single paragraph from a page, and I'd
>> like to assign this to [[include:PageName#anchor]].
>
>I'm working on an implementation, but the above brings up a question--
>what constitutes a "paragraph" in the above?  Which of the following
>is (or should be) a "paragraph" in Christian's sense of the
>word...
>
>  - just the markup line containing the anchor
>  - all lines from the markup line containing the anchor up to the
>    next line containing some other anchor
>  - all lines from the markup line containing the anchor up to the
>    next blank line
>
>Pm
>
>-- 
>Pmwiki-users mailing list
>Pmwiki-users at pmichaud.com
>http://pmichaud.com/mailman/listinfo/pmwiki-users_pmichaud.com
>

I sort of think it should be up to the next end-of-line character, 
because I think

[[#anchor]]What should be included:
# the current line
# lines to the next anchor
# lines to the next blank line

ought to return (IMO) "What should be included:"

I think we can discount 2, because that would be 
  [[include:Page#from#to]] 
if I interpret Christian's proposal correctly. 
3 would be OK, but my perference is for 1.

FWIW, in the [[para:Page#anchor]] markup extension, 
the code treats:

[[#anchor]]
What should be included:

as if the author had omitted the return after [[#anchor]] 
ie it returns "What should be included:"

I couldn't think of a case when one would want it to return 
an empty string.
-- 
JR
--
John Rankin





More information about the pmwiki-users mailing list