PackageDescription: SeasideAssistants(Bundle)


Seaside Assistants

Last published: September 11, 2006 by 'mbany'


SeasideAssistants for VisualWorks

Among other things, proper compliance to XHTML implies
(1) Form tags are not be nested,
(2) The id attribute values are unique.
The later is especially important when using AJAX techniques where it is critical for the Javascript functions to uniquely identify the XML elements that are manipulated.
In complex constructs that are using many nested components generated by many different rendering methods from many different classes, it may be difficult to ensure XHTML compliance. As a consequence, nested form tags or duplicate id attribute values are likely to occur.
This package slightly modifies Seaside so that nested form tags and duplicate id attribute values are producing an error. This makes it possible to immediately and precisely spot where to look in the Seaside application.
The exact behavior is decided in the following methods :
#shouldRaiseDuplicateCssIdErrors
#shouldRaiseNestedFormErrors
#shouldSilentlyDiscardNestedForms
These methods are available in classes WAHtmlRenderer and WARenderCanvas.
When this package is loaded the default behavior is the following:
(1) Duplicate id attribute values are allowed (#shouldRaiseDuplicateCssIdErrors answers false)
(2) Nested form tags are allowed (#shouldRaiseNestedFormErrors answers false)
(3) Nested form tags are silently discarded (#shouldSilentlyDiscardNestedForms answers true)
This default behavior ensures that an existing Seaside application does not break.
To enable a different behavior, there are two possibilities.
(1) Modifies any of the six methods listed above
(2) Subclass WAHtmlRenderer or WARenderCanvas and re-implement methods as needed
Contributors: Michel Bany

Keywords: Web, Continuations, HTML, XHTML, CSS, Internet, Squeak

Port from SeasideAssistants-mb.9.mcz 16 June 2006 9:58:36 am