[Seaside] inline javascript inside head section

Gerhard Obermann obi068 at gmail.com
Sat Jan 26 18:24:18 UTC 2008

I want to create a javascript inside the head section
without doing a callback.

I tried the following code:
 anHtmlRoot javascript add: 'function test() {.....}'

The problem is, that in this case the javascript will be also encoded and
breaks my javascript code.

The only solution i found up to now, is to override the encodeOn: method in

encodeOn: aDocument
 aDocument openTag: self tag attributes: attributes closed: self isClosed.
 self isClosed ifTrue: [ ^ self ].
 self childrenDo: [ :each | aDocument nextPutAll: each].
 aDocument closeTag: self tag

btw: i am using seaside 2.9

cheers Gerhard
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.squeakfoundation.org/pipermail/seaside/attachments/20080126/4bb98989/attachment.htm

More information about the seaside mailing list