> while(list($key, $val) = each($cb)) {
>  if ($val == 1 && $key != 0) {
>   $acc = $key;
> } else {
>   $acc = $acc.",".$key;
> }

This looks syntactically correct.

> }
> // by the way this: $acc=.$key would be a valid command? like the c++ $a =+
> $b

I usually use (for a string):
.=  
that would be:
$foo .= "old foo plus more stuff";
is the same as
$foo = $foo . "old foo plus more stuff";

in PHP you use += for mathimatics.

> 
> in this solution I store all the indexes that have a value 1 or that are
> setted.. so let's say tha the user had click in 2,4,8,25 I would have
> $acc=2,4,8,25... later on I explode that and I will have the clicks...
> 
> What do you think?

well, now you have the values.  You need to state them.  Either print
them to "hidden" HTML input tags or save and retrieve them from the
DB.

:)
Jeremy

Jeremy Brand :: Sr. Software Engineer :: 408-245-9058 :: [EMAIL PROTECTED]
http://www.JeremyBrand.com/Jeremy/Brand/Jeremy_Brand.html for more 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    "LINUX is obsolete"  -- Andy Tanenbaum, January 29th, 1992
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
       http://www.JEEP-FOR-SALE.com/ -- I need a buyer
  Get your own Free, Private email at http://www.smackdown.com/


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to