[Seaside] Re: Help with JQuery example

squeakman squeakman at gmail.com
Thu Aug 23 22:08:15 UTC 2012


Hello Again,

The callback for the onClick works but now I am stuck on getting the 
callback for the button to be called - the one with the comment 
"non-ajax callback" in the code below.

I read on the web that: "Instead put your callback code into the jQuery 
callback itself, aka the #script: block."  This is what I am trying to 
do below but it failed along with a few other experiments I tried.

What I want to do is trigger the form so that all the various callbacks 
are called.

Can you offer any help with this?

Thanks again,
Frank

----- code follows ----

renderContentOn: html

(html form)
	id: #form;
	with:
		[html label with: 'Name'.
		(html textInput)
			id: #temp;
			value: 'sample text'.

		(html button bePush)
			onClick: (html jQuery ajax
				callback: [:v | self halt]
				value: (html jQuery: #temp) value);

			onClick: (html jQuery ajax script:
				[:s | (s jQuery: #form) triggerSubmit]);

			callback: [self halt];    " non-ajax callback"
			with: 'Pay >']




More information about the seaside mailing list