I have an application that uses an array of values as a "lookup" table and
smarty as a template engine.
$lookup['stuff']['a'] = "label";
$lookup['stuff']['b'] = "label2";
$lookup['other']['a'] = "label";
$lookup['other']['b'] = "label2";
In my application I can easily use this array to find the values I need.
$data[ $lookup['other']['b'] ];
I want to assign my lookup value to the template, and have smarty perform
the matching, but for the life of me I can't get a smarty variable to modify
itself.
{$data.$lookup.other.b} doesn't work
{$data.$lookup[other][b]} also doesn't work.
I'd also like to use these in functions like
{html_checkboxes name="id" options=$data.$lookup.other.b
selected=$data.selected }
I've searched smarty forums, but looking for an instance of "array" in the
forums it too general, and I can't find anything that points to how to do
this.
Any help is appreciated.