seaside javascript builders
Hi all, I'm confused about the limitations and intended use of Seaside's javascript builders. I can follow that we can do eg: "(html jQuery: 'div') remove" or "html javascript alert: 'hello'" within the "renderContentOn: html" methods, but how do I deal with logic and variables? How do I eg. install an event listener and provide a browser-side function that extracts data from the event and then passes it to the server via "html jQuery ajax"? Is this something to be done in pure JS returned from the #script method? Thanks for any enlightenment! Siemen -- View this message in context: http://forum.world.st/seaside-javascript-builders-tp4926336.html Sent from the Pharo Smalltalk Users mailing list archive at Nabble.com.
On Fri, Dec 9, 2016 at 9:20 PM, Siemen Baader <siemenbaader@gmail.com> wrote:
Hi all,
I'm confused about the limitations and intended use of Seaside's javascript builders. I can follow that we can do eg: "(html jQuery: 'div') remove" or "html javascript alert: 'hello'" within the "renderContentOn: html" methods, but how do I deal with logic and variables? How do I eg. install an event listener and provide a browser-side function that extracts data from the event and then passes it to the server via "html jQuery ajax"?
Is this something to be done in pure JS returned from the #script method?
Thanks for any enlightenment!
Siemen
Hi Siemen, Sorry I can't help, I'm not a seaside user - but depending on your response here you might also like to try http://www.seaside.st/community/mailinglist cheers -ben
Thanks, I was unaware of the seaside list! cheers, Siemen On Fri, Dec 9, 2016 at 5:18 PM, Ben Coman <btc@openinworld.com> wrote:
On Fri, Dec 9, 2016 at 9:20 PM, Siemen Baader <siemenbaader@gmail.com> wrote:
Hi all,
I'm confused about the limitations and intended use of Seaside's javascript builders. I can follow that we can do eg: "(html jQuery: 'div') remove" or "html javascript alert: 'hello'" within the "renderContentOn: html" methods, but how do I deal with logic and variables? How do I eg. install an event listener and provide a browser-side function that extracts data from the event and then passes it to the server via "html jQuery ajax"?
Is this something to be done in pure JS returned from the #script method?
Thanks for any enlightenment!
Siemen
Hi Siemen,
Sorry I can't help, I'm not a seaside user - but depending on your response here you might also like to try http://www.seaside.st/community/mailinglist
cheers -ben
I guess that's where passengers: come handy. Because what you pass can be the result of a jQuery. TBH sometimes it is easier to do a JSStream on: 'some js code that does what you want' instead of wondering for ages how to do the same with the Javascript classes, subclasses and methods. Look into the test packages for lots of examples. That helped me. Phil On Fri, Dec 9, 2016 at 2:20 PM, Siemen Baader <siemenbaader@gmail.com> wrote:
Hi all,
I'm confused about the limitations and intended use of Seaside's javascript builders. I can follow that we can do eg: "(html jQuery: 'div') remove" or "html javascript alert: 'hello'" within the "renderContentOn: html" methods, but how do I deal with logic and variables? How do I eg. install an event listener and provide a browser-side function that extracts data from the event and then passes it to the server via "html jQuery ajax"?
Is this something to be done in pure JS returned from the #script method?
Thanks for any enlightenment!
Siemen
-- View this message in context: http://forum.world.st/seaside- javascript-builders-tp4926336.html Sent from the Pharo Smalltalk Users mailing list archive at Nabble.com.
Thanks, that was very helpful! Siemen Sent from my iPhone On 09/12/2016, at 19.45, "phil@highoctane.be" <phil@highoctane.be> wrote:
I guess that's where passengers: come handy.
Because what you pass can be the result of a jQuery.
TBH sometimes it is easier to do a JSStream on: 'some js code that does what you want' instead of wondering for ages how to do the same with the Javascript classes, subclasses and methods.
Look into the test packages for lots of examples. That helped me.
Phil
On Fri, Dec 9, 2016 at 2:20 PM, Siemen Baader <siemenbaader@gmail.com> wrote:
Hi all,
I'm confused about the limitations and intended use of Seaside's javascript builders. I can follow that we can do eg: "(html jQuery: 'div') remove" or "html javascript alert: 'hello'" within the "renderContentOn: html" methods, but how do I deal with logic and variables? How do I eg. install an event listener and provide a browser-side function that extracts data from the event and then passes it to the server via "html jQuery ajax"?
Is this something to be done in pure JS returned from the #script method?
Thanks for any enlightenment!
Siemen
-- View this message in context: http://forum.world.st/seaside-javascript-builders-tp4926336.html Sent from the Pharo Smalltalk Users mailing list archive at Nabble.com.
participants (3)
-
Ben Coman -
phil@highoctane.be -
Siemen Baader