Date: 04/14/01
- Next message: Jens Benecke: "Re: [phplib] templates: toggling blocks"
- Previous message: Jens Benecke: "[phplib] templates: toggling blocks"
- In reply to: Jens Benecke: "[phplib] templates: toggling blocks"
- Next in thread: Jens Benecke: "Re: [phplib] templates: toggling blocks"
- Reply: Jens Benecke: "Re: [phplib] templates: toggling blocks"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
On Sat, Apr 14, 2001 at 09:29:04PM +0200, Jens Benecke wrote:
> How would I accomplish this with PHPLIBs templates? Is there a cleaner
> solution than defining a CSS variable as {CSS} and then set_var'ing this
> over the result-loop? (which would mean that I'm not strictly separating
> design from code any more, which I dislike)
What about defining class alt1 and alt2 for the alternating rows
$class = ($class=="alt1") ? "alt2" : "alt1";
and then inject that using
$tpl->set_var("ROWCLASS",$class);
You can then define alt1 and alt2 in your stylesheet and give them
(independent from he code) any look you like. Seems seperated enough to
me...
Karsten
-- Why do we have to hide from the police, daddy? Because we use emacs, son. They use vi. ----------------------------- mailto:k.dambekalns <email protected> wł: http://www.k-fish.de/ gpg: http://www.k-fish.de/mykeys.gpg
- application/pgp-signature attachment: stored
- Next message: Jens Benecke: "Re: [phplib] templates: toggling blocks"
- Previous message: Jens Benecke: "[phplib] templates: toggling blocks"
- In reply to: Jens Benecke: "[phplib] templates: toggling blocks"
- Next in thread: Jens Benecke: "Re: [phplib] templates: toggling blocks"
- Reply: Jens Benecke: "Re: [phplib] templates: toggling blocks"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]

