Just trying to poke my way through simplifying some of the coded
JavaScript here and could use a couple of hints, for instance how would I come up with something like, html script: ((html javascript) add: (SUStream on: '$(''mydiv'').style.width="50%"'); yourself) all this to come up with simple, <script type="text/javascript">$('mydiv').style.width="50%"</script> Thanks, -Boris -- +1.604.689.0322 DeepCove Labs Ltd. 4th floor 595 Howe Street Vancouver, Canada V6C 2T5 [hidden email] CONFIDENTIALITY NOTICE This email is intended only for the persons named in the message header. Unless otherwise indicated, it contains information that is private and confidential. If you have received it in error, please notify the sender and delete the entire message including any attachments. Thank you. _______________________________________________ Seaside mailing list [hidden email] http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside |
> html script: ((html javascript)
> add: (SUStream on: '$(''mydiv'').style.width="50%"'); > yourself) Scriptaculous does not define a protocol to edit style but one to add/remove/enumerate classes. So I suggest that you define in your style-sheet .half { width: 50% } and then you do in Seaside: html script: (html element id: 'mydif'; addClassNamed: 'half') And this is it. However if you really want to mess around with styles you can do that of course. Grab the latest version of Scriptaculous, I've added tree new methods: #styleAt:, #styleAt:put: and #style:. html script: (html element id: 'mydif'; styleAt: 'width' put: '50%') Hope this helps, Lukas -- Lukas Renggli http://www.lukas-renggli.ch _______________________________________________ Seaside mailing list [hidden email] http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside |
In reply to this post by Boris Popov, DeepCove Labs (SNN)
Cool thanks! _______________________________________________ Seaside mailing list [hidden email] http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside |
In reply to this post by Lukas Renggli
> Scriptaculous does not define a protocol to edit style but one to
> add/remove/enumerate classes. So I suggest that you define in your > style-sheet I was confused: script.aculo.us provides one, but so up to an hour ago Scriptaculous for Seaside did not. Btw, I published yet another fix that was introduced with this enhancement and the encoding of dictionaries. Lukas -- Lukas Renggli http://www.lukas-renggli.ch _______________________________________________ Seaside mailing list [hidden email] http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside |
Free forum by Nabble | Edit this page |