RE: [PEAR] Flexy problem

From: Date: Sun, 31 Aug 2003 19:57:30 +0000
Subject: RE: [PEAR] Flexy problem
References: 1  Groups: php.pear.general 
Request: Send a blank email to pear-general+get-7517@lists.php.net to get a copy of this message
I've had to do similar workarounds. It would be really nice to have direct access to associative arrays. I tried to see if I could write that in, but got to the lexer stuff and realized I was in over my head. Andy > -----Original Message----- > From: Kjetil Wikestad [mailto:wikestad@stud.ntnu.no] > Sent: Sunday, August 31, 2003 3:47 PM > To: pear-general@lists.php.net > Subject: Re: [PEAR] Flexy problem > > I have found a way around it. Created a function like this: > output($var,$array){ echo $array[$var]; } > > But in my eyes this is not a good solution. Why doesn't Flexy allow > associative arrays and is there any plans of implementing it? > > -- > Kjetil W. > > > Andy Crain wrote: > > I might be wrong on this, but to my knowledge you can't, sadly, output > > associative arrays in Flexy templates, only numeric-indexed arrays. I > > suspect that's the problem. > > Andy > > > > > >>-----Original Message----- > >>From: Kjetil Wikestad [mailto:wikestad@stud.ntnu.no] > >>Sent: Saturday, August 30, 2003 2:20 PM > >>To: pear-general@lists.php.net > >>Subject: [PEAR] Flexy problem > >> > >>Hi! > >> > >>I just started using Flexy and I like it so far. But there is a small > >>problem I can't overcome. This is my template: > >> > >>{foreach:tasklist,taskid,task} > >> <a > >>href="/tasks/view.task.php?{taskid}">{task[title]}</a><br> > >>{end:} > >> > >>I thought this would produce a list of links with task titles, but it > >>doesn't do that. Instead it produce "{task[title]}". How do I fix > > > > this? > > > >>-- > >>Kjetil W. > >> > >>-- > >>PEAR General Mailing List (http://pear.php.net/) > >>To unsubscribe, visit: http://www.php.net/unsub.php > > -- > PEAR General Mailing List (http://pear.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php

« previous php.pear.general (#7517) next »