[ic] Filter doesn't interpolate by default? Wha...?

Peter peter at pajamian.dhs.org
Sun Nov 28 08:39:06 UTC 2010


On 28/11/10 18:16, Paul Jordan wrote:
>> From: peter at pajamian.dhs.org
>> On 28/11/10 04:25, Paul Jordan wrote:
>> > most, if
>> > not all other tags default interpolate=yes, reparse=no.
>>
>> Actually the default for all tags is interpolate=no reparse=yes unless
>> changed by the UserTag directive's Interpolate or NoReparse attributes.
>  
> What the F batman. I don't see how I could have thought the opposite for
> the last 10 years.  :-)
>  
> Maybe I had it wrong all this time?
>  
> [if scratch foo][scratch bar][/if]
>  
> I thought that Interpolation meant that when this IF tag evaluates, that
> it's output will be whatever is stored inside [scratch bar]. If
> Interpolate is off, then when this IF evaluates it will place [scratch
> bar] verbatim, square brakets and all, to the page. Reparse on the other
> hand, I always thought meant that if turned on in this example, would
> process ITL tags that may be contained inside the storage of the scratch
> "bar" (kinda like recursion).

Nope, interpolate is done on the input side of container tags and
reparse is done on the output side.  If the [if] tag interpolated then
something like this wouldn't work like you think:

[if scratch bounce][bounce page="[scratch bounce]"][/if]

The above would always run the bounce tag if [if] interpolated it's
input.  Since it reparses instead then the above bounce tag only runs if
the test condition results in a true value.

> Is that wrong? With my assumptions all this time, things have worked
> pretty much as expected.
>  
> Furthermore, I'd swear on my ex-girlfriends grave that the docs used to
> reflect interpolate=true, reparse=false. I remember back when I first
> got into this - it's very clear in my memory.

http://www.interchange.rtfm.info/icdocs/tags/if.html?id=SpvRtwRZ#Summary


Peter




More information about the interchange-users mailing list