Hello Everyone,
I'm having trouble sending array values through forms.
Will the following syntax create a variable called $product['desc'] on
the next page?
If not, what am I doing wrong here?
Note: I tried this but it didn't work! When I tried doing it without
using an array, but rather with a
Try:
input type=text name=product[]
?
foreach ($product as $p) {
print $p;
}
?
On Mon, 20 May 2002 11:05:07 +1200, Navid Y. wrote:
Hello Everyone,
I'm having trouble sending array values through forms. Will the
following syntax create a variable called $product['desc'] on the
On Monday 20 May 2002 07:05, Navid Y. wrote:
Hello Everyone,
I'm having trouble sending array values through forms.
Will the following syntax create a variable called $product['desc'] on
the next page?
If not, what am I doing wrong here?
Note: I tried this but it didn't work! When I tried
Your code looks fine. Are you sure you haven't edited away significant
parts of it when posting to the list? Maybe a input name=product
somewhere?
miguel
On Sun, 19 May 2002, Navid Y. wrote:
I'm having trouble sending array values through forms.
Will the following syntax create a variable
1) The example you have shown should work. Take a look at the foreach controle
structure. (Link at bottom of mail.)
2) You cannot assign a value to a checkbox. It can only be set by the checked
keyword (ie: input type=checkbox name=foo checked.)
3) The value of a checked checkbox is on. If a
Hi all,
I have a form, with about 40 checkboxes, I want to write a PHP document that
processes the submission and displays the values of the checkboxes that were
checked.
Pretty basic stuff, I've tried a few different things, some work but display
Array at the top of the list of values.
On Wed, 24 Apr 2002, Liam MacKenzie wrote:
Snippet of PHP
while ( $element = each( $games ) )
{
echo $element[value];
echo br;
}
/Snippet of PHP
I tried this too, it gave the same results as the above...
if (is_array($games)) {
for ($z=0;$zcount($games);$z++) {
echo
Hi, I have a multi-select listbox set up like this:
Author (you are able to select more than one.a href=addauthor.phpClick
here to add a new author/a)br:
select name=author multiple size=5
?php
$result = mysql_query(SELECT AUTHOR_ID, AUTHOR_FNAME, AUTHOR_LNAME FROM
AUTHORS;) or
mysql_auery($query) or die(echo mysql_error());
By the way, I know this line should be mysql_query
John Meyer
[EMAIL PROTECTED]
Programmer
If we didn't have Microsoft, we'd have to blame ourselves for all of our
programs crashing
--
PHP General Mailing List
Can someone please help me with this code I'm having major problems with
arrays. This code is part of a function I'm writing to deal with an array
returned from a HTML form of check boxes so if anyone has an example of this
sort of thing I'd appreciate a look at it. Anyway Code follows :
"Jamie" [EMAIL PROTECTED] wrote:
$results = mysql_query("SELECT option_type, code FROM options WHERE
code='000' ORDER BY option_type",$db);
mysql_fetch_array($results);
// From what understand I should have an array some thig like this:
// ("Size"="A4" , "Size" = "A3", "Size"="A5",
11 matches
Mail list logo