On Sep 14, 2007, at 8:38 AM, Brian Williams wrote:

> i think there is more than one issue.
>
> 1st) change your method to post

He's given no reason to make this assumption. In general (there are  
some minor exceptions), use GET if doing a db SELECT, and POST if  
doing an UPDATE, INSERT, DELETE, etc.

> 2nd) move the onclick (i presume on the submit button) to onsubmit  
> in the form tag proper.

Agreed.

> 3rd) make sure the function returns false to stop the page from  
> changing

That depends on how the observer was assigned.  A more consistent  
(and cross-browser) way would be to use Event.stop.


TAG




--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Spinoffs" 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/rubyonrails-spinoffs?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to