Array - problem solved... it´s always like this...

From: Date: Tue, 09 Apr 2002 00:06:04 +0000
Subject: Array - problem solved... it´s always like this...
Groups: php.smarty.general 
Request: Send a blank email to php-smarty-general+get-3567@lists.php.net to get a copy of this message
HI, ...you know that strange kind of magic: You are really trying hard, getting crazy about a problem and you don´t get it, but one minute AFTER you post your question to some mailinglist, you get the idea and then it works? Strange... I did it like this: {foreach from=$cats item=item key=key} <option value="{$key|catselect}">{$item.0|catindent:$item.1}</option> {/foreach} (catselect and catindent are simple modifiers.) (ok, it was simple, sorry, but I didn´t sleep too much since I found smarty this weekend, it´s so exciting, I am rebuilding everything with it now :)) btw the modifiers feature is really fantastic and saves so much typing... I tried to do something similar with IT[X], but it´s far away from being really usable. I was working with phplib-templates first, then after beeing frustrated about how to handle conditional output with that, I tried IT[X], which helps a lot, compared to phplib-templates, but after short time you get even more frustrated about the restrictions and problems you have to deal with, too many pitfalls nobody wrote anywhere about. And now smarty, man this is a real big step! It is so great to work with it, finally I realize, how much time I spent building everything around a half-finished template-engine, asking myself with every new idea "how to get it to work with that". Smarty is a real good helper, it extends my possibilities without having to deal with any restrictions - my english is too bad, to express that positive vibrations I feel... :) THANK YOU, this is really great, and a lot of PEACE, btw... Have a nice day, Jones

« previous php.smarty.general (#3567) next »