|
Posted by Jochem Maas on 10/04/95 11:23
edwardspl@ita.org.mo wrote:
>>>How can we define and display the varibles by using for loop
>>>function ?
>>
>><?php
>>for ($x=0;$x<10;$x++){
>> $func[$x]=$x;
>>}
>>print_r($func);
>>?>
>
>
> If I want to define a set of varibles ( two dimension array, eg : $func[0,0] )
$func[0,0] is not valid syntax. you mean $func[0][0]
> and via the varibles of form tag ( format, eg : $_GET["varname"] or
> $_POST["varname"] )...
> How about the example ?
watch what happen to $_POST when you stick these fields in your form
and submit it:
<input type="text" value="a" name="test[a]" />
<input type="text" value="b" name="test[b]" />
<input type="text" value="c" name="test[c]" />
<input type="text" value="d1" name="test[d][]" />
<input type="text" value="d2" name="test[d][]" />
>
> Edward.
>
Navigation:
[Reply to this message]
|