Re: Multiple value selection box (mix php/html problem) **SOLUTION**

From: Date: Wed, 23 May 2001 15:13:31 +0000
Subject: Re: Multiple value selection box (mix php/html problem) **SOLUTION**
References: 1  Groups: php.windows 
Request: Send a blank email to php-windows+get-7875@lists.php.net to get a copy of this message
SUCCESS!!!! (man do I feel STOOPID!!) A duh .... my cursor was at the end of the array (THIS WHOLE TIME!!) The reset was needed trick Thanks M@ Matt Williams wrote:
Hi Michael Just tried this --------------------------------- <form name="form1" method="get" action="<?= $PHP_SELF; ?>"> <select name="list[]" size="3" multiple>
    <option>1</option>
    <option>2</option>
    <option>3</option>
</select> <input type="submit" name="Submit" value="Submit"> </form> <? reset ($list); while (list ($key, $val) = each ($list)) {
    echo "$key => $val<br>";
}     ?>
------------------------------------ And it prints 0 => 1 1 => 2 2 => 3 OK on to the few HTML probs I've found They are tabnle related really. no opening table tag closing table tag comes before closing row tag and closing select no <td> or </td> maybe it would be easier to break out of php into html to set up your table and maybe use <td align="center"> instead of all the <center> tags HTH M@
-- Michael Kelley mkelley@nmsu.edu Programmer/Systems Analyst I New Mexico State University Information and Communication Technologies Work # (505)-646-1374 P.O. Box 30001 MSC: 3AT Las Cruces, NM 88003

« previous php.windows (#7875) next »