Can you suggest how i do this...was hoping to add this to my asp.net code instead of jquery ..easier tomanage in this instance
From: [email protected] [mailto:[email protected]] On Behalf Of Michael Ridland Sent: Tuesday, 19 April 2011 2:13 PM To: ozDotNet Subject: Re: add code to all button on my asp.net website? I was thinking of using jquery to modify the attribute on the actual html tag? On Tue, Apr 19, 2011 at 2:09 PM, Anthony <[email protected]> wrote: I'm pretty sure jquery will override the event. -----Original Message----- From: [email protected] [mailto:[email protected]] On Behalf Of DotNet Dude Sent: Tuesday, 19 April 2011 1:46 PM To: ozDotNet Subject: Re: add code to all button on my asp.net website? i don't think it'd be actually overriding the event handler, it is just appending so should be ok On Tue, Apr 19, 2011 at 12:56 PM, Anthony <[email protected]> wrote: > Would this retain any javascript code created by asp.net eg form validation > etc? If i override the onclick event then form validation etc is not > executed > > > > From: [email protected] [mailto:[email protected]] > On Behalf Of Michael Ridland > Sent: Tuesday, 19 April 2011 12:38 PM > To: ozDotNet > Subject: Re: add code to all button on my asp.net website? > > > > You could do it with jQuery Very Easily. > > > On Tue, Apr 19, 2011 at 12:28 PM, Anthony <[email protected]> wrote: > > I want add the following to all button on my website i.e. > button.Attributes.Add("onclick", ClientScript.GetPostBackEventReference(butt on, "") + ";this.value='Processing Credit Card Payment...';this.disabled = t rue;") > > > > Is there an easy to automatically apply this to all buttons? > > > > regards > > Anthony (*12QWERNB*) > > > > > >
