[Seaside-dev] submitFormNamed: weirdness

Lukas Renggli renggli at gmail.com
Wed Nov 28 18:08:06 UTC 2007


> The behavior of #submitFormNamed: has been completely reworked (lr.
> 441 & lr.446). You may want to try the following fixes to WAAnchorTag
> and see it they fix the weirdness:

The reason for this change was that we want to get rid of these weird
JavaScript hacks from the core framework. It is inacceptable if
Seaside tries to enforce the inclusion of some scripts, especially if
it conflicts with other functionality.

> > If you use #ignoreURL to put a 'return false' on the end of the
> > onclick you quickly discover that the anchor's callback is never
> > run.. which is puzzling when I found this thread: http://
> > www.nabble.com/Anchor-with-submit-and-callback-t2648056.html from
> > 2006 describing how submitFormNamed: should preserve the action id
> > of the previously setup callback. This code doesn't exist in
> > Seaside 2.8 final.

While refactoring WAAnchorTag (getting rid of its 25
instance-variables is another reason for Seaside requiring much less
memory) I obviously introduced this bug. The question is if we need
that method or if we can get rid of it altogether. I don't know of
anybody actually using it (the same for the other JavaScript
functions: swapDisplay, submitFormTriggeringCallback, submitForm,
submitForm, enableChoice, setFocus, setSelection). There are much
cleaner ways of doing the same things using Scriptaculous, and
presumably SeasideAsync.

Cheers,
Lukas

-- 
Lukas Renggli
http://www.lukas-renggli.ch


More information about the seaside-dev mailing list