RE: [PHP] Values from forms
| From: | Ford, Mike [LSS] | Date: | Tue, 05 Aug 2003 09:47:09 +0000 |
| Subject: | RE: [PHP] Values from forms | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-158254@lists.php.net to get a copy of this message | ||
> -----Original Message-----
> From: Beauford.2005 [mailto:beauford.2005@rogers.com]
> Sent: 05 August 2003 00:36
>
> Thanks for the info. The first suggestion doesn't work,
The first suggestion does work -- I've used it more than once in the past.
If it doesn't work for you, you're doing something wrong. But the array
solution is better.
> and the second
> may work - but the problem is I need the array to start at '1' - and
> arrays in general start at 0.
PHP arrays start wherever they start -- by default, if you don't specify
otherwise, they start at 0, but they can "start" with anything (e.g.
array('foo'=>'bar', 'plugh'=>'xyzzy') starts at
'foo') -- so if you want one
to start at 1 then just start it at 1.
Cheers!
Mike
---------------------------------------------------------------------
Mike Ford, Electronic Information Services Adviser,
Learning Support Services, Learning & Information Services,
JG125, James Graham Building, Leeds Metropolitan University,
Beckett Park, LEEDS, LS6 3QS, United Kingdom
Email: m.ford@lmu.ac.uk
Tel: +44 113 283 2600 extn 4730 Fax: +44 113 283 3211