Le samedi 14 novembre 2009 à 11:34 +0100, Stefan Schmiedl a écrit : > Hi Bèrto, > > On Sat, 14 Nov 2009 06:20:38 +0200 > Bèrto ëd Sèra <[email protected]> wrote: > > > Got it... I'm not using a button to submit the form, but rather an > > anchor. The reason i cannot use buttons is that we want button text to > > be "localisable in place", so it needs to show a "localization status" > > to authorized localizers (green, yellow, red ball for > > localized/fuzzy/missing status) and a MouseOver on this ball opens the > > localisation editor. > > > > Only I cannot seem to understand how I can submit a form using an > > anchor (a CSS button, that is)... > > > > What I have in my current onlinetester: > > b := form radio > beSubmitOnChange; > id: id; > name: group; > action: [ self postAnswer: i to: frage ]. > > > Looking into a fairly recent iliad source tree: > > $ grep beSubmitOn . > ./Core/XHTMLElements/FormElementElement.st: beSubmitOnChange [ > ./Core/XHTMLElements/FormElementElement.st: self beSubmitOnEvent: 'change' > ./Core/XHTMLElements/FormElementElement.st: beSubmitOnClick [ > ./Core/XHTMLElements/FormElementElement.st: self beSubmitOnEvent: 'click' > ./Core/XHTMLElements/FormElementElement.st: beSubmitOnEvent: aString [ > ./More/Examples/TodoListGridWidget.st: beSubmitOnClick; > > So I guess that > > form a beSubmitOnClick; ...
Nop, it won't work, because an anchor is not a form element, so it will send a GET request, and evaluate the action associated to the link, but that's all. And if you think about it, anchors do send requests on click :p :p Nico
signature.asc
Description: Ceci est une partie de message numériquement signée
_______________________________________________ help-smalltalk mailing list [email protected] http://lists.gnu.org/mailman/listinfo/help-smalltalk
