PREFIX-field
Summary
Description
Looks up a column value for the current row in one of several places,
in this order:
- The first DefaultTables table.
- Additional DefaultTables table(s) in the order they occur.
- The attribute value for the row in a hash list.
- 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: