Re: [PHP] Generating variable names 'on the fly'

2001-09-21 Thread Marcus Rasmussen
You can allso do like this: $i = 1; ${"test". $i} = "123"; echo $test1; ___ Marcus Rasmussen [EMAIL PROTECTED] On 21-09-01 at 11:21 _lallous wrote: >you can always use eval to create a variable too! > >$i = 1; >eval("\$test$i=123;"); >echo $test1; >?> > >

[PHP] Generating variable names 'on the fly'

2001-09-20 Thread Neil Freeman
Hi there, How do I generate variable names 'on the fly'? I wish to have variable names along the lines of $genre_category_1, $genre_category_2, $genre_category_3 etc. Ideally it would be along the lines of this... ### $current_field_number = 1; $genre_number_fields = 7; whi