Hi there,
I followed this tutorial http://demo.grahambird.co.uk/tasks by Graham
Bird to do a task list.
It has a text box and a submit button that updates a div.
This is how the form is rendered:
<form onSubmit="return false;">
<?php
print $html->input('Task/title', array('id' => 'add_input'));
print $ajax->submit('Add task', array('url' => 'add',
'update'=>'tasks_todo'));
?>
</form>
Which works perfectly fine.
Now, here comes the but - I want this to be loaded as the content in
another div, like in a widget.
So I do an AJAX update and fill my widget with the form and the data.
Works to some extent but the submit button loses it's AJAX request.
Used stand alone, Firebug gives me this:
<script type="text/javascript">
Event.observe("submit24261", 'click', function(event){ new
Ajax.Updater('tasks_todo','/cake/tasks/add' ...
</script>
But this section falls away when I load the task list (with the form)
into a widget.
Anyone know why?
Thanks,
Mickster
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Cake
PHP" 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
-~----------~----~----~----~------~----~------~--~---