[ic] Interpolating sql results
Peter
peter at pajamian.dhs.org
Fri Jan 5 05:14:50 EST 2007
On 01/05/2007 02:01 AM, graham hadgraft wrote:
> I have a sql-field which along with text contains interchange tags. e.g.
>
> this text is [filter keyword]filtered[/filter]
>
> Where the keyword filter creates a link using the contained word.
>
> The filter works outside of the sql-param tag and creates a link
> however this filter exists in the text of an sql field and when i
> print the sql-results like the following.
>
> [query type=list sql=|SOME QUERY|]
> [sql-param fieldname]
> [/query]
>
> it prints the text [filter keyword] and [/filter] rather than running
> the filter.
>
> I have tried placing interpolate=1 in both the query tag and the
> sql-param tag neither would run the filter.
>
> The query and the filter work just not together. How can i get it to
> run the filter before returning the contents of the field
Try reparse=1 on the [query] tag, you may also need safe_data=1.
Note that with both reparse=1 and safe_data=1 you will be interpolating
all data that is displayed in that query. Do not under any
circumstances display the contents of a field that you do not 100% trust
to be safe.
Peter
More information about the interchange-users
mailing list