[Seaside] How do I call a method from renderContentOn:
ld
s001 at landr.net
Tue Apr 13 04:44:51 CEST 2004
I'm new to Seaside. It seems very powerful, if I could just understand
it better. I have worked through the tutorial, and thought I'd practice
by modifying the WACounter example to change the change 'interval' from
the browser.. I added a 'interval' variable. Then added a
selectFromList to 'renderContentOn:' to quickly change the interval
that the counter is incremented/decremented by.
renderContentOn: html
html heading: count.
html anchorWithAction: [self increment] text: '++'.
html space.
html anchorWithAction: [self decrement] text: '--'.
html break.
html horizontalRule.
html text: 'Change the interval'.
html paragraph.
html form: [
html selectFromList: (1 to: 10) selected: interval callback:
[:i | interval _ i].
html submitButton.
].
html text: 'how do I call the setInterval from here?'.
-------
Next, factored the form into a setInterval method:
setInterval: html
html text: interval.
html space.
html space.
html form: [
html selectFromList: (1 to: 10) selected: interval callback:
[:i | interval _ i].
html submitButton.
]
-------
My questions are:
1) Is my factoring correct?
2) How do I call this from 'renderContentOn:' ?
Thanks for you patience with such simple questions.
- Larry Kelly
More information about the Seaside
mailing list