[Seaside] html5 canvas doesn't show processing.js sketch

nvr slx nvrslx at hotmail.com
Tue Jan 17 20:59:53 UTC 2012




hi i'm new to Seaside, and have a little problem:

the html5 canvas I added doesn't show my processing.js sketch



A) i've added "data:" to the WACanvasTag category: 'Seasdie-HTML5-Tags'
      data: aString	     self attributes at: 'data-processing-sources' put: aString

B) .. so the canvas tag is "brushed" like i want
      renderContentOn: html      html canvas data:'http://processingjs.org/sketches/basic-example.pde'.


html result:<canvas data-processing-sources="http://processingjs.org/sketches/basic-example.pde"></canvas>


C) also added the processing.js code:

       updateRoot: aRoot       super updateRoot: aRoot.
                aRoot javascript url: 'http://processingjs.org/js/processing.min.js'.

html result:<script type="text/javascript" src="http://processingjs.org/js/processing.min.js"></script>






D) my expectation was that the processing.js code should show up. when i look at the html source of the seaside page.    the code looks ok, it evens works when i save the code as a index.html file. see html file below
    but the html5 canvas I added doesn't show my processing.js sketch when it's loaded by Seaside


I'm not sure what i'm doing wrong? Please help.
Btw: seaside is great!
Thanks,
Jim




index.html<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"><head><title>Seaside</title><meta http-equiv="Content-Type" content="text/html;charset=utf-8"/><meta http-equiv="Content-Script-Type" content="text/javascript"/><link rel="stylesheet" type="text/css" href="/files/WADevelopmentFiles/development.css"/>
<script type="text/javascript" src="http://processingjs.org/js/processing.min.js"></script>
<link rel="stylesheet" type="text/css" href="/todo?_s=pQPDuwQ--u8uqFXe"/></head><body onload="onLoad()">
<canvas data-processing-sources="http://processingjs.org/sketches/basic-example.pde"></canvas>

<h1>Seaside ToDo</h1><form accept-charset="utf-8" method="post" action="/todo?_s=ZO3cEjCACrsGCweH&amp;_k=SYu7CbDYLBGbh_Yy"><ul><li class="done"><input checked="checked" name="1" type="checkbox" class="checkbox"/><input name="2" type="hidden" class="hidden"/>ToDo Item&nbsp;<a href="/todo?_s=ZO3cEjCACrsGCweH&amp;_k=SYu7CbDYLBGbh_Yy&amp;3">edit</a>&nbsp;<a href="/todo?_s=ZO3cEjCACrsGCweH&amp;_k=SYu7CbDYLBGbh_Yy&amp;4">remove</a></li><li class="done"><input checked="checked" name="5" type="checkbox" class="checkbox"/><input name="6" type="hidden" class="hidden"/>ToDo Item&nbsp;<a href="/todo?_s=ZO3cEjCACrsGCweH&amp;_k=SYu7CbDYLBGbh_Yy&amp;7">edit</a>&nbsp;<a href="/todo?_s=ZO3cEjCACrsGCweH&amp;_k=SYu7CbDYLBGbh_Yy&amp;8">remove</a></li><li class="done"><input checked="checked" name="9" type="checkbox" class="checkbox"/><input name="10" type="hidden" class="hidden"/>ToDo Item&nbsp;<a href="/todo?_s=ZO3cEjCACrsGCweH&amp;_k=SYu7CbDYLBGbh_Yy&amp;11">edit</a>&nbsp;<a href="/todo?_s=ZO3cEjCACrsGCweH&amp;_k=SYu7CbDYLBGbh_Yy&amp;12">remove</a></li><li><input name="13" type="checkbox" class="checkbox"/><input name="14" type="hidden" class="hidden"/>ToDo Item&nbsp;<a href="/todo?_s=ZO3cEjCACrsGCweH&amp;_k=SYu7CbDYLBGbh_Yy&amp;15">edit</a>&nbsp;<a href="/todo?_s=ZO3cEjCACrsGCweH&amp;_k=SYu7CbDYLBGbh_Yy&amp;16">remove</a></li></ul><input value="Save" type="submit" class="submit"/><input name="17" value="Add" type="submit" class="submit"/></form><div class="wa-toolbar"><a class="wa-newsessiontoolplugin" href="/todo?_s=ZO3cEjCACrsGCweH&amp;_k=SYu7CbDYLBGbh_Yy&amp;18">New Session</a> <a class="wa-configuretoolplugin" href="/todo?_s=ZO3cEjCACrsGCweH&amp;_k=SYu7CbDYLBGbh_Yy&amp;19">Configure</a> <a class="wa-togglehalostoolplugin" href="/todo?_s=ZO3cEjCACrsGCweH&amp;_k=SYu7CbDYLBGbh_Yy&amp;20">Halos</a> <a class="wa-profilertoolplugin" href="/todo?_s=ZO3cEjCACrsGCweH&amp;_k=SYu7CbDYLBGbh_Yy&amp;21">Profile</a> <a class="wa-memorytoolplugin" href="/todo?_s=ZO3cEjCACrsGCweH&amp;_k=SYu7CbDYLBGbh_Yy&amp;22">Memory</a> <a class="wa-validatetoolplugin" title="Validate XHTML" href="http://validator.w3.org/check/referer">XHTML</a> <span class="wa-timingtoolplugin"><span title="Callback Time">0</span>/<span title="Render Time">0</span> ms</span></div><script type="text/javascript">/*<![CDATA[*/function onLoad(){};/*]]>*/</script></body></html>
 		 	   		  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.squeakfoundation.org/pipermail/seaside/attachments/20120117/cfae8514/attachment.htm


More information about the seaside mailing list