[Seaside] NAME attribute over-ride for dynamic HTML

Robert Hawley R.Hawley at plymouth.ac.uk
Fri Oct 22 05:53:53 CEST 2004


I have been doing some dynamic HTML driven from seaside.  In order to be able to do things like animate web page components I have written JavaScript code that gets downloaded to the web page.  It works well and I can do things like drag an image around a web page and see it's coordinates changing. However, I have a problem that is to do with the way seaside allocates names to HTML components that makes scripting hard for getting the new coordinates back to the server.
 
Seaside's naming is done behind the scenes and is subject to change whenever the programmer adds or removes components from the web page.  Seaside allocates names sequentially: <INPUT NAME="1"....> <INPUT NAME="2"....> etc..  If I use my own (meaningful) naming however, then both names are downloaded so currently I get things like <INPUT NAME="XPOSITION" NAME="1" ....> and in this little clash seaside wins!  Depending on seaside's naming convention could allow something of a work-around, but it is not a good solution because it is vulnerable to changes and it makes the JavaScript (even more) unreadable.
 
It would be good if seaside could detect when the programmer has already set a 'name' attribute and use that name instead of the automatically generated one.
 
I would welcome a 'fix' - or at least some advice on where to start looking.
 
Yours

Bob
(Robert Hawley - Plymouth)
 


More information about the Seaside mailing list