logo       
Google Custom Search
    AddThis Social Bookmark Button
-->

Re: associative arrays with template_flexy ?: msg#00492

Subject: Re: associative arrays with template_flexy ?
>Well, i had the same problem , but i think using objects is the better
>way, so you can then use a syntax like : {element->value}.
>

Thanks for the hint! Anyway, I still prefer to work with arrays so I don't
need to declare a variable for each chunk in the element class. For
example:

class controller {
var $chunks = array();
...
 function set_chunk($key, $value) {
  $this->chunks[$key] = $value;
 }
}

Regards,

Daniel





-- 
PEAR General Mailing List (http://pear.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




<Prev in Thread] Current Thread [Next in Thread>