For more information... RTFM!
NAVIGATION
PAGES THAT LINK HERE
ACCOUNT LOGIN

You are not logged in

Powered by Interchange version 5.7.0

PREFIX-field

Summary

  • [PREFIX-field column]

Description

This loop sub-tag looks up a column value for the current row in one of several places, in the following order:

  1. The first DefaultTables table.
  2. Additional DefaultTables table(s) in the order they occur.
  3. The attribute value for the row in a hash list.
  4. Blank.

A common user error is to do this:

[loop search=|
    fi=foo
    se=bar
|]
    [loop-field foo_col]
[/loop]

In this case, you are searching the "foo" table for a value of "bar".  When it is found, you want to display the value of foo_col.

Unless the "foo" table is in DefaultTables, and the code is not present in a table earlier than "foo" in the DefaultTables list, you will get a blank or some other value you were not expecting.

What you really want, in this case, is the [loop-data] tag, which would specifically address the "foo" table, as follows:

[loop-data foo column]

Category:  Looping tags and sub-tags
Last modified by: Kevin Walsh
Modification date: Wednesday 19 September 2007 at 5:14 PM (EDT)
Home  |  Legal nonsense  |  Privacy policy  |  Donations  |  Contact us