Hi,
Let me try to explain what I'm trying to accomplish. I have a form
that I will be submitting using Ajax. Then I have 100 divs that I will
update based on the info submitted in the form. The form only has two
fields, a number from 00 to 99, and an amount field. It is like a
playing board. I have a table made using css with the numbers from 00
to 99 and next to each number is a div, that is named Q##(being ## the
specific number).

So, if the user inputs 25 in the number field, and 100 in the amount,
I need to update the div Q25 with the 100.

I was able to update the div successfully using fixed numbers, but I
can't find a way to use a variable in the update.

echo $ajax->submit('Submit', array('url' => 'agregartest', 'update' =>
'q25'),null, false);

echo $ajax->div('q25');
echo ' Primernum: ' . $this->data["Jugada"]["primernum"];
echo $ajax->divEnd('q25');

I tried using 'update' => 'q' . $this->data["Jugada"]["primernum"]
(Jugada is the model name, and primernum the field name)
but it didn't work. I thought that I could use the update option
inside the After callback, but it didn't seem to work.

Any suggestions on how I could do this?

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to