[Seaside] Disable a submit button

Pablo Iaría iariap at tutopia.com
Thu Jul 24 14:42:30 CEST 2003


I've been using old versions of seaside but if you could add some javascript code to the html button to get like this:

<input type="Submit" value="Do something" onclick="this.disabled=true;return true">

... could work.


Pablo.-

On Thu, 24 Jul 2003 10:27 , Nevin Pratt <nevin at smalltalkpro.com> sent:

>I need to use Javascript to disable the submit button after it has been 
>clicked.  But, as I understand it,  the Javascript that does this would 
>need to know the button name, and the button name is dynamically 
>assigned by Seaside.
>
>What is happening on my Checkout page is, after hitting the Payment 
>Submit button, the user is occasionally hitting the "Back" button on the 
>browser, then looking at stuff, then hitting the "Forward" button, and 
>then clicking the Payment Submit button again.  This is resulting in 
>multiple charges (I'm manually correcting them for now, so the customer 
>doesn't see this error).  So, I need to disable the Payment button once 
>it has been clicked (and *without* the page having to be re-rendered or 
>reloaded).
>
>Anybody know how to do that?
>
>Nevin
>
>-- 
>Nevin Pratt
>Bountiful Baby
>http://www.bountifulbaby.com
>(801) 992-3137
>
>
>_______________________________________________
>Seaside mailing list
>Seaside at lists.squeakfoundation.org
>http://lists.squeakfoundation.org/listinfo/seaside






More information about the Seaside mailing list