array elements in a .ini file

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

array elements in a .ini file

Mike Wright
Hi all,

(3 hrs later) I know I've seen this explained before but searching for
non-alphanumeric characters just doesn't google and I can't find it
again anywhere.

How do I specify within a config.ini file an element whose name may be
an array?

e.g.
<input name='test[i]' type='text' />

elements.test[].type = "text"  ;doesn't work.  (and you'd probably get a
good laugh out of some of the things I've tried ;)

Thanks!
Mike Wright
Reply | Threaded
Open this post in threaded view
|

Re: array elements in a .ini file

David Mintz


On Thu, Feb 25, 2010 at 2:55 PM, Mike Wright <[hidden email]> wrote:
Hi all,

(3 hrs later) I know I've seen this explained before but searching for non-alphanumeric characters just doesn't google and I can't find it again anywhere.

How do I specify within a config.ini file an element whose name may be an array?

e.g.
<input name='test[i]' type='text' />

elements.test[].type = "text"  ;doesn't work.  (and you'd probably get a good laugh out of some of the things I've tried ;)

Just a wild guess, because this is not my strong suit, but --- the solution may be to forget about array notation and have a look at belongsTo.


--
Support real health care reform:
http://phimg.org/

--
David Mintz
http://davidmintz.org/


Reply | Threaded
Open this post in threaded view
|

Re: array elements in a .ini file

Bart McLeod
My guess would be that you can't do this using ini configuration. It is limited compared to custom OO forms. And correct documentation is hard to find.

-Bart

Op 25-2-2010 22:27, David Mintz schreef:


On Thu, Feb 25, 2010 at 2:55 PM, Mike Wright <[hidden email]> wrote:
Hi all,

(3 hrs later) I know I've seen this explained before but searching for non-alphanumeric characters just doesn't google and I can't find it again anywhere.

How do I specify within a config.ini file an element whose name may be an array?

e.g.
<input name='test[i]' type='text' />

elements.test[].type = "text"  ;doesn't work.  (and you'd probably get a good laugh out of some of the things I've tried ;)

Just a wild guess, because this is not my strong suit, but --- the solution may be to forget about array notation and have a look at belongsTo.


--
Support real health care reform:
http://phimg.org/

--
David Mintz
http://davidmintz.org/



--
Bart McLeod
Space Web
Middenlaan 47
6865 VN Heveadorp
The Netherlands
t +31(0)26 3392952
m 06 51 51 89 71
@ [hidden email]
www.spaceweb.nl
zce logozce PHP 5 logo zce Zend Framework logo

Bart McLeod is a Zend Certified Engineer.

Click to verify!