<?xml version="1.0" encoding="ISO-8859-15"?>
<feed version="0.3" xmlns="http://purl.org/atom/ns#"
      xmlns:dc="http://purl.org/dc/elements/1.1/">
  <title mode="escaped" type="text/html">Tarek Ziadé</title>
  <tagline>ATOM Feed - Tarek Ziadé</tagline>
  <link rel="alternate" type="text/html"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade" />
  <id>tag:blogs.nuxeo.com:sections:blogs:tarek_ziade</id>
  <generator url="http://cps-project.org" version="3">CPS</generator>
  <modified>2005-01-25 19:15:52</modified>

  <link rel="service.feed"
        href=" http://blogs.nuxeo.com/sections/blogs/tarek_ziade/atomFeed"
        title="Tarek Ziadé" type="application/atom+xml" />
  <link rel="service.post"
        href=" http://blogs.nuxeo.com/sections/blogs/tarek_ziade/postAtom"
        title="Tarek Ziadé" type="application/atom+xml" />
  <link rel="service.categories"
        href=" http://blogs.nuxeo.com/sections/blogs/tarek_ziade/atomCategories"
        title="Tarek Ziadé" type="application/atom+xml" />

  
      <entry xmlns="http://purl.org/atom/ns#"
       xmlns:dc="http://purl.org/dc/elements/1.1/">
     
  <title mode="escaped" type="text/html">A second blog</title>
  <link rel="alternate" type="text/html"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_10_15_second-blog" />
  <issued>2006-10-15T17:04:05Z</issued>
  <modified>2006-10-15T17:04:05Z</modified>
  <created>2006-10-15T17:04:04Z</created>
  <draft xmlns="http://purl.org/atom-blog/ns#">false</draft>
  <author>
    <name>tziade</name>
  </author>
  
  
    <dc:subject>python</dc:subject>
  
  
    <dc:subject>zope</dc:subject>
  
  
    <dc:subject>zope3</dc:subject>
  
  
  <summary type="text/html" mode="escaped">Just to let you know: I have decided to split this blog in two distinct blogs for more clarity, ecm, java and cps related things will remain here, while python related things will now be written in a secondary blog: Carpet Python.</summary>

  <content type="text/html" mode="escaped"
           xml:space="preserve">Just to let you know: I have decided to split this blog in two distinct blogs for more clarity, ecm, java and cps related things will remain here, while python related things will now be written in a secondary blog: &lt;a href="http://tarekziade.wordpress.com/"&gt;Carpet Python&lt;/a&gt;.&lt;br&gt;</content>

  <id>tag:blogs.nuxeo.com:sections:blogs:tarek_ziade:2006_10_15_second-blog</id>
  <link rel="service.edit" type="application/atom+xml"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_10_15_second-blog/atom?2006_10_15_second-blog"
        title="Edit Here - A second blog" />
</entry>

  
  
      <entry xmlns="http://purl.org/atom/ns#"
       xmlns:dc="http://purl.org/dc/elements/1.1/">
     
  <title mode="escaped" type="text/html">Europython 2006, Slides</title>
  <link rel="alternate" type="text/html"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_07_03_europython-2006-slides" />
  <issued>2006-07-04T10:59:16Z</issued>
  <modified>2006-07-04T10:59:16Z</modified>
  <created>2006-07-03T03:10:30Z</created>
  <draft xmlns="http://purl.org/atom-blog/ns#">false</draft>
  <author>
    <name>tziade</name>
  </author>
  
  
    <dc:subject>AJAX</dc:subject>
  
  
    <dc:subject>coding</dc:subject>
  
  
    <dc:subject>cps</dc:subject>
  
  
    <dc:subject>nuxeo</dc:subject>
  
  
    <dc:subject>python</dc:subject>
  
  
    <dc:subject>web</dc:subject>
  
  
    <dc:subject>zope</dc:subject>
  
  
    <dc:subject>zope3</dc:subject>
  
  
  <summary type="text/html" mode="escaped">I am here at Europython, and will enjoying a great session that compares web
  frameworks (Zope 3, Django, Pylons, etc..), I am dropping here the slides
  from my presentations, done yesterday and today.
  
  At the menu:
  

  
   
   zope-cookbook.org: the slides presents the website, and moreover good
   pratices for documenting softwares in an agile way

   
   CPSBayes: a ...</summary>

  <content type="text/html" mode="escaped"
           xml:space="preserve">I am here at Europython, and will enjoying a great session that compares web
  frameworks (Zope 3, Django, Pylons, etc..), I am dropping here the slides
  from my presentations, done yesterday and today.&lt;br /&gt;
  &lt;br /&gt;
  At the menu:&lt;br /&gt;
  &lt;br /&gt;

  &lt;ul&gt;
   &lt;li&gt;&lt;a
   href="http://indico.cern.ch/contributionDisplay.py?contribId=5&amp;amp;sessionId=53&amp;amp;confId=44"&gt;
   zope-cookbook.org&lt;/a&gt;: the slides presents the website, and moreover good
   pratices for documenting softwares in an agile way&lt;/li&gt;

   &lt;li&gt;&lt;a
   href="http://indico.cern.ch/contributionDisplay.py?contribId=28&amp;amp;sessionId=9&amp;amp;confId=44"&gt;
   CPSBayes&lt;/a&gt;: a bayesian classifier implemented for CPSCourier&lt;/li&gt;

   &lt;li&gt;&lt;a
   href="http://indico.cern.ch/contributionDisplay.py?contribId=27&amp;amp;sessionId=53&amp;amp;confId=44"&gt;
   Ajax, state of the art&lt;/a&gt;: a resumé of Ajax usage and good practices, and
   how developers and designers feel about this technology&lt;br /&gt;
   &lt;/li&gt;
  &lt;/ul&gt;
  &lt;br /&gt;
  &lt;br /&gt;
(attached files below)</content>

  <id>tag:blogs.nuxeo.com:sections:blogs:tarek_ziade:2006_07_03_europython-2006-slides</id>
  <link rel="service.edit" type="application/atom+xml"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_07_03_europython-2006-slides/atom?2006_07_03_europython-2006-slides"
        title="Edit Here - Europython 2006, Slides" />
</entry>

  
  
      <entry xmlns="http://purl.org/atom/ns#"
       xmlns:dc="http://purl.org/dc/elements/1.1/">
     
  <title mode="escaped" type="text/html">Try out CPSBayes, the multipurpose naive bayesian classifier for CPS</title>
  <link rel="alternate" type="text/html"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_06_24_try-cpsbayes" />
  <issued>2006-06-24T11:35:15Z</issued>
  <modified>2006-06-24T11:35:15Z</modified>
  <created>2006-06-24T11:25:44Z</created>
  <draft xmlns="http://purl.org/atom-blog/ns#">false</draft>
  <author>
    <name>tziade</name>
  </author>
  
  
    <dc:subject>AJAX</dc:subject>
  
  
    <dc:subject>cps</dc:subject>
  
  
    <dc:subject>nuxeo</dc:subject>
  
  
    <dc:subject>python</dc:subject>
  
  
    <dc:subject>zope</dc:subject>
  
  
    <dc:subject>zope3</dc:subject>
  
  
  <summary type="text/html" mode="escaped">CPSBayes is a naive bayesian
  classifier, that uses the same kind of algorithms than software like SpamAssassin. Its main use case
  is to categorize incoming mails in CPSCourier, a
  complete solution for mail and notes managment.
   
   The tool stores data in the ZODB or in any kind of SQL Database, using
  SQLObject connector.
   
   Categorization can apply to a lot of other use ...</summary>

  <content type="text/html" mode="escaped"
           xml:space="preserve">CPSBayes is a &lt;a
  href="http://en.wikipedia.org/wiki/Naive_Bayes_classifier"&gt;naive bayesian
  classifier&lt;/a&gt;, that uses the same kind of algorithms than software like &lt;a
  href="http://spamassassin.apache.org/"&gt;SpamAssassin&lt;/a&gt;. Its main use case
  is to categorize incoming mails in &lt;a
  href="http://www.nuxeo.com/solutions/cps-courrier"&gt;CPSCourier&lt;/a&gt;, a
  complete solution for mail and notes managment.&lt;br /&gt;
   &lt;br /&gt;
   The tool stores data in the ZODB or in any kind of SQL Database, using
  SQLObject connector.&lt;br /&gt;
   &lt;br /&gt;
   Categorization can apply to a lot of other use cases as well, and I have
  coded a small product called CPSBayesExample that shows how simple it is to
  set and use CPSBayes over a portal.&lt;br /&gt;
   &lt;br /&gt;
   The product provides a textarea where you can type some text, and show some pictures and categories that are guessed by CPSBayes, with the text. The page is dynamically updated through Ajax, with a simple keystroke.&lt;br /&gt;
   &lt;br /&gt;
   The categories can be trained as well so you can make it learn new
  patterns.&lt;br /&gt;
   &lt;br /&gt;
   This simple demo shows how CPSBayes could be used to do automatic metadata filling with a very few lines of code.&lt;br /&gt;
   &lt;br /&gt;
   To get it, checkout the code from our subversion:&lt;br /&gt;
   &lt;br /&gt;
&lt;pre&gt;
  # svn co https://svn.nuxeo.org/pub/CPS3/examples/CPSBayesExample/trunk CPSBayesExample&lt;br /&gt;
&lt;/pre&gt;
  &lt;br /&gt;
   And read the README.txt file&lt;br /&gt;
   &lt;br /&gt;
   &lt;br /&gt;</content>

  <id>tag:blogs.nuxeo.com:sections:blogs:tarek_ziade:2006_06_24_try-cpsbayes</id>
  <link rel="service.edit" type="application/atom+xml"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_06_24_try-cpsbayes/atom?2006_06_24_try-cpsbayes"
        title="Edit Here - Try out CPSBayes, the multipurpose naive bayesian classifier for CPS" />
</entry>

  
  
      <entry xmlns="http://purl.org/atom/ns#"
       xmlns:dc="http://purl.org/dc/elements/1.1/">
     
  <title mode="escaped" type="text/html">Europython coming up !</title>
  <link rel="alternate" type="text/html"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_06_06_europython-coming-up" />
  <issued>2006-06-06T10:32:44Z</issued>
  <modified>2006-06-06T10:32:44Z</modified>
  <created>2006-06-06T10:30:44Z</created>
  <draft xmlns="http://purl.org/atom-blog/ns#">false</draft>
  <author>
    <name>tziade</name>
  </author>
  
  
    <dc:subject>AJAX</dc:subject>
  
  
    <dc:subject>cps</dc:subject>
  
  
    <dc:subject>nuxeo</dc:subject>
  
  
    <dc:subject>python</dc:subject>
  
  
    <dc:subject>zope</dc:subject>
  
  
    <dc:subject>zope3</dc:subject>
  
  
  <summary type="text/html" mode="escaped">Like 
  Julien has started to announce, we are going to be present at Europython
  this year, and I am really excited to be part of it. 
  
  I will present three topics:
  
  

  
   CPSBayes: a bayesian classifier of Zope (
   abstract)

   Ajax, state of the art: a presentation about Ajax, Javascript,
   that will mainly focus on agile development techniques with javascript, and
 ...</summary>

  <content type="text/html" mode="escaped"
           xml:space="preserve">Like &lt;a
  href="http://blogs.nuxeo.com/sections/blogs/julien_anguenot/2006_06_06_europython-2006-timetable-conference-partially-annonced"&gt;
  Julien has started to announce&lt;/a&gt;, we are going to be present at Europython
  this year, and I am really excited to be part of it. &lt;br /&gt;
  &lt;br /&gt;
  I will present three topics:&lt;br /&gt;
  &lt;b&gt;&lt;br /&gt;
  &lt;/b&gt;

  &lt;ul&gt;
   &lt;li&gt;&lt;b&gt;CPSBayes&lt;/b&gt;: a bayesian classifier of Zope (&lt;a
   href="http://indico.cern.ch/contributionDisplay.py?contribId=28&amp;amp;sessionId=9&amp;amp;confId=44"&gt;
   abstract&lt;/a&gt;)&lt;/li&gt;

   &lt;li&gt;&lt;b&gt;Ajax, state of the art&lt;/b&gt;: a presentation about Ajax, Javascript,
   that will mainly focus on agile development techniques with javascript, and
   how it can be integrated in a Zope project continuous integration. (&lt;a
   href="http://indico.cern.ch/abstractDisplay.py?abstractId=27&amp;amp;amp;confId=44"&gt;
   abstract&lt;/a&gt;)&lt;/li&gt;

   &lt;li&gt;&lt;b&gt;zope-cookbook.org&lt;/b&gt;: a presentation on a personal project I am
   doing to create a cookbook for Zope 3. The talk focuses on the project
   agility obtained through doctests and efficient writing techniques. This is
   quite important to document code bases that still moves a lot like Zope 3
   (&lt;a
   href="http://indico.cern.ch/abstractDisplay.py?abstractId=27&amp;amp;amp;confId=44"&gt;
   abstract&lt;/a&gt;)&lt;/li&gt;
  &lt;/ul&gt;
  &lt;br /&gt;
  Julien's talk will be very interesting to follow as well (trust me, &lt;a
  href="http://www.cps-project.org/sections/projects/nxlucene"&gt;NXLucene&lt;/a&gt;
  really rocks).&lt;br /&gt;
  &lt;br /&gt;
  July will be Python fest, since right after EP, the &lt;a
  href="http://www.afpy.org/"&gt;AFPY&lt;/a&gt; user group will be part of the &lt;a
  href="http://www.rmll.info/?lang=en"&gt;Libre Software Meeting&lt;/a&gt; in Nancy
  (FRA) to cover Python in a local meeting that will be &lt;a
  href="http://www.afpy.org/groups/gr_adherents/wikis/ReunionJuillet2006Nancy"&gt;
  juicy as well&lt;/a&gt;.&lt;br /&gt;
  &lt;br /&gt;
  &lt;br /&gt;</content>

  <id>tag:blogs.nuxeo.com:sections:blogs:tarek_ziade:2006_06_06_europython-coming-up</id>
  <link rel="service.edit" type="application/atom+xml"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_06_06_europython-coming-up/atom?2006_06_06_europython-coming-up"
        title="Edit Here - Europython coming up !" />
</entry>

  
  
      <entry xmlns="http://purl.org/atom/ns#"
       xmlns:dc="http://purl.org/dc/elements/1.1/">
     
  <title mode="escaped" type="text/html">JSDoc, a JavaDoc-like for Javascript</title>
  <link rel="alternate" type="text/html"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_05_03_jsdoc-javadoc-like-for-javascript" />
  <issued>2006-05-03T14:03:48Z</issued>
  <modified>2006-05-03T14:03:48Z</modified>
  <created>2006-05-03T14:00:56Z</created>
  <draft xmlns="http://purl.org/atom-blog/ns#">false</draft>
  <author>
    <name>tziade</name>
  </author>
  
  
    <dc:subject>AJAX</dc:subject>
  
  
    <dc:subject>eclipse</dc:subject>
  
  
  <summary type="text/html" mode="escaped">I was looking for something similar to docstrings in Python, to make an API
  static html documentation for 
  nuxeo.javascript.
   
   JSDoc seems to fill the bill,
  and generates an API documentation similar to what I would get with JavaDoc
  or Epydoc.
   
   See an example
  here.
   
  It is also used by tools like 
  JSEclipse</summary>

  <content type="text/html" mode="escaped"
           xml:space="preserve">I was looking for something similar to docstrings in Python, to make an API
  static html documentation for &lt;a
  href="http://svn.nuxeo.org/trac/pub/browser/nuxeo.javascript/trunk/src/nuxeo/javascript/cps/doc/api/"&gt;
  nuxeo.javascript&lt;/a&gt;.&lt;br /&gt;
   &lt;br /&gt;
   &lt;a href="http://jsdoc.sourceforge.net/"&gt;JSDoc&lt;/a&gt; seems to fill the bill,
  and generates an API documentation similar to what I would get with JavaDoc
  or Epydoc.&lt;br /&gt;
   &lt;br /&gt;
   &lt;a href="http://jsdoc.sourceforge.net/example/index.html"&gt;See an example
  here.&lt;/a&gt;&lt;br /&gt;
   &lt;br /&gt;
  It is also used by tools like &lt;a
  href="http://www.interaktonline.com/Products/Eclipse/JSEclipse/Features/Details/Use+of+JSDoc+and+inline+parameter+comments+to+detect+parameter+type.html?id_ftr=639"&gt;
  JSEclipse&lt;/a&gt;&lt;br /&gt;</content>

  <id>tag:blogs.nuxeo.com:sections:blogs:tarek_ziade:2006_05_03_jsdoc-javadoc-like-for-javascript</id>
  <link rel="service.edit" type="application/atom+xml"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_05_03_jsdoc-javadoc-like-for-javascript/atom?2006_05_03_jsdoc-javadoc-like-for-javascript"
        title="Edit Here - JSDoc, a JavaDoc-like for Javascript" />
</entry>

  
  
      <entry xmlns="http://purl.org/atom/ns#"
       xmlns:dc="http://purl.org/dc/elements/1.1/">
     
  <title mode="escaped" type="text/html">Zope community portraits, meet the guys</title>
  <link rel="alternate" type="text/html"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_04_29_zope-community-portraits-meet-guys" />
  <issued>2006-04-29T13:15:21Z</issued>
  <modified>2006-04-29T13:15:21Z</modified>
  <created>2006-04-29T13:15:21Z</created>
  <draft xmlns="http://purl.org/atom-blog/ns#">false</draft>
  <author>
    <name>tziade</name>
  </author>
  
  
    <dc:subject>zope</dc:subject>
  
  
    <dc:subject>zope3</dc:subject>
  
  
  <summary type="text/html" mode="escaped">I have started to collect portraits from Zope community people on this page. Meet them !</summary>

  <content type="text/html" mode="escaped"
           xml:space="preserve">I have started to collect portraits from Zope community people on &lt;a
  href="http://zope-cookbook.org/community"&gt;this page&lt;/a&gt;. Meet them !&lt;br /&gt;</content>

  <id>tag:blogs.nuxeo.com:sections:blogs:tarek_ziade:2006_04_29_zope-community-portraits-meet-guys</id>
  <link rel="service.edit" type="application/atom+xml"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_04_29_zope-community-portraits-meet-guys/atom?2006_04_29_zope-community-portraits-meet-guys"
        title="Edit Here - Zope community portraits, meet the guys" />
</entry>

  
  
      <entry xmlns="http://purl.org/atom/ns#"
       xmlns:dc="http://purl.org/dc/elements/1.1/">
     
  <title mode="escaped" type="text/html">CPS4/Z3ECM sprint, Final wrapup</title>
  <link rel="alternate" type="text/html"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_04_25_cps4-z3ecm-sprint-final-wrapup" />
  <issued>2006-04-24T22:32:56Z</issued>
  <modified>2006-04-24T22:32:56Z</modified>
  <created>2006-04-24T22:12:19Z</created>
  <draft xmlns="http://purl.org/atom-blog/ns#">false</draft>
  <author>
    <name>tziade</name>
  </author>
  
  
    <dc:subject>AJAX</dc:subject>
  
  
    <dc:subject>cps</dc:subject>
  
  
    <dc:subject>ecm</dc:subject>
  
  
    <dc:subject>python</dc:subject>
  
  
    <dc:subject>sprint</dc:subject>
  
  
    <dc:subject>zope</dc:subject>
  
  
    <dc:subject>zope3</dc:subject>
  
  
  <summary type="text/html" mode="escaped">The week went very fast, but was very productive indeed, here's a quick
  wrapup of sprinters work:

  Florent &amp;amp; Dario: The boys managed to write a parser to
  leverage the schemas that exists in JCR into Python structures. They create
  Zope 3 schemas, rather than CPSSchemas. Everything will be hooked through JackRabbit, so JCR content will
  become a good citizen for beeing used ...</summary>

  <content type="text/html" mode="escaped"
           xml:space="preserve">&lt;p&gt;The week went very fast, but was very productive indeed, here's a quick
  wrapup of sprinters work:&lt;/p&gt;

  &lt;p&gt;&lt;b&gt;Florent &amp;amp; Dario&lt;/b&gt;: The boys managed to write a parser to
  leverage the schemas that exists in JCR into Python structures. They create
  Zope 3 schemas, rather than CPSSchemas. Everything will be hooked through &lt;a
  href="http://jackrabbit.apache.org/"&gt;JackRabbit,&lt;/a&gt; so JCR content will
  become a good citizen for beeing used within Zope 3. They've also created a
  hierarchy of interfaces for this in Zope 3. All the work is here: &lt;a
  href="http://svn.nuxeo.org/trac/pub/browser/nuxeo.jcr/trunk/src/nuxeo/jcr/"&gt;nuxeo.jcr&lt;/a&gt;&lt;/p&gt;

  &lt;p&gt;&lt;b&gt;Michael &amp;amp; Lennart&lt;/b&gt;: They struggled with Zope 2 &amp;amp; 3
  publishers to continue Sidnei's work and came up with an advanced prototype.
  And, as this was one of the concern, they benched a bit twisted behavior in
  Zope 2, using &lt;a href="http://funkload.nuxeo.org/"&gt;funkload&lt;/a&gt; and it seem
  not too slow compared to zserver. The work is on a &lt;a
  href="http://svn.zope.org/Zope/branches/publication-refactor2"&gt;branch on
  svn.zope.org&lt;/a&gt;.&lt;br /&gt;
  &lt;/p&gt;

  &lt;p&gt;&lt;b&gt;Jean-Marc&lt;/b&gt;: That guy knows everything about Zope 2 and Zope 3
  branches now ;). &lt;a
  href="http://www.z3lab.org/sections/blogs/philipp-weitershausen"&gt;Philipp&lt;/a&gt;
  helped a lot through IRC (thanks) and Jean Marc came up with... wait a
  minute... &lt;a
  href="http://www.z3lab.org/sections/blogs/jean-marc-orliaguet/2006_04_23_cps4-z3ecm-paris-sprint"&gt;
  a blog entry that resumes it all&lt;/a&gt;.&lt;/p&gt;

  &lt;p&gt;&lt;b&gt;Tarek&lt;/b&gt;: After a first release of &lt;a
  href="http://svn.nuxeo.org/trac/pub/browser/CPSResourceLibrary/trunk/"&gt;CPSResourceLibrary,&lt;/a&gt;
  and &lt;a
  href="http://svn.nuxeo.org/trac/pub/browser/nuxeo.javascript/trunk/src/nuxeo/javascript/"&gt;
  nuxeo.javascript&lt;/a&gt;, I focused on doing tests automation in Javascript. OK
  that might not be very easy to set up on a buildbot, but on my laptop, it's
  going to be just perfect to TDD js code in zope.&lt;/p&gt;

  &lt;p&gt;&lt;b&gt;Joachim&lt;/b&gt;: He played with Jean-Marc Cpsskins v3 concepts, by
  creating some Ajax Portlets in CPS 3.4, relying on CPSResourceLibrary, and
  nuxeo.javascript. Watch it in &lt;a
  href="http://svn.nuxeo.org/trac/pub/browser/CPSAjaxPortlets/trunk/"&gt;CPSAjaxPortlets&lt;/a&gt;,
  it's coming soon babe !&lt;br /&gt;
  &lt;/p&gt;

  &lt;p&gt;&lt;br /&gt;
  &lt;/p&gt;</content>

  <id>tag:blogs.nuxeo.com:sections:blogs:tarek_ziade:2006_04_25_cps4-z3ecm-sprint-final-wrapup</id>
  <link rel="service.edit" type="application/atom+xml"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_04_25_cps4-z3ecm-sprint-final-wrapup/atom?2006_04_25_cps4-z3ecm-sprint-final-wrapup"
        title="Edit Here - CPS4/Z3ECM sprint, Final wrapup" />
</entry>

  
  
      <entry xmlns="http://purl.org/atom/ns#"
       xmlns:dc="http://purl.org/dc/elements/1.1/">
     
  <title mode="escaped" type="text/html">CPS4/Z3ECM sprint, day 4, Javascript unit testing automation</title>
  <link rel="alternate" type="text/html"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_04_21_javascript-unit-testing-automation" />
  <issued>2006-04-21T14:53:45Z</issued>
  <modified>2006-04-21T14:53:45Z</modified>
  <created>2006-04-21T14:02:02Z</created>
  <draft xmlns="http://purl.org/atom-blog/ns#">false</draft>
  <author>
    <name>tziade</name>
  </author>
  
  
    <dc:subject>AJAX</dc:subject>
  
  
    <dc:subject>cps</dc:subject>
  
  
    <dc:subject>python</dc:subject>
  
  
    <dc:subject>sprint</dc:subject>
  
  
    <dc:subject>web</dc:subject>
  
  
    <dc:subject>zope3</dc:subject>
  
  
  <summary type="text/html" mode="escaped">For the last day of sprint, I wanted to set up a Javascript unit test
  automation,
   in order to be able to run all Js unitests like Python tests are through
  buildbot.
   
   Scriptaculous unit testing framework provides a way to do it: the tests
  results are sent to a url through an Ajax call. 
   
   More infos on unit testing javascript here: Scriptaculous
  Unit testing
   
   ...</summary>

  <content type="text/html" mode="escaped"
           xml:space="preserve">For the last day of sprint, I wanted to set up a Javascript unit test
  automation,&lt;br /&gt;
   in order to be able to run all Js unitests like Python tests are through
  buildbot.&lt;br /&gt;
   &lt;br /&gt;
   Scriptaculous unit testing framework provides a way to do it: the tests
  results are sent to a url through an Ajax call. &lt;br /&gt;
   &lt;br /&gt;
   More infos on unit testing javascript here: &lt;a
  href="http://wiki.script.aculo.us/scriptaculous/show/UnitTesting"&gt;Scriptaculous
  Unit testing&lt;/a&gt;&lt;br /&gt;
   &lt;br /&gt;
   Therefore, I have coded:&lt;br /&gt;
   &lt;br /&gt;
   

  &lt;ul&gt;
   &lt;li&gt;a small python script that launches html unit tests with
   mozilla-firefox, then close it&lt;/li&gt;

   &lt;li&gt;a small python http server that retrieves results sent by the
   javascript&lt;/li&gt;
  &lt;/ul&gt;
  &lt;br /&gt;
   Some caveats to correct before its useable in a Zope project:&lt;br /&gt;
   &lt;br /&gt;
   

  &lt;ul&gt;
   &lt;li&gt;Right now the results sent by the unit test is just a simple 'SUCESS'
   or 'ERROR' string, and I need to change it so I can get the full error log
   when they are errors, like the one displayed in the browser, and convert it
   to Python assertions.&lt;/li&gt;

   &lt;li&gt;The ajax call to send results is done from the filesystem html to the
   localhost. So a trick is needed to make cross-domain ajax posts. The python
   http server could be used to serve the html tests file as well to avoid
   this problem, so I would have a complete js test server.&lt;/li&gt;

   &lt;li&gt;It needs to work on IE as well, maybe through Wine&lt;br /&gt;
   &lt;/li&gt;
  &lt;/ul&gt;
  &lt;br /&gt;
   So to the question "Can I do TDD in JS as smoothly as in Python ?", I'd
  answer: "Yes, it's coming up :)"&lt;br /&gt;
   &lt;br /&gt;
   You can check the work here: &lt;a
  href="http://svn.nuxeo.org/trac/pub/browser/nuxeo.javascript/trunk/src/nuxeo/javascript/cps/src/tests/"&gt;
  nuxeo.javascript cps tests&lt;/a&gt;&lt;br /&gt;
   &lt;br /&gt;
   I might try to release the js test runner in a clean package sometimes, as
  it might be reused.&lt;br /&gt;
   &lt;br /&gt;
&lt;i&gt;This entry contains a screencast, you should check it in a browser&lt;/i&gt;&lt;br/&gt;
   &lt;object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"
  codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=5,0,0,0"
   height="600" width="800"&gt;
   &lt;param name="movie" value="automation.swf" /&gt;
   &lt;param name="play" value="true" /&gt;
   &lt;param name="loop" value="True" /&gt;
   &lt;param name="quality" value="low" /&gt;
   &lt;embed src="automation.swf" play="true" loop="True" quality="low"
   type="application/x-shockwave-flash"
   pluginspage="http://www.macromedia.com/go/getflashplayer" height="600"
   width="800" /&gt;
  &lt;/object&gt; &lt;br /&gt;</content>

  <id>tag:blogs.nuxeo.com:sections:blogs:tarek_ziade:2006_04_21_javascript-unit-testing-automation</id>
  <link rel="service.edit" type="application/atom+xml"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_04_21_javascript-unit-testing-automation/atom?2006_04_21_javascript-unit-testing-automation"
        title="Edit Here - CPS4/Z3ECM sprint, day 4, Javascript unit testing automation" />
</entry>

  
  
      <entry xmlns="http://purl.org/atom/ns#"
       xmlns:dc="http://purl.org/dc/elements/1.1/">
     
  <title mode="escaped" type="text/html">Python event in "Le Monde en Tique" book store in Paris the 13th May</title>
  <link rel="alternate" type="text/html"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_04_12_python-event-in-le-monde-en-tique-stor-in-paris-13th-may" />
  <issued>2006-04-12T12:27:16Z</issued>
  <modified>2006-04-12T12:27:16Z</modified>
  <created>2006-04-12T10:57:05Z</created>
  <draft xmlns="http://purl.org/atom-blog/ns#">false</draft>
  <author>
    <name>tziade</name>
  </author>
  
  
    <dc:subject>python</dc:subject>
  
  
  <summary type="text/html" mode="escaped">We'll continue our Python evangelism work with Stéfane the 13th May, at le
  Monde en Tique, a book store in Paris.
   
   We'll meet people from 3 to 6 pm, around the "Programmation Python" book to
  convince more developers to switch to Python and join the community ;)
   
   Web site: http://lmet.com
   
   Address:  6 rue Maître Albert - 75005 PARIS - FRANCE
  
  
Access map: ...</summary>

  <content type="text/html" mode="escaped"
           xml:space="preserve">We'll continue our Python evangelism work with Stéfane the 13th May, at le
  Monde en Tique, a book store in Paris.&lt;br /&gt;
   &lt;br /&gt;
   We'll meet people from 3 to 6 pm, around the "Programmation Python" book to
  convince more developers to switch to Python and join the community ;)&lt;br /&gt;
   &lt;br /&gt;
   Web site: &lt;a onclick="return top.js.OpenExtLink(window,event,this)"
  href="http://lmet.com/" target="_blank"&gt;http://lmet.com&lt;/a&gt;&lt;br /&gt;
   &lt;br /&gt;
   Address: &amp;nbsp;6 rue Maître Albert - 75005 PARIS - FRANCE&lt;br /&gt;
  &lt;br /&gt;
  
Access map: &lt;a
  href="http://www.mappy.com/mappyme/map?data_id=D295582F-2BAE-420F-B28C-B476EC9B3F9A"&gt;
  Mappy&lt;/a&gt;&lt;br /&gt;
   &lt;br /&gt;
   Tube, RER:&lt;br /&gt;
   Ligne 10 : Station Maubert - Mutualité&lt;br /&gt;
   Rer B : Saint Michel - Notre Dame, Sortie : Notre-Dame&lt;br /&gt;
   Rer C : Cluny - La &amp;nbsp;Sorbonne, Sortie : Boulevard Saint-Michel /&lt;br /&gt;
   Boulevard Saint-Germain&lt;br /&gt;
   &lt;br /&gt;
   &lt;br /&gt;</content>

  <id>tag:blogs.nuxeo.com:sections:blogs:tarek_ziade:2006_04_12_python-event-in-le-monde-en-tique-stor-in-paris-13th-may</id>
  <link rel="service.edit" type="application/atom+xml"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_04_12_python-event-in-le-monde-en-tique-stor-in-paris-13th-may/atom?2006_04_12_python-event-in-le-monde-en-tique-stor-in-paris-13th-may"
        title="Edit Here - Python event in &quot;Le Monde en Tique&quot; book store in Paris the 13th May" />
</entry>

  
  
      <entry xmlns="http://purl.org/atom/ns#"
       xmlns:dc="http://purl.org/dc/elements/1.1/">
     
  <title mode="escaped" type="text/html">zope-cookbook.org, an open Zope 3 cookbook launched !</title>
  <link rel="alternate" type="text/html"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_04_09_zope-cookbook-org-open-zope-3-cookbook-launched" />
  <issued>2006-04-09T19:12:37Z</issued>
  <modified>2006-04-09T19:12:37Z</modified>
  <created>2006-04-09T19:11:16Z</created>
  <draft xmlns="http://purl.org/atom-blog/ns#">false</draft>
  <author>
    <name>tziade</name>
  </author>
  
  
    <dc:subject>python</dc:subject>
  
  
    <dc:subject>zope</dc:subject>
  
  
    <dc:subject>zope3</dc:subject>
  
  
  <summary type="text/html" mode="escaped">zope-cookbook.org is a website that
  starts to gather recipes and tutorials for Zope 3.

  The cookbook aims to provide a complete sight of Zope 3 through various
  recipes written by project participants, both in french and english.
  

  Recipes are made available on the website when they are tagged as
  'readable' in all languages.
  

  The code examples in the recipes are run for ...</summary>

  <content type="text/html" mode="escaped"
           xml:space="preserve">&lt;a href="http://zope-cookbook.org"&gt;zope-cookbook.org&lt;/a&gt; is a website that
  starts to gather recipes and tutorials for Zope 3.&lt;br /&gt;

  &lt;p&gt;The cookbook aims to provide a complete sight of Zope 3 through various
  recipes written by project participants, both in french and english.&lt;br /&gt;
  &lt;/p&gt;

  &lt;p&gt;Recipes are made available on the website when they are tagged as
  'readable' in all languages.&lt;br /&gt;
  &lt;/p&gt;

  &lt;p&gt;The code examples in the recipes are run for real by the zope tests
  tools, so they are up to date and should be therefore with a bit less
  errors.&lt;br /&gt;
  &lt;/p&gt;

  &lt;p&gt;If you are a writer, a translator, a z3 developer etc.. please join the
  &lt;a href="http://zope-cookbook.org"&gt;zope-cookbook.org&lt;/a&gt; project, to enhance
  its quality and build a good documentation source.&lt;br /&gt;
  &lt;br /&gt;
  &lt;/p&gt;</content>

  <id>tag:blogs.nuxeo.com:sections:blogs:tarek_ziade:2006_04_09_zope-cookbook-org-open-zope-3-cookbook-launched</id>
  <link rel="service.edit" type="application/atom+xml"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_04_09_zope-cookbook-org-open-zope-3-cookbook-launched/atom?2006_04_09_zope-cookbook-org-open-zope-3-cookbook-launched"
        title="Edit Here - zope-cookbook.org, an open Zope 3 cookbook launched !" />
</entry>

  
  
      <entry xmlns="http://purl.org/atom/ns#"
       xmlns:dc="http://purl.org/dc/elements/1.1/">
     
  <title mode="escaped" type="text/html">Python slides from xp-day (french)</title>
  <link rel="alternate" type="text/html"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_03_25_python-slides-from-xp-day-french" />
  <issued>2006-03-25T16:39:20Z</issued>
  <modified>2006-03-25T16:39:20Z</modified>
  <created>2006-03-25T10:49:36Z</created>
  <draft xmlns="http://purl.org/atom-blog/ns#">false</draft>
  <author>
    <name>tziade</name>
  </author>
  
  
    <dc:subject>python</dc:subject>
  
  
    <dc:subject>zope</dc:subject>
  
  
    <dc:subject>zope3</dc:subject>
  
  
  <summary type="text/html" mode="escaped">We have presented Python yesterday with Stéfane, at the
  
  french XP days conference (the first conference in France on eXtreme Programming and Agile methodologies), to demonstrate its agility.
   

The talk's title was "Python: un langage agile" ("Python: an agile programming language" in english)


   Here are the slides (in french)</summary>

  <content type="text/html" mode="escaped"
           xml:space="preserve">We have presented Python yesterday with &lt;a
  href="http://blogs.nuxeo.com/sections/blogs/fermigier"&gt;Stéfane&lt;/a&gt;, at the
  &lt;a
  href="http://xp-france.net/index.php?option=com_content&amp;amp;task=view&amp;amp;id=35&amp;amp;Itemid=104&amp;amp;mbfhack=0b5c237c45b87166131855d2d342c8cf"&gt;
  french XP days&lt;/a&gt; conference (the first conference in France on eXtreme Programming and Agile methodologies), to demonstrate its agility.&lt;br /&gt;
   &lt;br /&gt;

The talk's title was "Python: un langage agile" ("Python: an agile programming language" in english)
&lt;br/&gt;
&lt;br/&gt;
   Here are the slides (in french)&lt;br /&gt;</content>

  <id>tag:blogs.nuxeo.com:sections:blogs:tarek_ziade:2006_03_25_python-slides-from-xp-day-french</id>
  <link rel="service.edit" type="application/atom+xml"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_03_25_python-slides-from-xp-day-french/atom?2006_03_25_python-slides-from-xp-day-french"
        title="Edit Here - Python slides from xp-day (french)" />
</entry>

  
  
      <entry xmlns="http://purl.org/atom/ns#"
       xmlns:dc="http://purl.org/dc/elements/1.1/">
     
  <title mode="escaped" type="text/html">Python IDE Projects: joining the forces</title>
  <link rel="alternate" type="text/html"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_03_11_python-ide-projects-joining-forces" />
  <issued>2006-03-11T21:49:28Z</issued>
  <modified>2006-03-11T21:49:28Z</modified>
  <created>2006-03-11T21:41:33Z</created>
  <draft xmlns="http://purl.org/atom-blog/ns#">false</draft>
  <author>
    <name>tziade</name>
  </author>
  
  
    <dc:subject>python</dc:subject>
  
  
  <summary type="text/html" mode="escaped">Stani, from the SPE (Stani's Python Editor) project, has launched among
  other people, a website so all Python IDE projects out there can
  collaborate.
  
  Very cool !
  

   The news: http://pyxides.stani.be/news/launch

   

   The project: http://pyxides.stani.be/

   IDE Developers reactions: http://pyxides.stani.be/wiki/AuthorsOfIDEsTools
  </summary>

  <content type="text/html" mode="escaped"
           xml:space="preserve">Stani, from the SPE (Stani's Python Editor) project, has launched among
  other people, a website so all Python IDE projects out there can
  collaborate.&lt;br /&gt;
  &lt;br /&gt;
  Very cool !&lt;br /&gt;
  &lt;br /&gt;
&lt;ul&gt;
   &lt;li&gt;The news: &lt;a
   href="http://pyxides.stani.be/news/launch"&gt;http://pyxides.stani.be/news/launch&lt;/a&gt;&lt;br /&gt;

   &lt;/li&gt;

   &lt;li&gt;The project: &lt;a
   href="http://pyxides.stani.be/"&gt;http://pyxides.stani.be/&lt;/a&gt;&lt;/li&gt;

   &lt;li&gt;IDE Developers reactions: &lt;a
   href="http://pyxides.stani.be/wiki/AuthorsOfIDEsTools"&gt;http://pyxides.stani.be/wiki/AuthorsOfIDEsTools&lt;/a&gt;&lt;/li&gt;
  &lt;/ul&gt;</content>

  <id>tag:blogs.nuxeo.com:sections:blogs:tarek_ziade:2006_03_11_python-ide-projects-joining-forces</id>
  <link rel="service.edit" type="application/atom+xml"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_03_11_python-ide-projects-joining-forces/atom?2006_03_11_python-ide-projects-joining-forces"
        title="Edit Here - Python IDE Projects: joining the forces" />
</entry>

  
  
      <entry xmlns="http://purl.org/atom/ns#"
       xmlns:dc="http://purl.org/dc/elements/1.1/">
     
  <title mode="escaped" type="text/html">Advanced Through-The-Web (TTW) Document Type creation with CPSTypeMaker</title>
  <link rel="alternate" type="text/html"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_03_06_advanced-trough-web-type-creation-wth-cpstypemaker" />
  <issued>2006-03-06T14:51:46Z</issued>
  <modified>2006-03-06T14:51:46Z</modified>
  <created>2006-03-06T14:45:34Z</created>
  <draft xmlns="http://purl.org/atom-blog/ns#">false</draft>
  <author>
    <name>tziade</name>
  </author>
  
  
    <dc:subject>AJAX</dc:subject>
  
  
    <dc:subject>cps</dc:subject>
  
  
    <dc:subject>zope</dc:subject>
  
  
    <dc:subject>zope3</dc:subject>
  
  
  <summary type="text/html" mode="escaped">CPSTypeMaker provides a simple yet powerfull way
to create new document types over a CPS portal.

It drives CPSSchemas to let the user creates new types over the web,
with a simple editor where new fields can be added and a layout
created with the mouse
Thanks to CPSSchemas architecture, a document type can be changed in the fly,
and all its existings instances automatically ...</summary>

  <content type="text/html" mode="escaped"
           xml:space="preserve">&lt;p&gt;CPSTypeMaker provides a simple yet powerfull way
to create new document types over a CPS portal.&lt;/p&gt;

&lt;p&gt;It drives CPSSchemas to let the user creates new types over the web,
with a simple editor where new fields can be added and a layout
created with the mouse&lt;/p&gt;
&lt;p&gt;Thanks to CPSSchemas architecture, a document type can be changed in the fly,
and all its existings instances automatically updated&lt;/p&gt;

&lt;p&gt;This tool generates Python dictionnaries that are usually coded by hand, 
and therefore exportable to embed the new types in Zope Products&lt;/p&gt;

&lt;p&gt;In the future CPSTypeMaker might evolve in a generic visual editor, that can generate CPSSchemas document types or any other type of document description (xml, etc..), through a plugins system&lt;/p&gt;
  
&lt;p&gt;In the screencast below (aggregator readers, you should visualize this entry in a flash-enabled browser), a new "Person" type is created, and an instance created. 

Then the type is extended with an extra field, that is automatically made available 
in existing instances&lt;/p&gt;

&lt;object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="800" height="600"
 codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=5,0,0,0"&gt;
 &lt;param name="movie" value="typemaker.swf"&gt;
 &lt;param name="play" value="true"&gt;

 &lt;param name="loop" value="True"&gt;
 &lt;param name="quality" value="low"&gt;
&lt;embed src="typemaker.swf" width="800" height="600" play="true"
 loop="True" quality="low" type="application/x-shockwave-flash"
 pluginspage="http://www.macromedia.com/go/getflashplayer"&gt;
&lt;/embed&gt;
&lt;/object&gt;</content>

  <id>tag:blogs.nuxeo.com:sections:blogs:tarek_ziade:2006_03_06_advanced-trough-web-type-creation-wth-cpstypemaker</id>
  <link rel="service.edit" type="application/atom+xml"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_03_06_advanced-trough-web-type-creation-wth-cpstypemaker/atom?2006_03_06_advanced-trough-web-type-creation-wth-cpstypemaker"
        title="Edit Here - Advanced Through-The-Web (TTW) Document Type creation with CPSTypeMaker" />
</entry>

  
  
      <entry xmlns="http://purl.org/atom/ns#"
       xmlns:dc="http://purl.org/dc/elements/1.1/">
     
  <title mode="escaped" type="text/html">A few rules to keep in mind when using Ajax</title>
  <link rel="alternate" type="text/html"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_02_19_few-rules-to-keep-in-mind-when-using-ajax" />
  <issued>2006-02-19T15:06:53Z</issued>
  <modified>2006-02-19T15:06:53Z</modified>
  <created>2006-02-19T15:02:17Z</created>
  <draft xmlns="http://purl.org/atom-blog/ns#">false</draft>
  <author>
    <name>tziade</name>
  </author>
  
  
    <dc:subject>AJAX</dc:subject>
  
  
    <dc:subject>cps</dc:subject>
  
  
    <dc:subject>zope</dc:subject>
  
  
    <dc:subject>zope3</dc:subject>
  
  
  <summary type="text/html" mode="escaped">In this entry, I try to sum up some rules that should be looked over when
  adding AJAX features in a CMS. 
   
   

  keep accessibility
  
   A CMS is used by a wide variety of people and WAI rules should be kept in
  mind. All functions and screens should be usable even though javascript is
  not enabled. 
   
   This means that AJAX features have to be implemented with methods ...</summary>

  <content type="text/html" mode="escaped"
           xml:space="preserve">In this entry, I try to sum up some rules that should be looked over when
  adding AJAX features in a CMS. &lt;br /&gt;
   &lt;br /&gt;
   

  &lt;h3&gt;keep accessibility&lt;/h3&gt;
  &lt;br /&gt;
   A CMS is used by a wide variety of people and WAI rules should be kept in
  mind. All functions and screens should be usable even though javascript is
  not enabled. &lt;br /&gt;
   &lt;br /&gt;
   This means that AJAX features have to be implemented with methods like
  graceful degradation to avoid the CMS to be dependent on Javascript
  features.&lt;br /&gt;
   &lt;br /&gt;
   Most of the time, this is quite easy to implement a Javascript enhanced
  version over a regular version, but sometimes two version has to be
  developed in parallel, like gmail for example does. &lt;br /&gt;
   &lt;br /&gt;
   There are few exceptions for this rule: &lt;br /&gt;
   &lt;br /&gt;
   

  &lt;ul&gt;
   &lt;li&gt;it's ok to develop managment screens or backoffice screens in
   javascript&lt;/li&gt;
  &lt;/ul&gt;

  &lt;ul&gt;
   &lt;li&gt;same things for some products like webmails, calendars: people that
   really need accessibility for these very specific products will use
   specialized pieces of softwares.&lt;/li&gt;
  &lt;/ul&gt;

  &lt;ul&gt;
   &lt;li&gt;the product is very specific, and ajax is used for example to reduce
   network bandwidth. example: MacRumorsLive&lt;/li&gt;
  &lt;/ul&gt;
  &lt;br /&gt;
   

  &lt;h3&gt;one state, one url&lt;/h3&gt;
  &lt;br /&gt;
   This is probably one of the most important point. When developing ajax
  interfaces, it's very tempting to develop advanced screens that let the user
  play around without doing direct calls. &lt;br /&gt;
   &lt;br /&gt;
   The javascript retrieves datas asynchronously from the server and refresh
  the interface, the user makes changes, and the javascript display these
  changes directly. &lt;br /&gt;
   &lt;br /&gt;
   One of the common approach is to use a "model-driven" infrastructure that
  let the different interface elements get synchronized with a local pool of
  data, using xml transformation or, like in some recent developments, using
  things like CTAL. In other words, if the user changes the data through one
  interface, like an input text, a button, or anything else, the local data
  pool is changed and other part of the screens are refreshed
  consequently.&lt;br /&gt;
   &lt;br /&gt;
   It's a great approach as long as the rendered screen looks exactly as it
  would look if another user would load the same url in her browser.&amp;nbsp;
  This means that the server state should always be synchronized with what the
  user is doing. &lt;br /&gt;
   &lt;br /&gt;
   So having a local pool of data (what people call "model-driven") is more
  likely to be an optimisation to minimize exchanges by having a local cache,
  and should be done with this rule in mind. &lt;br /&gt;
   &lt;br /&gt;
   Of course the benefit of this approach also let the client-side calculate
  the interface itself. In this case the javascript becomes a template engine
  and push the server to a single role wich is: data provider; but this has to
  be done with the first rule in mind: a javascript template engine won't work
  under lynx, and having two mecanisms to do the same thing can be hard to
  keep growing together. &lt;br /&gt;
   &lt;br /&gt;
   Back to the one state, one url rule. &lt;br /&gt;
   &lt;br /&gt;
   If this rule is not respected, third party softwares, like search engines,
  or xml-rpc callers, won't be able to use the web application because they
  use urls as single state elements. Moreover, users most of the time expect a
  given url to give them the same result (that's why the "favorite" button
  exists) &lt;br /&gt;
   &lt;br /&gt;
   

  &lt;h3&gt;use test-driven approach, and automate tests&lt;br /&gt;
  &lt;/h3&gt;
  &lt;br /&gt;
   Most of the time, a piece of javascript is not well tested. Developers
  should work in a test-driven development (TDD) way like they do in their
  main language. &lt;br /&gt;
   &lt;br /&gt;
   All actual Javascript toolkit now has everything needed to set up test
  automation, and let the developpers benefit from TDD. &lt;br /&gt;
   &lt;br /&gt;
   Moreover, Javascript pieces should be tested over all possible execution
  contexts. A tool like Selenium can be used to automate functional test over
  all kind of browsers. &lt;br /&gt;
   &lt;br /&gt;
   References:&lt;br /&gt;
   

  &lt;ul&gt;
   &lt;li&gt;Why Ajax Sucks, by Chris McEvoy, &lt;a
   href="http://www.usabilityviews.com/ajaxsucks.html"&gt;http://www.usabilityviews.com/ajaxsucks.html&lt;/a&gt;&lt;/li&gt;

   &lt;li&gt;one state, one url not respected example: &lt;a
   href="http://weblogs.asp.net/mschwarz/archive/2005/08/06/421761.aspx%3E"&gt;http://weblogs.asp.net/mschwarz/archive/2005/08/06/421761.aspx&lt;/a&gt;&lt;/li&gt;

   &lt;li&gt;MacRumorsLive: &lt;a
   href="http://www.digg.com/apple/macrumorslive.com_using_AJAX_to_update_their_MacWorld_news"&gt;
   http://www.digg.com/apple/macrumorslive.com_using_AJAX_to_update_their_MacWorld_news&lt;/a&gt;&lt;/li&gt;

   &lt;li&gt;WAI: &lt;a href="http://www.w3.org/WAI/"&gt;http://www.w3.org/WAI/&lt;/a&gt;&lt;br /&gt;
   &lt;/li&gt;
  &lt;/ul&gt;</content>

  <id>tag:blogs.nuxeo.com:sections:blogs:tarek_ziade:2006_02_19_few-rules-to-keep-in-mind-when-using-ajax</id>
  <link rel="service.edit" type="application/atom+xml"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_02_19_few-rules-to-keep-in-mind-when-using-ajax/atom?2006_02_19_few-rules-to-keep-in-mind-when-using-ajax"
        title="Edit Here - A few rules to keep in mind when using Ajax" />
</entry>

  
  
      <entry xmlns="http://purl.org/atom/ns#"
       xmlns:dc="http://purl.org/dc/elements/1.1/">
     
  <title mode="escaped" type="text/html">CPS Ajaxification, round #6 a dynamic tree and an event oserver</title>
  <link rel="alternate" type="text/html"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_02_17_cps-ajaxification-round-6-dynamic-tree-an-event-oserver" />
  <issued>2006-02-17T23:23:53Z</issued>
  <modified>2006-02-17T23:23:53Z</modified>
  <created>2006-02-17T22:42:53Z</created>
  <draft xmlns="http://purl.org/atom-blog/ns#">false</draft>
  <author>
    <name>tziade</name>
  </author>
  
  
    <dc:subject>AJAX</dc:subject>
  
  
    <dc:subject>cps</dc:subject>
  
  
    <dc:subject>five</dc:subject>
  
  
    <dc:subject>zope</dc:subject>
  
  
    <dc:subject>zope3</dc:subject>
  
  
  <summary type="text/html" mode="escaped">Features

The treeview that we wanted is pretty similar to what Zope 3 has
(xmltree), except that it one is implemented with scriptaculous. The principles are quite simple: branches of the tree are asynchronously loaded
through Javascript whenever we need it. Scriptaculous provides the nice fade-in effect, which make the whole thing looks good.

Now the biggest deal was to be able to hook ...</summary>

  <content type="text/html" mode="escaped"
           xml:space="preserve">&lt;h3&gt;Features&lt;/h3&gt;

&lt;p&gt;The treeview that we wanted is pretty similar to what Zope 3 has
(xmltree), except that it one is implemented with scriptaculous. The principles are quite simple: branches of the tree are asynchronously loaded
through Javascript whenever we need it. Scriptaculous provides the nice fade-in effect, which make the whole thing looks good.&lt;/p&gt;

&lt;p&gt;Now the biggest deal was to be able to hook the treeview with what happens
in the center of the page.&lt;/p&gt;

&lt;p&gt;Since some drag'and'drop features were previously added, the tree needs
to be refreshed whenever a drop which changes the structure of the portal is made. In our case, it happens when folders are reordered or a folder is dropped
over the treeview. A event mechanism has been created, in order to be able to refresh the treeview whenever a 'drop event' happens.&lt;/p&gt;

&lt;p&gt;See 'implementation details' section for some details.&lt;/p&gt;

&lt;h3&gt;Screencast&lt;/h3&gt; 
&lt;br/&gt;
&lt;object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="852" height="480"
 codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=5,0,0,0"&gt;
 &lt;param name="movie" value="dragdrop.swf"&gt;
 &lt;param name="play" value="true"&gt;

 &lt;param name="loop" value="True"&gt;
 &lt;param name="quality" value="low"&gt;
&lt;embed src="dragdrop.swf" width="852" height="480" play="true"
 loop="True" quality="low" type="application/x-shockwave-flash"
 pluginspage="http://www.macromedia.com/go/getflashplayer"&gt;
&lt;/embed&gt;&lt;/object&gt;&lt;br/&gt;
&lt;i&gt;(if you read this entry through a aggregator, you should open your flash enabled browser
to see the screencast)
&lt;/i&gt;
&lt;h3&gt;Implementation&lt;/h3&gt;

&lt;p&gt;The treeview is displayed in a portlet, which is, thanks to the briliant people that have thaught it, a standalone document. In other words, a simple Five view was the only thing to add to be able to query the server for an fresh version of the portlet&lt;/p&gt;

&lt;p&gt;The treeview acts as an observer over the page, registering itself on all 'drop' events. This is done with a simple javascript class that gathers for each event name, a list of functions to call when the event is triggered. The drag'n'drop features triggers the so-called event, and the function asynchronously gets the new rendered portlet&lt;/p&gt; 

All the code is viewable here: &lt;a href="http://svn.nuxeo.org/trac/pub/browser/CPSPortlets/trunk/browser/"&gt;http://svn.nuxeo.org/trac/pub/browser/CPSPortlets/trunk/browser/&lt;/a&gt;
&lt;br/&gt;and here is the class that register event observers and trigger them : &lt;a href="http://svn.nuxeo.org/trac/pub/file/CPSDefault/trunk/skins/cps_javascript/cpsdefault.js.dtml"&gt;http://svn.nuxeo.org/trac/pub/file/CPSDefault/trunk/skins/cps_javascript/cpsdefault.js.dtml&lt;/a&gt; (see at end of file)</content>

  <id>tag:blogs.nuxeo.com:sections:blogs:tarek_ziade:2006_02_17_cps-ajaxification-round-6-dynamic-tree-an-event-oserver</id>
  <link rel="service.edit" type="application/atom+xml"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_02_17_cps-ajaxification-round-6-dynamic-tree-an-event-oserver/atom?2006_02_17_cps-ajaxification-round-6-dynamic-tree-an-event-oserver"
        title="Edit Here - CPS Ajaxification, round #6 a dynamic tree and an event oserver" />
</entry>

  
  
      <entry xmlns="http://purl.org/atom/ns#"
       xmlns:dc="http://purl.org/dc/elements/1.1/">
     
  <title mode="escaped" type="text/html">My Python slides from Linux Solutions '06</title>
  <link rel="alternate" type="text/html"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_02_04_my-slides-from-linux" />
  <issued>2006-02-04T22:57:19Z</issued>
  <modified>2006-02-04T22:57:19Z</modified>
  <created>2006-02-04T22:54:01Z</created>
  <draft xmlns="http://purl.org/atom-blog/ns#">false</draft>
  <author>
    <name>tziade</name>
  </author>
  
  
    <dc:subject>nuxeo</dc:subject>
  
  
    <dc:subject>python</dc:subject>
  
  
  <summary type="text/html" mode="escaped">Here's my slides (in french) from my presentation in Paris at Linux Solutions. 
  
  These slides present "Python Best Practices". 
  
  The main idea was to explain to people that are unfamiliar with Python and
  uses other langages in their work, that it's a fully qualified langage for
  best practices, like test-driven development. It introduces also some tools
  like Pyrex and Psyco.</summary>

  <content type="text/html" mode="escaped"
           xml:space="preserve">Here's my slides (in french) from my presentation in Paris at &lt;a
  href="http://www.solutionslinux.fr/fr/index.php"&gt;Linux Solutions&lt;/a&gt;. &lt;br /&gt;
  &lt;br /&gt;
  These slides present "Python Best Practices". &lt;br /&gt;
  &lt;br /&gt;
  The main idea was to explain to people that are unfamiliar with Python and
  uses other langages in their work, that it's a fully qualified langage for
  best practices, like test-driven development. It introduces also some tools
  like Pyrex and Psyco.</content>

  <id>tag:blogs.nuxeo.com:sections:blogs:tarek_ziade:2006_02_04_my-slides-from-linux</id>
  <link rel="service.edit" type="application/atom+xml"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_02_04_my-slides-from-linux/atom?2006_02_04_my-slides-from-linux"
        title="Edit Here - My Python slides from Linux Solutions '06" />
</entry>

  
  
      <entry xmlns="http://purl.org/atom/ns#"
       xmlns:dc="http://purl.org/dc/elements/1.1/">
     
  <title mode="escaped" type="text/html">CPS Ajaxification round #5: A one-step publishing process</title>
  <link rel="alternate" type="text/html"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_01_20_cps-ajaxification-round" />
  <issued>2006-01-20T02:48:26Z</issued>
  <modified>2006-01-20T02:48:26Z</modified>
  <created>2006-01-20T02:30:37Z</created>
  <draft xmlns="http://purl.org/atom-blog/ns#">false</draft>
  <author>
    <name>tziade</name>
  </author>
  
  
    <dc:subject>AJAX</dc:subject>
  
  
    <dc:subject>cps</dc:subject>
  
  
    <dc:subject>zope</dc:subject>
  
  
    <dc:subject>zope3</dc:subject>
  
  
  <summary type="text/html" mode="escaped">In this screencast, the view that let people change the elements order has
been extended in order to be able to drop them on the navigation portlet,
and therefore move elements in other folders.


The interesting part of this approach is about publishing: as seen in the
animation, when "Link 1" is dragged from its workspace to a section
of the portal, it is automatically published, and ...</summary>

  <content type="text/html" mode="escaped"
           xml:space="preserve">&lt;p&gt;In this screencast, the view that let people change the elements order has
been extended in order to be able to drop them on the navigation portlet,
and therefore move elements in other folders.
&lt;/p&gt;
&lt;p&gt;
The interesting part of this approach is about publishing: as seen in the
animation, when "Link 1" is dragged from its workspace to a section
of the portal, it is automatically published, and follows the right workflow transition.
&lt;/p&gt;
&lt;p&gt;
This &lt;b&gt;one step&lt;/b&gt; publishing process should be very useful to avoid 
the intermediate screen where we choose a publishing place.
&lt;/p&gt;
&lt;p&gt;Another eye-candy effect has been added when a drop cannot
be performed: the small ajax floating layer pulsates and turns red: it's angry ;)&lt;/p&gt;
&lt;br/&gt;

&lt;object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="640" height="480"
 codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=5,0,0,0"&gt;
&lt;param name="movie" value="dragdrop4.swf"&gt;
&lt;param name="play" value="true"&gt;
&lt;param name="loop" value="true"&gt;
&lt;param name="quality" value="high"&gt;
&lt;embed src="dragdrop4.swf" width="640" height="480"
 play="true" align="" loop="true" quality="high" type="application/x-shockwave-flash"
 pluginspage="http://www.macromedia.com/go/getflashplayer"&gt;&lt;/embed&gt;
&lt;/object&gt;
&lt;br/&gt;
&lt;i&gt;Feed readers, there's a flash animation in this entry, you should use your browser in order to see it&lt;/i&gt;</content>

  <id>tag:blogs.nuxeo.com:sections:blogs:tarek_ziade:2006_01_20_cps-ajaxification-round</id>
  <link rel="service.edit" type="application/atom+xml"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_01_20_cps-ajaxification-round/atom?2006_01_20_cps-ajaxification-round"
        title="Edit Here - CPS Ajaxification round #5: A one-step publishing process" />
</entry>

  
  
      <entry xmlns="http://purl.org/atom/ns#"
       xmlns:dc="http://purl.org/dc/elements/1.1/">
     
  <title mode="escaped" type="text/html">"Programmation Python" french book is out!</title>
  <link rel="alternate" type="text/html"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_01_19_programmation-python" />
  <issued>2006-01-18T23:40:52Z</issued>
  <modified>2006-01-18T23:40:52Z</modified>
  <created>2006-01-18T23:40:06Z</created>
  <draft xmlns="http://purl.org/atom-blog/ns#">false</draft>
  <author>
    <name>tziade</name>
  </author>
  
  
    <dc:subject>python</dc:subject>
  
  
    <dc:subject>zope</dc:subject>
  
  
  <summary type="text/html" mode="escaped">My french book about Python is out now ! 
  
  I would like to thank Stéfane and
  Stephan Richter for the great forewords they provided for this book. 
  
  Like 
  Stéfane previously said, a dedicated site has been made to cover errata,
  news around the book, and all usual stuff.
  
  French readers, a contest is running in order to win a book, try to answer
  to those
  very hard ...</summary>

  <content type="text/html" mode="escaped"
           xml:space="preserve">My french book about Python is out now ! &lt;br /&gt;
  &lt;br /&gt;
  I would like to thank &lt;a
  href="http://blogs.nuxeo.com/sections/blogs/fermigier"&gt;Stéfane&lt;/a&gt; and
  Stephan Richter for the great forewords they provided for this book. &lt;br /&gt;
  &lt;br /&gt;
  Like &lt;a
  href="http://blogs.nuxeo.com/sections/blogs/fermigier/2006_01_16_programmation-python"&gt;
  Stéfane previously said&lt;/a&gt;, a dedicated site has been made to cover errata,
  news around the book, and all usual stuff.&lt;br /&gt;
  &lt;br /&gt;
  French readers, a contest is running in order to win a book, try to answer
  to &lt;a
  href="http://programmation-python.org/sections/news/sortie-du-livre-et"&gt;those
  very hard questions&lt;/a&gt; :)&lt;br /&gt;</content>

  <id>tag:blogs.nuxeo.com:sections:blogs:tarek_ziade:2006_01_19_programmation-python</id>
  <link rel="service.edit" type="application/atom+xml"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_01_19_programmation-python/atom?2006_01_19_programmation-python"
        title="Edit Here - &quot;Programmation Python&quot; french book is out!" />
</entry>

  
  
      <entry xmlns="http://purl.org/atom/ns#"
       xmlns:dc="http://purl.org/dc/elements/1.1/">
     
  <title mode="escaped" type="text/html">CPS Ajaxification round #4: Zope 3 ajax view to change Zope 2 container order</title>
  <link rel="alternate" type="text/html"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_01_11_cps-ajaxification-round" />
  <issued>2006-01-12T15:08:02Z</issued>
  <modified>2006-01-12T15:08:02Z</modified>
  <created>2006-01-11T19:55:21Z</created>
  <draft xmlns="http://purl.org/atom-blog/ns#">false</draft>
  <author>
    <name>tziade</name>
  </author>
  
  
    <dc:subject>AJAX</dc:subject>
  
  
    <dc:subject>cps</dc:subject>
  
  
    <dc:subject>zope</dc:subject>
  
  
    <dc:subject>zope3</dc:subject>
  
  
  <summary type="text/html" mode="escaped">In this round, the objective is to add a feature in ordered folders
in CPS, that let the user drag elements and drop them within the same
page, to change the elements order.
Here's the result:








Macromedia Flash Plugin required


This is quite simple, even though the javascript part gets a bit
longer and tougher to create than the previous rounds,
but more interesting ...</summary>

  <content type="text/html" mode="escaped"
           xml:space="preserve">&lt;p&gt;In this round, the objective is to add a feature in ordered folders
in CPS, that let the user drag elements and drop them within the same
page, to change the elements order.&lt;/p&gt;
&lt;p&gt;Here's the result:&lt;/p&gt;
&lt;object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" 
      width="640" height="480" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=5,0,0,0"&gt;
&lt;param name="movie" value="cpsdragdrop.swf"&gt;
&lt;param name="play" value="true"&gt;
&lt;param name="loop" value="true"&gt;
&lt;param name="quality" value="high"&gt;
&lt;embed src="cpsdragdrop.swf"" width="640" height="480"
 play="true" align="" loop="true" quality="high" type="application/x-shockwave-flash"
 pluginspage="http://www.macromedia.com/go/getflashplayer"&gt;&lt;/embed&gt;
&lt;/object&gt;
&lt;br/&gt;
&lt;span&gt;&lt;a href="http://www.macromedia.com/"&gt;Macromedia Flash Plugin&lt;/a&gt; required&lt;/span&gt;


&lt;p&gt;This is quite simple, even though the javascript part gets a bit
longer and tougher to create than the previous rounds,
but more interesting because we are going to add server-side code
that can be reused later on in Zope 3.&lt;/p&gt;
&lt;div class="section" id="zope-3-style-server-side"&gt;
&lt;h1&gt;&lt;a name="zope-3-style-server-side"&gt;Zope 3 style server-side&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;Doing this feature in Zope 3, would involve coding some kind
of Ajax view that would know how to deal with the current context
(ie: the ordered folder) and a directive in the zcml, in order
to hook the view with a method associated to the current folder.&lt;/p&gt;
&lt;p&gt;Thanks to Five, we can use this path within Zope 2.&lt;/p&gt;
&lt;p&gt;The view which is quite simple, introduces a method that simply
gets the id of the element that is beeing dragged and the id of the
element that receives the drop. It returns the new order, so
the javascript side can play with the DOM to reorder the list:&lt;/p&gt;
&lt;pre class="literal-block"&gt;
from Products.Five import BrowserView

class AjaxFolderView(BrowserView):

    def moveElement(self, from_id, to_id):

        if (not from_id.startswith('draggable') or
            not to_id.startswith('droppable')):
            return ''

        from_id = from_id[len('draggable'):]
        to_id = to_id[len('droppable'):]

        if from_id == to_id:
            return ''

        proxy_folder = self.context
        to_position = proxy_folder.getObjectPosition(to_id)
        proxy_folder.moveObjectToPosition(from_id, to_position)

        return ':'.join([id for id in proxy_folder.objectIds()
                        if not id.startswith('.')])
&lt;/pre&gt;
&lt;p&gt;This view derives from Five's BrowserView, in order to be able to hook
it in the zcml. The zcml just associates the &lt;cite&gt;IOrderedContainer&lt;/cite&gt; interface:&lt;/p&gt;

&lt;pre class="literal-block"&gt;
&amp;lt;configure xmlns=&amp;quot;http://namespaces.zope.org/zope&amp;quot;
        xmlns:five=&amp;quot;http://namespaces.zope.org/five&amp;quot;
        xmlns:browser=&amp;quot;http://namespaces.zope.org/browser&amp;quot;
        xmlns:i18n=&amp;quot;http://namespaces.zope.org/i18n&amp;quot;
        i18n_domain=&amp;quot;cpsdefault&amp;quot;

        &amp;gt;

&amp;lt;browser:page
    for=&amp;quot;OFS.interfaces.IOrderedContainer&amp;quot;
    name=&amp;quot;ajaxMoveElement&amp;quot;
    class=&amp;quot;.browser.ajaxfolderview.AjaxFolderView&amp;quot;
    attribute=&amp;quot;moveElement&amp;quot;

    permission=&amp;quot;zope.Public&amp;quot;/&amp;gt; &amp;lt;!-- TODO: secure the method --&amp;gt;
&amp;lt;/configure&amp;gt;
&lt;/pre&gt;
&lt;p&gt;That's it ! The server-side infrastructure provides now a method in all ordered
folders that can be used asynchronously by any ajax toolkit.&lt;/p&gt;
&lt;/div&gt;
&lt;div class="section" id="client-side"&gt;
&lt;h1&gt;&lt;a name="client-side"&gt;Client-side&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;The client side can be found here in a branch of CPSDefault: &lt;a href="http://svn.nuxeo.org/trac/pub/browser/CPSDefault/branches/tziade_dragdrop/skins/cps_javascript/"&gt;client side&lt;/a&gt; &lt;/p&gt;</content>

  <id>tag:blogs.nuxeo.com:sections:blogs:tarek_ziade:2006_01_11_cps-ajaxification-round</id>
  <link rel="service.edit" type="application/atom+xml"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_01_11_cps-ajaxification-round/atom?2006_01_11_cps-ajaxification-round"
        title="Edit Here - CPS Ajaxification round #4: Zope 3 ajax view to change Zope 2 container order" />
</entry>

  
  
      <entry xmlns="http://purl.org/atom/ns#"
       xmlns:dc="http://purl.org/dc/elements/1.1/">
     
  <title mode="escaped" type="text/html">CPS Ajaxification round #3</title>
  <link rel="alternate" type="text/html"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_01_06_cps-ajaxification-round" />
  <issued>2006-01-12T15:31:05Z</issued>
  <modified>2006-01-12T15:31:05Z</modified>
  <created>2006-01-06T16:34:30Z</created>
  <draft xmlns="http://purl.org/atom-blog/ns#">false</draft>
  <author>
    <name>tziade</name>
  </author>
  
  
    <dc:subject>AJAX</dc:subject>
  
  
    <dc:subject>cps</dc:subject>
  
  
    <dc:subject>rich_client</dc:subject>
  
  
    <dc:subject>zope</dc:subject>
  
  
    <dc:subject>zope3</dc:subject>
  
  
  <summary type="text/html" mode="escaped">Sometimes images are betters than explanations...


Here's a small flash movie that shows the use of scriptaculous cinematics
in CPSWiki, wich allows the user to work on the wiki through Ajax.


The resolution might not be displaying well on the blog, 
so you can also download the movie here if you want a better experience:

cpswiki.swf








</summary>

  <content type="text/html" mode="escaped"
           xml:space="preserve">&lt;p&gt;Sometimes images are betters than explanations...&lt;/p&gt;

&lt;p&gt;
Here's a small flash movie that shows the use of scriptaculous cinematics
in CPSWiki, wich allows the user to work on the wiki through Ajax.
&lt;/p&gt;

&lt;p&gt;The resolution might not be displaying well on the blog, 
so you can also download the movie here if you want a better experience:&lt;br/&gt;

&lt;a href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/cpswiki.swf"&gt;cpswiki.swf&lt;/a&gt;

&lt;br/&gt;&lt;br/&gt;
&lt;object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="640" height="480"
 codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=5,0,0,0"&gt;
&lt;param name="movie" value="cpswiki.swf"&gt;
&lt;param name="play" value="true"&gt;
&lt;param name="loop" value="true"&gt;
&lt;param name="quality" value="high"&gt;
&lt;embed src="cpswiki.swf" width="640" height="480"
 play="true" align="" loop="true" quality="high" type="application/x-shockwave-flash"
 pluginspage="http://www.macromedia.com/go/getflashplayer"&gt;&lt;/embed&gt;
&lt;/object&gt;</content>

  <id>tag:blogs.nuxeo.com:sections:blogs:tarek_ziade:2006_01_06_cps-ajaxification-round</id>
  <link rel="service.edit" type="application/atom+xml"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_01_06_cps-ajaxification-round/atom?2006_01_06_cps-ajaxification-round"
        title="Edit Here - CPS Ajaxification round #3" />
</entry>

  
  
      <entry xmlns="http://purl.org/atom/ns#"
       xmlns:dc="http://purl.org/dc/elements/1.1/">
     
  <title mode="escaped" type="text/html">CPS Ajaxification round #2</title>
  <link rel="alternate" type="text/html"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_01_05_cps-ajaxification-round" />
  <issued>2006-01-05T21:41:16Z</issued>
  <modified>2006-01-05T21:41:16Z</modified>
  <created>2006-01-05T21:41:15Z</created>
  <draft xmlns="http://purl.org/atom-blog/ns#">false</draft>
  <author>
    <name>tziade</name>
  </author>
  
  
    <dc:subject>AJAX</dc:subject>
  
  
    <dc:subject>cps</dc:subject>
  
  
    <dc:subject>rich_client</dc:subject>
  
  
    <dc:subject>zope</dc:subject>
  
  
    <dc:subject>zope3</dc:subject>
  
  
  <summary type="text/html" mode="escaped">
I really enjoy the graceful degradation approach. It's a pleasure
to enhance CPS user interfaces that way.
Last time the edit form for simple document was ajaxified in order
to give the user a fast way to get feedback when she changes the data.

The next challenging step on these form is to enable file uploads
so complex documents will be ajaxified as well. The iframe technique
is the ...</summary>

  <content type="text/html" mode="escaped"
           xml:space="preserve">&lt;div class="document" id="cps-ajaxification-round-2"&gt;
&lt;p&gt;I really enjoy the graceful degradation approach. It's a pleasure
to enhance CPS user interfaces that way.&lt;/p&gt;
&lt;p&gt;&lt;a class="reference" href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2005_12_16_cps-ajaxification-round"&gt;Last time&lt;/a&gt; the edit form for &lt;cite&gt;simple&lt;/cite&gt; document was ajaxified in order
to give the user a fast way to get feedback when she changes the data.&lt;/p&gt;

&lt;p&gt;The next challenging step on these form is to enable file uploads
so &lt;cite&gt;complex&lt;/cite&gt; documents will be ajaxified as well. The &lt;cite&gt;iframe technique&lt;/cite&gt;
is the only technique i've hurd of for this task. Some guys over the Ruby ML
also explained me how to do it with a bit of Flash in the form but this
is a dependency we don't want. Anyway, this enhancement will be exposed
in round #3 or #4.&lt;/p&gt;
&lt;p&gt;Round #2 is about a quick and lazy todo, yet powerfull feature: autocompletion.&lt;/p&gt;
&lt;p&gt;This is just great: with Scriptaculous there's absolutely nothing to code :).
The well-thaught &lt;cite&gt;Ajax.Autocompleter&lt;/cite&gt; class knows automatically how to grab
an input field and link it to a server-side &lt;em&gt;or&lt;/em&gt; a client-side data provider.&lt;/p&gt;

&lt;p&gt;The class deals with all the hard work, automatically showing and
hiding the panel that contains the choices. Every command you would think
of to select an element from the list (keyboard, mouse) just works as
expected.&lt;/p&gt;
&lt;p&gt;I won't expose how all this works, just take a look at &lt;a class="reference" href="http://demo.script.aculo.us/ajax/autocompleter_customized"&gt;this demo&lt;/a&gt; and
enjoy their work.&lt;/p&gt;
&lt;div class="section" id="client-side-data-or-server-side-data"&gt;
&lt;h1&gt;&lt;a name="client-side-data-or-server-side-data"&gt;Client-side data or server-side data ?&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;Like said previously, a decision has to be made when this kind of widgets
are used: where does the data that feeds the popup panel live ?&lt;/p&gt;
&lt;p&gt;That's a topic you can talk about for hours with &lt;a class="reference" href="http://radio.weblogs.com/0116506/"&gt;Paul Everitt&lt;/a&gt;, who
is a preacher of the full client-side approach. In his demos, Paul loads
data at startup and play with it on the form through javascript.&lt;/p&gt;
&lt;p&gt;It's very impressive, as the whole screen can be repainted without calling
the server ever.&lt;/p&gt;

&lt;p&gt;If I were working at BuzzwordMakers Corp., I would call this approach
the Lazy Ajax Painting (LAP).&lt;/p&gt;
&lt;p&gt;But too much LAPing can deteriorate the user experience: the lag involved
can be really bad, and she might try to refresh the page over and over again,
because it seems locked or some similar feeling.&lt;/p&gt;
&lt;p&gt;Furthermore, the retrieved data is dead: if someone else changes it on
the server it won't change on her client browser, unless an expensive observer
that recheck datas once a while is settled.&lt;/p&gt;
&lt;p&gt;On the other hand, too much asynchronous server calls can drawn everything
as well...&lt;/p&gt;
&lt;p&gt;But autocompletion means the output is beeing filtered out at least by the first
character, so the amount of data is not so bad.&lt;/p&gt;
&lt;p&gt;For example, if the widget is used to select some people over a LDAP directory
that contains 5k users, the first data packet will be composed of an average of
200 entries at most. The second character put this number down to 8 entries
or so. In case of a big directory, a smart approach would be to block the
autocompletion feature until the user has typed a few characters.&lt;/p&gt;
&lt;p&gt;Anyway, this is the same scale than regular queries over directories, so a full
server-side data provider is probably the way to go in most case.&lt;/p&gt;
&lt;p&gt;If needed, the widget can combine both ways, and decide which one to use depending
on the amount of data.&lt;/p&gt;

&lt;/div&gt;
&lt;div class="section" id="cpsautocompletionstring-widget"&gt;
&lt;h1&gt;&lt;a name="cpsautocompletionstring-widget"&gt;CPSAutoCompletionString widget&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;Back to CPS: I've created a new widget called CPSAutoCompletionString that is just
a simple String widget with an extra piece of javascript. It adds a class
initialization and roughly renders someting that looks like this:&lt;/p&gt;
&lt;pre class="literal-block"&gt;
&amp;lt;input type=&amp;quot;text&amp;quot; name=&amp;quot;field&amp;quot; id=&amp;quot;field&amp;quot; value=&amp;quot;cool value&amp;quot;/&amp;gt;

&amp;lt;div id=&amp;quot;field_choices&amp;quot;/&amp;gt;
&amp;lt;script type=&amp;quot;text/javascript&amp;quot; language=&amp;quot;javascript&amp;quot;&amp;gt;
    new Ajax.Autocompleter(&amp;quot;field&amp;quot;, &amp;quot;field_choices&amp;quot;, &amp;quot;server_method&amp;quot;, {});'&amp;gt;

&amp;lt;/script&amp;gt;
&lt;/pre&gt;
&lt;p&gt;The input will use the div, feeded with value asynchronously retrieved with the
&lt;cite&gt;server_method&lt;/cite&gt;. That's it. &lt;em&gt;cough&lt;/em&gt; &lt;em&gt;cough&lt;/em&gt;. (Some may argue it's even shorter
in Ruby on Rails, but it looks short enough to me ;) )&lt;/p&gt;
&lt;p&gt;Now the cool part: the server method has been kept totally out of the widget code
in order to let the developer code it as he wants. A Zope 3 view can be done,
or a raw Zope 2 skin as well.&lt;/p&gt;
&lt;p&gt;The server side has to send a &lt;cite&gt;&amp;lt;UL&amp;gt;&lt;/cite&gt; tag with all entries in it.&lt;/p&gt;

&lt;p&gt;Since this javascript code works with the raw &lt;cite&gt;responseText&lt;/cite&gt;, we don't need to
implement a special transport protocol (json, rpc, ..)&lt;/p&gt;
&lt;p&gt;The result is just used to fill the div.&lt;/p&gt;
&lt;p&gt;Example of Zope 2 skin:&lt;/p&gt;
&lt;pre class="literal-block"&gt;
##parameters=
# I wish I had Five installed so I would do a view here :')
return '&amp;lt;ul class=&amp;quot;cpsskinsMenu&amp;quot;&amp;gt;&amp;lt;li&amp;gt;one&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;two&amp;lt;/li&amp;gt;&amp;lt;li&amp;gt;three&amp;lt;/li&amp;gt;&amp;lt;/ul&amp;gt;'

&lt;/pre&gt;
&lt;p&gt;There's no filtering in this example, but it's really simple to send the current
input in order to filter entries, and I'm still working on it.&lt;/p&gt;
&lt;/div&gt;
&lt;div class="section" id="conclusion"&gt;
&lt;h1&gt;&lt;a name="conclusion"&gt;Conclusion&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;&lt;cite&gt;CPSAutoCompletionString&lt;/cite&gt; has been integrated for CPS 3.4.0 but won't be used
in any CPS forms yet, as this will be done later on. You can already use it
though, in your custom CPSSchemas layouts, or through CPSTypeMaker.&lt;/p&gt;
&lt;p&gt;CPS Developpers, if you give it a try, let me know !&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;</content>

  <id>tag:blogs.nuxeo.com:sections:blogs:tarek_ziade:2006_01_05_cps-ajaxification-round</id>
  <link rel="service.edit" type="application/atom+xml"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2006_01_05_cps-ajaxification-round/atom?2006_01_05_cps-ajaxification-round"
        title="Edit Here - CPS Ajaxification round #2" />
</entry>

  
  
      <entry xmlns="http://purl.org/atom/ns#"
       xmlns:dc="http://purl.org/dc/elements/1.1/">
     
  <title mode="escaped" type="text/html">CPS Ajaxification, round #1</title>
  <link rel="alternate" type="text/html"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2005_12_16_cps-ajaxification-round" />
  <issued>2006-02-27T08:14:11Z</issued>
  <modified>2006-02-27T08:14:11Z</modified>
  <created>2005-12-16T08:46:35Z</created>
  <draft xmlns="http://purl.org/atom-blog/ns#">false</draft>
  <author>
    <name>tziade</name>
  </author>
  
  
    <dc:subject>AJAX</dc:subject>
  
  
    <dc:subject>cps</dc:subject>
  
  
    <dc:subject>web</dc:subject>
  
  
    <dc:subject>zope</dc:subject>
  
  
    <dc:subject>zope3</dc:subject>
  
  
  <summary type="text/html" mode="escaped">
   
    In my 
    last blurg I said I would select some toolkit out there to compare the
    result, but after some mails exchanged on Z3 mailing list ( 
    Ajax in Zope 3 Thread), I agreed with what Benji York and Gary Poster said
    in this subject:

    
     "I'm very interested in coming up with a one or more relatively simple
     server-side proposals to make Ajax stuff ...</summary>

  <content type="text/html" mode="escaped"
           xml:space="preserve">&lt;div class="document"&gt;
   &lt;div class="section" id="cps-ajaxification-round-1"&gt;
    &lt;p&gt;In my &lt;a class="reference"
    href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2005_12_06_choosing-javascript"&gt;
    last blurg&lt;/a&gt; I said I would select some toolkit out there to compare the
    result, but after some mails exchanged on Z3 mailing list ( &lt;a
    class="reference"
    href="http://archives.free.net.ph/thread/20051208.161025.460ed1ed.en.html"&gt;
    Ajax in Zope 3 Thread&lt;/a&gt;), I agreed with what &lt;a class="reference"
    href="http://www.benjiyork.com/blog/"&gt;Benji York&lt;/a&gt; and Gary Poster said
    in this subject:&lt;/p&gt;

    &lt;blockquote&gt;
     "I'm very interested in coming up with a one or more relatively simple
     server-side proposals to make Ajax stuff easier, but I think the Ajax
     stuff (and even the whole JavaScript world) is too immature to settle on
     one client-side implementation. Therefore we should concentrate on doing
     things that help most or all of the JS toolkits be more usable with Z3."
    &lt;/blockquote&gt;

    &lt;p&gt;So I have started the work over CPS with Scriptaculous, focusing on
    uses cases and when doable, on the server-side infrastructure.&lt;/p&gt;
   &lt;/div&gt;

   &lt;div class="section"
   id="cps-use-case-1-cpsdocument-ajax-form-controller-with-graceful-degradation"&gt;
    &lt;h1&gt;&lt;a
    id="cps-use-case-1-cpsdocument-ajax-form-controller-with-graceful-degradation"
     name="cps-use-case-1-cpsdocument-ajax-form-controller-with-graceful-degradation"&gt;
    CPS Use case #1: CPSDocument AJAX form controller with graceful
    degradation&lt;/a&gt;&lt;/h1&gt;

    &lt;p&gt;The first use case in CPS is to embed existing forms used to change
    document fields. The Javascript needs to let the user validate a form,
    that is sent asynchronously through an XMLHttpRequest object, to get
    direct feedback.&lt;/p&gt;

    &lt;p&gt;The feedback is then used on client-side to either:&lt;/p&gt;

    &lt;ul class="simple"&gt;
     &lt;li&gt;Update the form on errors, to point out the fields that are not
     correct;&lt;/li&gt;

     &lt;li&gt;tell the user changes where made, optionnaly changes the page title
     when the user has change the title, and eventually redirect the
     user.&lt;/li&gt;
    &lt;/ul&gt;

    &lt;p&gt;Since this is an ajaxification of existing server side Z2
    infrastructure, it was very hard, even overkill to start doing server-side
    work, so for this use case I have just added a bit of code on server side
    to make it work, without trying to do a clean infrastructure.&lt;/p&gt;

    &lt;p&gt;The constraints are:&lt;/p&gt;

    &lt;ul class="simple"&gt;
     &lt;li&gt;Graceful degradation: if JavaScript is not available, the form has to
     work as usual&lt;/li&gt;

     &lt;li&gt;If the user &lt;a class="reference" href="#tries-to-send-a-file"&gt;tries
     to send a file&lt;/a&gt; in the form, the classic form will be used&lt;/li&gt;

     &lt;li&gt;Use Object Oriented approach (OO)&lt;/li&gt;

     &lt;li&gt;Use Test-driven development approach (TDD)&lt;/li&gt;
    &lt;/ul&gt;

    &lt;div class="section" id="graceful-degradation"&gt;
     &lt;h2&gt;&lt;a id="graceful-degradation" name="graceful-degradation"&gt;Graceful
     degradation&lt;/a&gt;&lt;/h2&gt;

     &lt;p&gt;This is one of the most interesting thing to work on: make the pages
     still work when Javascript is unavailable, so CPS stays compliant with
     all accessibility levels.&lt;/p&gt;

     &lt;p&gt;This is simply done by an unobtrusive way of doing thing: when
     initialized, the Javascript code hook itslef to the form, degrading its
     action and its submit buttons.&lt;/p&gt;
    &lt;/div&gt;

    &lt;div class="section" id="tdd-and-oo"&gt;
     &lt;h2&gt;&lt;a id="tdd-and-oo" name="tdd-and-oo"&gt;TDD and OO&lt;/a&gt;&lt;/h2&gt;

     &lt;p&gt;The OO approach is very easy under Scriptaculous, wich is built on the
     top of &lt;a class="reference"
     href="http://prototype.conio.net/"&gt;Prototype&lt;/a&gt;. So this is as easy as
     Mochikit, and I would say, as easy a coding some classes in Python !&lt;/p&gt;

     &lt;p&gt;The TDD approach is very simple too: Scriptaculous comes with a
     unittest framework that provides usual tools you would find under Python
     (assertXXX methods, test fixtures, etc.). Doing TDD in Javascript come in
     two parts: browser-side testing and server-side testing when AJAx is
     involved.&lt;/p&gt;

     &lt;div class="section" id="browser-side-testing"&gt;
      &lt;h3&gt;&lt;a id="browser-side-testing"
      name="browser-side-testing"&gt;browser-side testing&lt;/a&gt;&lt;/h3&gt;

      &lt;p&gt;browser-side testing is done by creating a simple HTML file that
      contains all use cases to be tested, wich is the HTML environnement
      where the JS has to evolve, and the test object itself with all tests.
      When the HTML file is called, all test are called and you can even
      display feedback with green divs and red divs a la selenium.&lt;/p&gt;

      &lt;p&gt;&lt;a class="reference"
      href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/jstdd/cpsdocumenteditor.html"&gt;
      Try CPSDocument Js Test&lt;/a&gt; here, it should fail on some testunder
      Firefox, maybe more on Safari, and even more under Konqueror :) (old
      version).&lt;/p&gt;
     &lt;/div&gt;

     &lt;div class="section" id="server-side-testing"&gt;
      &lt;h3&gt;&lt;a id="server-side-testing" name="server-side-testing"&gt;server-side
      testing&lt;/a&gt;&lt;/h3&gt;

      &lt;p&gt;I won't discuss this part in that blurg, but to cover the whole code,
      we need to validate the code that generates AJAX answers as well.&lt;/p&gt;
     &lt;/div&gt;
    &lt;/div&gt;
   &lt;/div&gt;

   &lt;div class="section" id="conclusion"&gt;
    &lt;h1&gt;&lt;a id="conclusion" name="conclusion"&gt;Conclusion&lt;/a&gt;&lt;/h1&gt;

    &lt;p&gt;CPS now has a nice AJAX form validation that will be available in the
    next releases, and wich is still beeing worked out in a &lt;a
    class="reference"
    href="http://svn.nuxeo.org/trac/pub/browser/CPSDocument/branches/tziade_direct_check/skins/cps_document_js/"&gt;
    branch&lt;/a&gt; at this time.&lt;/p&gt;

    &lt;p&gt;This was quite simple to do, thanks to the nice, smart js toolkit, and
    thanks to the scriptaculous community out there, that helped me out on
    some small problems&lt;/p&gt;

    &lt;p&gt;I didn't talk about two things yet:&lt;/p&gt;

    &lt;ul class="simple"&gt;
     &lt;li&gt;Server-side infrastructure&lt;/li&gt;

     &lt;li&gt;Test automation&lt;/li&gt;
    &lt;/ul&gt;

    &lt;div class="section" id="server-side-infrastructure"&gt;
     &lt;h2&gt;&lt;a id="server-side-infrastructure"
     name="server-side-infrastructure"&gt;Server-side infrastructure&lt;/a&gt;&lt;/h2&gt;

     &lt;p&gt;The next use case fits better for presenting how AJAX helpers can be
     done on Zope side: drag'n'drop in folderish objects.&lt;/p&gt;
    &lt;/div&gt;

    &lt;div class="section" id="test-automation"&gt;
     &lt;h2&gt;&lt;a id="test-automation" name="test-automation"&gt;Test
     automation&lt;/a&gt;&lt;/h2&gt;

     &lt;p&gt;In my next blurg I will explain how to automate this tests and add
     them in a Zope environment, to be able to call them in a Python test
     suite, try out several browser types, and get feedback about it.&lt;/p&gt;

     &lt;p&gt;-- footnotes&lt;/p&gt;

     &lt;p&gt;&lt;a class="target" id="tries-to-send-a-file"
     name="tries-to-send-a-file"&gt;tries to send a file&lt;/a&gt;: You cannot send
     file with Javascript (security hole) unless you use some iframe
     artifact.&lt;/p&gt;
     &lt;a class="target" id="branch" name="branch"&gt;&lt;/a&gt;
    &lt;/div&gt;
   &lt;/div&gt;
  &lt;/div&gt;</content>

  <id>tag:blogs.nuxeo.com:sections:blogs:tarek_ziade:2005_12_16_cps-ajaxification-round</id>
  <link rel="service.edit" type="application/atom+xml"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2005_12_16_cps-ajaxification-round/atom?2005_12_16_cps-ajaxification-round"
        title="Edit Here - CPS Ajaxification, round #1" />
</entry>

  
  
      <entry xmlns="http://purl.org/atom/ns#"
       xmlns:dc="http://purl.org/dc/elements/1.1/">
     
  <title mode="escaped" type="text/html">Choosing a Javascript library for Zope</title>
  <link rel="alternate" type="text/html"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2005_12_06_choosing-javascript" />
  <issued>2006-02-27T08:23:06Z</issued>
  <modified>2006-02-27T08:23:06Z</modified>
  <created>2005-12-06T10:03:44Z</created>
  <draft xmlns="http://purl.org/atom-blog/ns#">false</draft>
  <author>
    <name>tziade</name>
  </author>
  
  
    <dc:subject>cps</dc:subject>
  
  
    <dc:subject>rich_client</dc:subject>
  
  
    <dc:subject>web</dc:subject>
  
  
    <dc:subject>zope</dc:subject>
  
  
    <dc:subject>zope3</dc:subject>
  
  
  <summary type="text/html" mode="escaped">
Choosing a Javascript library for Zope

Background

What's AJAX ?
(If you know it, you should skip this section)
Wikipedia says:

Asynchronous JavaScript and XML, or Ajax, is a web development technique for
creating interactive web applications using a combination of:

  - XHTML (or HTML) and CSS for marking up and styling information
  - The Document Object Model manipulated ...</summary>

  <content type="text/html" mode="escaped"
           xml:space="preserve">&lt;div class="document" id="choosing-a-javascript-library-for-zope"&gt;
&lt;h1 class="title"&gt;Choosing a Javascript library for Zope&lt;/h1&gt;
&lt;div class="section" id="background"&gt;
&lt;h1&gt;&lt;a name="background"&gt;Background&lt;/a&gt;&lt;/h1&gt;
&lt;div class="section" id="what-s-ajax"&gt;
&lt;h2&gt;&lt;a name="what-s-ajax"&gt;What's AJAX ?&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;(If you know it, you should skip this section)&lt;/p&gt;
&lt;p&gt;Wikipedia says:&lt;/p&gt;
&lt;pre class="literal-block"&gt;
Asynchronous JavaScript and XML, or Ajax, is a web development technique for
creating interactive web applications using a combination of:

  - XHTML (or HTML) and CSS for marking up and styling information
  - The Document Object Model manipulated through JavaScript to dynamically
    display and interact with the information presented
  - The XMLHttpRequest object to exchange data asynchronously with the web
    server. (XML is commonly used, although any format will work, including
    preformatted HTML, plain text, JSON and even EBML)

Like DHTML, LAMP, or SPA, Ajax is not a technology in itself, but a term
that refers to the use of a group of technologies together. In fact,
derivative/composite technologies based substantially upon Ajax, such as
AFLAX, are already appearing.
&lt;/pre&gt;
&lt;p&gt;(full definition here: &lt;a class="reference" href="http://en.wikipedia.org/wiki/AJAX"&gt;What's AJAX ?&lt;/a&gt;)&lt;/p&gt;
&lt;p&gt;In other words, AJAX allows a developer to make calls to the server from the
loaded page with Javascript, and change the page based on the server's
answer without having to do a complete page reload.&lt;/p&gt;
&lt;p&gt;Since the publishing machinery is not involved, a asynchronous round-trip is
&lt;em&gt;very fast&lt;/em&gt; and allow big ergonomics improvments. This is due to the fact that
asyncrhonous calls are made over server methods that just quickly renders
the needed datas, in opposition to a regular call that calculates and renders
a full page.&lt;/p&gt;
&lt;/div&gt;
&lt;div class="section" id="why-should-we-care-of-ajax-in-zope-applications"&gt;
&lt;h2&gt;&lt;a name="why-should-we-care-of-ajax-in-zope-applications"&gt;Why should we care of AJAX in Zope applications ?&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;AJAX isn't just the latest buzz word out there you can show up in your
applications (the come-here-we-have-some effect), AJAX is not this latest and
coolest technological thing all hype developers should know about.&lt;/p&gt;
&lt;p&gt;AJAX is not the web UI silver bullet either.&lt;/p&gt;
&lt;p&gt;AJAX is just a tool that let you focus on something that often get lost,
when creating a web applications: &lt;em&gt;people&lt;/em&gt;.&lt;/p&gt;
&lt;p&gt;I believe this is the main reason of AJAX success: developers are
able to greatly enhance their users experience with a few drops of
Javascript.&lt;/p&gt;
&lt;p&gt;Examples of use cases:&lt;/p&gt;
&lt;ul class="simple"&gt;
&lt;li&gt;A select box value is changed, the values of a second one are reloaded.&lt;/li&gt;
&lt;li&gt;Direct edition of page parts (see CPSWiki for instance)&lt;/li&gt;
&lt;li&gt;Content panel that changes on user actions&lt;/li&gt;
&lt;li&gt;Forms are checked before actually sent (see CPSMailAccess email editor)&lt;/li&gt;
&lt;li&gt;etc..&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;People can argue there are a lot of caveats on this (for example, using the
'back' button of the navigator can brake it) but it improves so much the
flexibility of a web application and make web app as reactive as desktop
apps.&lt;/p&gt;
&lt;p&gt;A recent &lt;a class="reference" href="http://www.surveymonkey.com/DisplaySummary.asp?SID=1427046&amp;amp;U=142704624114"&gt;Ajax Survey&lt;/a&gt; shows us that AJAX is used in real applications
everywhere. Even if the amount of developers that have answered this survey is
not big, it also brings a good idea on what tools are actually used to do
AJAX.&lt;/p&gt;
&lt;p&gt;Zope is not apart from the main web developpers stream, and can use any
AJAX library out there. AJAX libraries have different approaches, explained in
the next section.&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;div class="section" id="different-libraries-approaches"&gt;
&lt;h1&gt;&lt;a name="different-libraries-approaches"&gt;Different libraries approaches&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;There are several kind of libraries available to work with AJAX:&lt;/p&gt;
&lt;ul class="simple"&gt;
&lt;li&gt;Low-level client-side frameworks (LLF)&lt;/li&gt;
&lt;li&gt;Client-side Application frameworks (CSF)&lt;/li&gt;
&lt;li&gt;Server-side Javascript generation frameworks (SSF)&lt;/li&gt;
&lt;li&gt;XForm approach framework (XFF)&lt;/li&gt;
&lt;li&gt;Other frameworks&lt;/li&gt;
&lt;/ul&gt;
&lt;div class="section" id="low-level-client-side-frameworks"&gt;
&lt;h2&gt;&lt;a name="low-level-client-side-frameworks"&gt;Low-level client-side frameworks&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Low-level Javascript libraries provide a simple piping to access the server by
wrapping XMLHTTPRequest objects and let the developper perfom DOM manipulation
with the server's answer.&lt;/p&gt;
&lt;p&gt;Most of these libraries are a thin layer that provides a portable API for these
actions, and other utilies like:&lt;/p&gt;
&lt;ul class="simple"&gt;
&lt;li&gt;XPath query APIs&lt;/li&gt;
&lt;li&gt;XSLT APIs&lt;/li&gt;
&lt;li&gt;etc.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Example of such libraries are: &lt;a class="reference" href="http://sarissa.sf.net/"&gt;Sarissa&lt;/a&gt;, &lt;a class="reference" href="http://xkr.us/code/javascript/XHConn/"&gt;XHConn&lt;/a&gt;, &lt;a class="reference" href="http://www.whitefrost.com/reference/2005/09/09/libXmlRequest.html"&gt;LibXMLHttpRequest&lt;/a&gt;
(non GPL), etc.&lt;/p&gt;
&lt;p&gt;Here's a small example of a simple AJAX call in Sarissa:&lt;/p&gt;
&lt;pre class="literal-block"&gt;
Sarissa.updateContentFromURI = function(sFromUrl, oTargetElement, xsltproc) {
    try{
        oTargetElement.style.cursor = &amp;quot;wait&amp;quot;;
        var xmlhttp = new XMLHttpRequest();
        xmlhttp.open(&amp;quot;GET&amp;quot;, sFromUrl);
        function sarissa_dhtml_loadHandler() {
            if (xmlhttp.readyState == 4) {
                oTargetElement.style.cursor = &amp;quot;auto&amp;quot;;
                Sarissa.updateContentFromNode(xmlhttp.responseXML, oTargetElement, xsltproc);
            };
        };
        xmlhttp.onreadystatechange = sarissa_dhtml_loadHandler;
        xmlhttp.send(null);
        oTargetElement.style.cursor = &amp;quot;auto&amp;quot;;
    }
    catch(e){
        oTargetElement.style.cursor = &amp;quot;auto&amp;quot;;
        throw e;
    };
};
&lt;/pre&gt;
&lt;p&gt;Sarissa takes care of all portability aspects to allow this code to work under
most navigators that implements Javascript. These simple libraries provide a
quick and simple way to use asynchronous calls on a web view.&lt;/p&gt;
&lt;p&gt;Google has also released its XSLT/XPath JavaScript engine as an open source project:
&lt;a class="reference" href="http://goog-ajaxslt.sourceforge.net/"&gt;AJAXSLT&lt;/a&gt;&lt;/p&gt;
&lt;/div&gt;
&lt;div class="section" id="client-side-application-frameworks"&gt;
&lt;h2&gt;&lt;a name="client-side-application-frameworks"&gt;Client-side application frameworks&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Most of the time, client-side application frameworks provide the same features
than Low-level client-side frameworks, but also brings a higher level,
component-oriented, set of APIs.&lt;/p&gt;
&lt;p&gt;These APIs let the developer work on client-side like he or she would do in a
desktop app with a classical GUI toolkit. The style and the amount of
javascript code produced are very dependent on the library, and the developer
is quite driven by the toolkit.&lt;/p&gt;
&lt;p&gt;For example, toolkits like &lt;a class="reference" href="http://prototype.conio.net/"&gt;Prototype&lt;/a&gt; provides a object-oriented way to work
in Javascript, and therefore changes a lot how Javascript is used in a web
application and its importance in the architecture.&lt;/p&gt;
&lt;p&gt;This example show how to create a class hierarchy with Prototype:&lt;/p&gt;
&lt;pre class="literal-block"&gt;
function Manager () {
    this.reports = [];
}
Manager.prototype = new Employee;

function WorkerBee () {
    this.projects = [];
}
WorkerBee.prototype = new Employee;

function SalesPerson () {
  this.dept = &amp;quot;sales&amp;quot;;
  this.quota = 100;
}
SalesPerson.prototype = new WorkerBee;

etc...
&lt;/pre&gt;
&lt;p&gt;Some toolkits also provide very high level functionnalities that let the
developper implement common AJAX use cases in a few lines. &lt;a class="reference" href="http://openrico.org/rico/demos.page"&gt;OpenRico&lt;/a&gt;, which
is built on the top of Prototype, is one of those.&lt;/p&gt;
&lt;p&gt;For example, adding a nice fade effect in OpenRico is done with a single
command:&lt;/p&gt;
&lt;pre class="literal-block"&gt;
new Effect.FadeTo('fadeMe',
                  .2, // 20% opacity
                  500, // 500ms (1/2 second)
                  10, // 10 steps
                  {complete:function() {setStatus('done fading element.',
                   1500);}} );
&lt;/pre&gt;
&lt;p&gt;Complex use cases, like live grids, can be provided as well. See &lt;a class="reference" href="http://openrico.org/rico/livegrid.page"&gt;OpenRico
live grid demo&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Client-side application frameworks also provide other developper tools like:&lt;/p&gt;
&lt;ul class="simple"&gt;
&lt;li&gt;Unit-testing framework integration, like &lt;a class="reference" href="http://kupu.oscom.org/download/ecmaunit-0.2.html"&gt;ECMAUnit&lt;/a&gt; or &lt;a class="reference" href="http://www.openjsan.org/doc/t/th/theory/Test/Simple/0.21/"&gt;Test.Simple&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;Debuggers&lt;/li&gt;
&lt;li&gt;Different protocol for client-server dialogs (XML, &lt;a class="reference" href="http://www.crockford.com/JSON/index.html"&gt;JSON&lt;/a&gt;)&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;The learning curve involved by these frameworks worth it, as they bring to
Javascript what we have in Python.&lt;/p&gt;
&lt;ul class="simple"&gt;
&lt;li&gt;Javascript? huh! I don't want to use it&lt;/li&gt;
&lt;li&gt;What if you can actually use object oriented programming in it ?&lt;/li&gt;
&lt;li&gt;I always get thousands of errors in a few lines of Javascript&lt;/li&gt;
&lt;li&gt;What if you can debug it ?&lt;/li&gt;
&lt;li&gt;Is there any pop corn left ?&lt;/li&gt;
&lt;/ul&gt;
&lt;/div&gt;
&lt;div class="section" id="server-side-javascript-generation-frameworks"&gt;
&lt;h2&gt;&lt;a name="server-side-javascript-generation-frameworks"&gt;Server-side Javascript generation frameworks&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;Server-side Javascript generation is generally based on the
&lt;cite&gt;no-javascript-skills-needed paradigm&lt;/cite&gt;: the developper creates code on server
side, using the server's language using specific APIs, or a specific model.
The framework then automatically generates the right HTML and Javascript
elements and sends them to the client. Sometime this generation is made
on client sied with a javascript engine.&lt;/p&gt;
&lt;p&gt;CrackAjax is one of those for Python, and let the developper create
&lt;cite&gt;AJAX views&lt;/cite&gt;:&lt;/p&gt;
&lt;pre class="literal-block"&gt;
import crackajax
import cherrypy
import ituneslib

class iTunesAjaxPage(crackajax.AjaxPage):

    &amp;#64;crackajax.clientside
    def do_search():
        update_list(search_songs(document.getElementById(&amp;quot;searchbox&amp;quot;).value))

    &amp;#64;crackajax.serverside
    def get_all_songs(self):
        return [self.SONGS]

    &amp;#64;crackajax.serverside
    def search_songs(self, query):
        query = query.lower()
        return [filter(lambda s: self.does_song_match(query, s),
                self.SONGS)]

crackajax.init(&amp;quot;jsolait&amp;quot;)
cherrypy.root = iTunesAjaxPage(ituneslib.Library(&amp;quot;Library.xml&amp;quot;), &amp;quot;&amp;quot;)
cherrypy.server.start()
&lt;/pre&gt;
&lt;p&gt;The &lt;cite&gt;serverside&lt;/cite&gt; decorator tags the methods to become an XML-RPC call, and the
&lt;cite&gt;clientside&lt;/cite&gt; automatically convert Python code into client-side javascript,
using &lt;cite&gt;Python-to-JScript .NET compiler&lt;/cite&gt;.&lt;/p&gt;
&lt;p&gt;There are also less radical approaches, where the framework provides APIs to
describe the javascript that needs to be created, using for example a
descriptive langage that covers explicit behaviors. (see &lt;a class="reference" href="http://bubblenet.be/home/community-work/kukit-azax-details/"&gt;Azax&lt;/a&gt; approach).&lt;/p&gt;
&lt;/div&gt;
&lt;div class="section" id="xform-approach-frameworks"&gt;
&lt;h2&gt;&lt;a name="xform-approach-frameworks"&gt;XForm approach frameworks&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;&lt;em&gt;Section to be completed&lt;/em&gt; (see &lt;a class="reference" href="http://www.formfaces.com/main.html"&gt;FormFaces&lt;/a&gt;)&lt;/p&gt;
&lt;/div&gt;
&lt;div class="section" id="other-frameworks"&gt;
&lt;h2&gt;&lt;a name="other-frameworks"&gt;Other frameworks&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;They are many other hybrid approaches that mixes server-side and client-side,
or approaches that provides even lower-level mecanisms.&lt;/p&gt;
&lt;p&gt;They are not detailed here because they are often tighted to a particular web
framework or don't bring more features that what we would have in other types.&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;div class="section" id="choosing-a-library"&gt;
&lt;h1&gt;&lt;a name="choosing-a-library"&gt;Choosing a library&lt;/a&gt;&lt;/h1&gt;
&lt;p&gt;For CPS , and moreover for Zope-based applications, an AJAX library has to be
taken in CSF category or SSF, since all functionalities available in LLF
exists in CSF. The next sections provide a very quick review on existing
libraries.&lt;/p&gt;
&lt;div class="section" id="ssf-libraries"&gt;
&lt;h2&gt;&lt;a name="ssf-libraries"&gt;SSF Libraries&lt;/a&gt;&lt;/h2&gt;
&lt;div class="section" id="crackajax"&gt;
&lt;h3&gt;&lt;a name="crackajax"&gt;CrackAjax&lt;/a&gt;&lt;/h3&gt;
&lt;dl class="docutils"&gt;
&lt;dt&gt;Pros:&lt;/dt&gt;
&lt;dd&gt;&lt;ul class="first last simple"&gt;
&lt;li&gt;straight-forward: a server side approach, like CrackAjax or Azax,
provides a straight-forward tool to add Ajax features in a web application,
by hiding the Javascript layers from the developer with techniques
that can be compared to &lt;a class="reference" href="http://c2.com/cgi/wiki?TemplateMetaprogramming"&gt;Template MetaProgramming&lt;/a&gt;, and providing a
meta langage or a set of APIs in the web application native language.&lt;/li&gt;
&lt;/ul&gt;
&lt;/dd&gt;
&lt;dt&gt;Cons:&lt;/dt&gt;
&lt;dd&gt;&lt;ul class="first last simple"&gt;
&lt;li&gt;not so hidden: as you can see in this &lt;a class="reference" href="http://svn.subway.python-hosting.com/crackajax/trunk/itunes.py"&gt;CrackAjax example&lt;/a&gt;, the code
written in Python is very similar to what you would have done in Javascript.
Furthermore, it's a bit of magic since the given Python code cannot
be unit tested howsoever (the 'document' variable does not exists on Python
side)&lt;/li&gt;
&lt;/ul&gt;
&lt;/dd&gt;
&lt;/dl&gt;
&lt;/div&gt;
&lt;div class="section" id="azax"&gt;
&lt;h3&gt;&lt;a name="azax"&gt;Azax&lt;/a&gt;&lt;/h3&gt;
&lt;dl class="docutils"&gt;
&lt;dt&gt;Pros:&lt;/dt&gt;
&lt;dd&gt;&lt;ul class="first last simple"&gt;
&lt;li&gt;clean architecture: Sometime the SSF approach is also meant to
drive the developper to cleary separate the Controller and the Interface.
For example Azax xml templates provides a way to separate the behavior of
a page and the UI, example of separation: &lt;a class="reference" href="http://svn.z3lab.org/trac/z3lab/file/azax/trunk/demos/azaxdemo/browser/azax_tree.azax"&gt;Azax page behavior&lt;/a&gt; / &lt;a class="reference" href="http://svn.z3lab.org/trac/z3lab/file/azax/trunk/demos/azaxdemo/browser/azax_tree.pt"&gt;Azax page template&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;includes a link to mochikit, allowing hybrid behaviors&lt;/li&gt;
&lt;/ul&gt;
&lt;/dd&gt;
&lt;/dl&gt;
&lt;p&gt;Cons:&lt;/p&gt;
&lt;ul class="simple"&gt;
&lt;li&gt;one more layer: This clean separation can be done straight
forward in Javascript, without adding a layer, but describing behaviors
in XML can also be seen as more portable and readable, because the
code could work without Javascript, wich is just the last layer
This approach is very similar to what XUL has in &lt;a class="reference" href="http://www.xulplanet.com/tutorials/xultu/xblevents.html"&gt;XBL Events&lt;/a&gt;,
but this is a bit of Not Invented Here.&lt;/li&gt;
&lt;/ul&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;div class="section" id="csf-libraries"&gt;
&lt;h2&gt;&lt;a name="csf-libraries"&gt;CSF Libraries&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;A quite complete &lt;a class="reference" href="http://wiki.osafoundation.org/bin/view/Projects/AjaxLibraries"&gt;survey at OSA foundation&lt;/a&gt; is available and EDevil's blog
has a &lt;a class="reference" href="http://edevil.wordpress.com/2005/11/14/javascript-libraries-roundup/"&gt;nice library&lt;/a&gt; list.&lt;/p&gt;
&lt;/div&gt;
&lt;div class="section" id="a-library-for-cps"&gt;
&lt;h2&gt;&lt;a name="a-library-for-cps"&gt;A library for CPS&lt;/a&gt;&lt;/h2&gt;
&lt;p&gt;In the next blurg, I will try to see wich library fits the best for CPS by:&lt;/p&gt;
&lt;ul class="simple"&gt;
&lt;li&gt;Suming up the use cases that already need to be covered, in both Zope 2 and Zope 3.&lt;/li&gt;
&lt;li&gt;Selecting the 10 best libs out there&lt;/li&gt;
&lt;li&gt;Trying out all use cases with each toolkit to compare.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;And please don't hesitate to react on this blurg, if you want to give more
precisions or corrections on some toolkits, or if you have opinions, comments.
These will be integrated on the page.&lt;/p&gt;
&lt;p&gt;Thanks to &lt;a class="reference" href="http://radio.weblogs.com/0116506/"&gt;Paul Everitt&lt;/a&gt;, for for pointing out some mistakes on this entry,
and for pointing out the XForm approach, that will be completed soon.&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/div&gt;</content>

  <id>tag:blogs.nuxeo.com:sections:blogs:tarek_ziade:2005_12_06_choosing-javascript</id>
  <link rel="service.edit" type="application/atom+xml"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2005_12_06_choosing-javascript/atom?2005_12_06_choosing-javascript"
        title="Edit Here - Choosing a Javascript library for Zope" />
</entry>

  
  
      <entry xmlns="http://purl.org/atom/ns#"
       xmlns:dc="http://purl.org/dc/elements/1.1/">
     
  <title mode="escaped" type="text/html">CPSMailAccess 1.2.0 released</title>
  <link rel="alternate" type="text/html"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2005_11_28_cpsmailaccess-1-2-0" />
  <issued>2005-11-28T12:53:42Z</issued>
  <modified>2005-11-28T12:53:42Z</modified>
  <created>2005-11-28T12:45:35Z</created>
  <draft xmlns="http://purl.org/atom-blog/ns#">false</draft>
  <author>
    <name>tziade</name>
  </author>
  
  
    <dc:subject>cps</dc:subject>
  
  
    <dc:subject>python</dc:subject>
  
  
    <dc:subject>semantic_web</dc:subject>
  
  
    <dc:subject>zope</dc:subject>
  
  
  <summary type="text/html" mode="escaped">I have released CPSMailAccess 1.2.0 today. It includes bugfixes, engine and
  UI enhancements.
   
   The next steps will become very interesting because it will provide some
  features we wanted to have since we started the project:
   
   

  
   Virtual folders classification

   Thread manipulations
   

   ...
   
  
  
   Also, a major upcoming change will be on ajax side, ...</summary>

  <content type="text/html" mode="escaped"
           xml:space="preserve">I have released CPSMailAccess 1.2.0 today. It includes bugfixes, engine and
  UI enhancements.&lt;br /&gt;
   &lt;br /&gt;
   The next steps will become very interesting because it will provide some
  features we wanted to have since we started the project:&lt;br /&gt;
   &lt;br /&gt;
   

  &lt;ul&gt;
   &lt;li&gt;Virtual folders classification&lt;/li&gt;

   &lt;li&gt;Thread manipulations&lt;br /&gt;
   &lt;/li&gt;

   &lt;li&gt;...&lt;br /&gt;
   &lt;/li&gt;
  &lt;/ul&gt;
  &lt;br /&gt;
   Also, a major upcoming change will be on ajax side, as I'll refactor the
  javascript code to make it rely on a third party js library. This will also
  be helpfull to start unit testing this part of the app.&lt;br /&gt;
  &lt;br /&gt;
  Last, I'll probably add a import feature from other mail clients, in order
  to grab configured filters. I've been told this was the last thing that was
  missing to adopt CPSMailAccess over that exotic and unfamous mail client
  called Thunderbird ;)&lt;br /&gt;
   &lt;br /&gt;
   here's the annoucement: &lt;a
  href="http://www.cps-project.org/sections/news/cpsmailaccess-1-2-0"&gt;http://www.cps-project.org/sections/news/cpsmailaccess-1-2-0&lt;/a&gt;&lt;br /&gt;

   &lt;br /&gt;
   &lt;a href="http://lists.nuxeo.com/mailman/listinfo/cps-devel"&gt;&lt;/a&gt;</content>

  <id>tag:blogs.nuxeo.com:sections:blogs:tarek_ziade:2005_11_28_cpsmailaccess-1-2-0</id>
  <link rel="service.edit" type="application/atom+xml"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2005_11_28_cpsmailaccess-1-2-0/atom?2005_11_28_cpsmailaccess-1-2-0"
        title="Edit Here - CPSMailAccess 1.2.0 released" />
</entry>

  
  
      <entry xmlns="http://purl.org/atom/ns#"
       xmlns:dc="http://purl.org/dc/elements/1.1/">
     
  <title mode="escaped" type="text/html">XML-RPC over Zope 3, a quick tutorial</title>
  <link rel="alternate" type="text/html"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2005_11_04_xml-rpc-over-zope-3" />
  <issued>2005-11-05T01:39:49Z</issued>
  <modified>2005-11-05T01:39:49Z</modified>
  <created>2005-11-04T20:56:18Z</created>
  <draft xmlns="http://purl.org/atom-blog/ns#">false</draft>
  <author>
    <name>tziade</name>
  </author>
  
  
    <dc:subject>zope</dc:subject>
  
  
    <dc:subject>zope3</dc:subject>
  
  
  <summary type="text/html" mode="escaped">
  Please read this blog entry from here 

  
   What 's XML-RPC ?

   XML-RPC is a very simple Remote Procedure Control encoded in xml that
   can be used to interact with an application server from another program
   (another server, a rich client, or some Ajax'ed web Page)

   More infos at wikipedia
  

  
   XML-RPC in Zope
   3

   Zope 3 comes with a very handy approach to ...</summary>

  <content type="text/html" mode="escaped"
           xml:space="preserve">
  Please read this blog entry from &lt;a
  href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/"&gt;here&lt;/a&gt; 

  &lt;div class="section" id="what-s-xml-rpc"&gt;
   &lt;h3&gt;&lt;a id="what-s-xml-rpc" name="what-s-xml-rpc"&gt;What 's XML-RPC ?&lt;/a&gt;&lt;/h3&gt;

   &lt;p&gt;XML-RPC is a very simple Remote Procedure Control encoded in xml that
   can be used to interact with an application server from another program
   (another server, a rich client, or some Ajax'ed web Page)&lt;/p&gt;

   &lt;p&gt;More infos at &lt;a class="reference"
   href="http://en.wikipedia.org/wiki/Xmlrpc"&gt;wikipedia&lt;/a&gt;&lt;/p&gt;
  &lt;/div&gt;

  &lt;div class="section" id="xml-rpc-in-zope-3"&gt;
   &lt;h3&gt;&lt;a id="xml-rpc-in-zope-3" name="xml-rpc-in-zope-3"&gt;XML-RPC in Zope
   3&lt;/a&gt;&lt;/h3&gt;

   &lt;p&gt;Zope 3 comes with a very handy approach to provide XML-RPC features. You
   just have to write a view class that provides methods that will be
   available as RPC methods.&lt;/p&gt;

   &lt;p&gt;If you are coming for Zope 2 world, please read up &lt;a class="reference"
   href="http://worldcookery.com/files/ploneconf05-five/step3.html"&gt;philliKon's
   slides&lt;/a&gt; at worldcookery (other Z3 goodies can be found there).&lt;/p&gt;

   &lt;div class="section" id="my-first-xmlrpc-package"&gt;
    &lt;h4&gt;&lt;a id="my-first-xmlrpc-package" name="my-first-xmlrpc-package"&gt;My
    First XMLRPC Package&lt;/a&gt;&lt;/h4&gt;

    &lt;p&gt;Let's write a small Zope 3 package to provide an XML-RPC method over
    all server folders, that provides a folder listing.&lt;/p&gt;

    &lt;p&gt;This product is a folder composed of two files:&lt;/p&gt;

    &lt;ul class="simple"&gt;
     &lt;li&gt;&lt;cite&gt;xmlprctest.py&lt;/cite&gt;: contains the xmlrpc view class that
     implements the method.&lt;/li&gt;

     &lt;li&gt;&lt;cite&gt;configure.zcml&lt;/cite&gt;: contains the configuration that will be
     read by Zope when it starts.&lt;/li&gt;

     &lt;li&gt;&lt;cite&gt;__init__.py&lt;/cite&gt;: an empty file that makes the folder beeing
     a Package.&lt;/li&gt;
    &lt;/ul&gt;

    &lt;div class="section" id="folderlisting-view-class-in-xmlrpctest-py"&gt;
     &lt;h5&gt;&lt;a id="folderlisting-view-class-in-xmlrpctest-py"
     name="folderlisting-view-class-in-xmlrpctest-py"&gt;FolderListing View class
     in xmlrpctest.py&lt;span style="font-style: italic;"&gt;&amp;nbsp;&lt;/span&gt;&lt;/a&gt;&lt;/h5&gt;

     &lt;p&gt;Writing a XML-RPC view is extremely simple&lt;/p&gt;
&lt;pre class="literal-block"&gt;
from zope.app.publisher.xmlrpc import XMLRPCView

class FolderListing(XMLRPCView):
    def contents(self):
        """ returns the folder content """
        return list(self.context.keys())
&lt;/pre&gt;

     &lt;p&gt;The &lt;cite&gt;contents()&lt;/cite&gt; method just returns the context
     elements.&lt;/p&gt;

     &lt;div class="section" id="introspection"&gt;
      &lt;h6&gt;&lt;a id="introspection" name="introspection"&gt;Introspection&lt;/a&gt;&lt;/h6&gt;

      &lt;p&gt;Zope 3 will also automatically provide three extra methods for
      XML-RPC Introspection, that helps on API discovering from the
      client:&lt;/p&gt;

      &lt;ul class="simple"&gt;
       &lt;li&gt;&lt;cite&gt;listMethods()&lt;/cite&gt;: Lists all xmlrpc methods (ie views)
       registered for the current object&lt;/li&gt;

       &lt;li&gt;&lt;cite&gt;methodHelp(method_name)&lt;/cite&gt;: Returns the method
       documentation of the given method.&lt;/li&gt;

       &lt;li&gt;&lt;cite&gt;methodSignature(method_name)&lt;/cite&gt;: Returns the method
       documentation of the given method.&lt;/li&gt;
      &lt;/ul&gt;

      &lt;p&gt;Get more info about introspection here: &lt;a class="reference"
      href="http://xmlrpc-c.sourceforge.net/xmlrpc-howto/xmlrpc-howto-api-introspection.html"&gt;
      introspection&lt;/a&gt;.&lt;/p&gt;

      &lt;p&gt;Since Python does not provide static typing,
      &lt;cite&gt;methodSignature&lt;/cite&gt; needs a bit of help to return the signature
      of the method.&lt;/p&gt;

      &lt;p&gt;A method decorator called &lt;cite&gt;xmlrpccallable&lt;/cite&gt; is provided and
      can be used on the View:&lt;/p&gt;
&lt;pre class="literal-block"&gt;
from zope.app.publisher.xmlrpc import XMLRPCView
from zope.app.xmlrpcintrospection.xmlrpcintrospection import xmlrpccallable

class FolderListing(XMLRPCView):

    @xmlrpccallable(str)
    def contents(self):
        """ returns the folder content """
        return list(self.context.keys())
&lt;/pre&gt;

      &lt;p&gt;The first decorator parameter is the return type, and the next
      parameters are the arguments type, if needeed.&lt;/p&gt;
     &lt;/div&gt;
    &lt;/div&gt;

    &lt;div class="section" id="linking-the-view-in-configure-zcml"&gt;
     &lt;h5&gt;&lt;a id="linking-the-view-in-configure-zcml"
     name="linking-the-view-in-configure-zcml"&gt;Linking the view in
     configure.zcml&lt;/a&gt;&lt;/h5&gt;

     &lt;p&gt;In the configuration file, we will tell Zope 3 that
     &lt;cite&gt;FolderListing()&lt;/cite&gt; has to be instanciated and used everytime a
     XML-RPC call is made on a zope folder:&lt;/p&gt;

     &lt;div class="system-message"&gt;
&lt;pre&gt;
&amp;lt;configure xmlns="http://namespaces.zope.org/zope"
        xmlns:xmlrpc="http://namespaces.zope.org/xmlrpc"&amp;gt;
&amp;lt;xmlrpc:view
    for="zope.app.folder.folder.IFolder"
    methods="contents"
    class="xmlrpctest.xmlrpctest.FolderListing"
    permission="zope.ManageContent"/&amp;gt;
&amp;lt;/configure&amp;gt;
&lt;/pre&gt;
     &lt;/div&gt;

     &lt;p&gt;The &lt;cite&gt;xmlrpc:view&lt;/cite&gt; directive, provided by
     &lt;cite&gt;zope.app.publisher.xmlrpc&lt;/cite&gt; hooks everything up.&lt;/p&gt;
    &lt;/div&gt;

    &lt;div class="section" id="setting-up-the-package"&gt;
     &lt;h5&gt;&lt;a id="setting-up-the-package" name="setting-up-the-package"&gt;Setting
     up the package&lt;/a&gt;&lt;/h5&gt;

     &lt;p&gt;The three files are saved into a folder called &lt;cite&gt;xlmrpctest&lt;/cite&gt;
     into &lt;cite&gt;{$INSTANCE}/lib/python&lt;/cite&gt;.&lt;/p&gt;

     &lt;p&gt;Last but not least, a zcml file, called
     &lt;cite&gt;xmlrpctest-configure.zcml&lt;/cite&gt;,has to be added in
     &lt;cite&gt;{$INSTANCE}/etc/package-includes/&lt;/cite&gt; to let zope 3 know about
     the package.&lt;/p&gt;

     &lt;p&gt;xmlrpctest-configure.zcml:&lt;br /&gt;
     &lt;/p&gt;
&lt;pre&gt;
&amp;lt;include package="xmlrpctest" /&amp;gt;
&lt;/pre&gt;
     That's all, Zope can be restarted !&lt;br /&gt;
     &lt;br /&gt;
    &lt;/div&gt;
   &lt;/div&gt;
  &lt;/div&gt;

  &lt;div class="section" id="trying-out-the-xml-rpc-method"&gt;
   &lt;h3&gt;&lt;a id="trying-out-the-xml-rpc-method"
   name="trying-out-the-xml-rpc-method"&gt;Trying out the XML-RPC method&lt;/a&gt;&lt;/h3&gt;

   &lt;p&gt;Let's try out our product, with a few lines of python, using
   &lt;cite&gt;xmlrpclib&lt;/cite&gt;:&lt;/p&gt;
&lt;pre class="literal-block"&gt;
from XMLRPCAuth import BasicAuthTransport
from xmlrpclib import ServerProxy

transport = BasicAuthTransport('admin', 'admin')
proxy = ServerProxy('http://localhost:8080/ok', transport=transport)

print 'method list:'
for method in proxy.listMethods():
    signature = proxy.methodSignature(method)[0]
    returned_type = signature[0]
    arguments_type = ', '.join(signature[1:])
    print '  + %s(%s) -&amp;gt; %s: %s' % (method, arguments_type, returned_type,
                                proxy.methodHelp(method).strip())
&lt;/pre&gt;

   &lt;p&gt;This small program will display all XML-RPC methods available on the
   folder &lt;cite&gt;ok&lt;/cite&gt;, with their signatures.&lt;/p&gt;

   &lt;p&gt;The XMLRPCAuth package is a simple module that provides a basic
   authorization transport, and can be taken here: &lt;a class="reference"
   href="https://svn.nuxeo.org/trac/pub/file/CPSRemoteController/trunk/XMLRPCAuth.py"&gt;
   XMLRPCAuth&lt;/a&gt;&lt;/p&gt;
&lt;pre class="literal-block"&gt;
tziade@Tarek:/home/tziade$ python z3test.py
method list:
+ contents() -&amp;gt; str: returns the content of the folder
&lt;/pre&gt;
  &lt;/div&gt;
 </content>

  <id>tag:blogs.nuxeo.com:sections:blogs:tarek_ziade:2005_11_04_xml-rpc-over-zope-3</id>
  <link rel="service.edit" type="application/atom+xml"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2005_11_04_xml-rpc-over-zope-3/atom?2005_11_04_xml-rpc-over-zope-3"
        title="Edit Here - XML-RPC over Zope 3, a quick tutorial" />
</entry>

  
  
      <entry xmlns="http://purl.org/atom/ns#"
       xmlns:dc="http://purl.org/dc/elements/1.1/">
     
  <title mode="escaped" type="text/html">Choosing an IDE for Python (updated)</title>
  <link rel="alternate" type="text/html"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2005_11_01_choosing-an-ide-for" />
  <issued>2005-11-03T10:52:16Z</issued>
  <modified>2005-11-03T10:52:16Z</modified>
  <created>2005-11-01T02:13:36Z</created>
  <draft xmlns="http://purl.org/atom-blog/ns#">false</draft>
  <author>
    <name>tziade</name>
  </author>
  
  
    <dc:subject>python</dc:subject>
  
  
  <summary type="text/html" mode="escaped">
  I am trying to choose a new IDE to write Python code, after a few problems I
  had with the *beeeep* generic editor I use.
   
   I've read the very interesting blurg from Jonathan Ellis here
  but i didn't find the IDE that fits me yet. I am trying them all.
   
   

  Wishlist
  The perfect IDE for me needs:
   

  
   easy encoding configuration: I do iso-8859-15 and some of ...</summary>

  <content type="text/html" mode="escaped"
           xml:space="preserve">
  I am trying to choose a new IDE to write Python code, after a few problems I
  had with the *beeeep* generic editor I use.&lt;br /&gt;
   &lt;br /&gt;
   I've read the very interesting blurg from Jonathan Ellis &lt;a
  href="http://spyced.blogspot.com/2005/09/review-of-6-python-ides.html"&gt;here&lt;/a&gt;
  but i didn't find the IDE that fits me yet. I am trying them all.&lt;br /&gt;
   &lt;br /&gt;
   

  &lt;h2&gt;Wishlist&lt;/h2&gt;
  The perfect IDE for me needs:&lt;br /&gt;
   

  &lt;ul&gt;
   &lt;li&gt;easy encoding configuration: I do iso-8859-15 and some of the IDE out
   there don't want me to.&lt;br /&gt;
   &lt;/li&gt;

   &lt;li&gt;simple, yet powerfull, code completion. Some of them are just
   crazy.&lt;br /&gt;
   &lt;/li&gt;

   &lt;li&gt;reasonable CPU/Mem load&lt;/li&gt;

   &lt;li&gt;A decent learning curve&amp;nbsp;&lt;br /&gt;
   &lt;/li&gt;

   &lt;li&gt;good enough code cleaning: trailing spaces removal&lt;/li&gt;

   &lt;li&gt;bad syntax notifier: for example SPE hilites bad syntax&lt;br /&gt;
   &lt;/li&gt;

   &lt;li&gt;decent debugguer links, with toggles.&lt;/li&gt;

   &lt;li&gt;easy macro programming&lt;/li&gt;

   &lt;li&gt;XML, ZPT, CSS, and third party editing as well, with proper
   *indentation*. 4 is nice for Python, I want 2 for ZPT !&lt;/li&gt;

   &lt;li&gt;...&lt;/li&gt;
  &lt;/ul&gt;
  &lt;br /&gt;
   Tried so far: drpython, SPE, Eric3, WingIde, Bluefish, BoaConstructor,
  Kate&lt;br /&gt;
   &lt;br /&gt;
   

  &lt;ul&gt;
   &lt;li&gt;drpython: really nice plugin, script features, i need to get deeper
   into it. autocompletion not really helpfull. I had to manually download and
   install plugins, the download UI bugged.&lt;br /&gt;
   &lt;/li&gt;

   &lt;li&gt;Eric3: pretty good, I miss some features though, still trying it
   up&lt;/li&gt;

   &lt;li&gt;WingIDE: really nice&lt;br /&gt;
   &lt;/li&gt;

   &lt;li&gt;SPE: Nice one, I had some bugs but Stani corrected them in the very
   same day I mentioned them.&lt;br /&gt;
   &lt;/li&gt;

   &lt;li&gt;Bluefish: not interesting for 100% python devel.&lt;/li&gt;

   &lt;li&gt;BoaConstructor: I can't get use to the UI, and had a few bugs&lt;br /&gt;
   &lt;/li&gt;
  &lt;/ul&gt;
  &lt;br /&gt;
   I won't try PyDev, i need to run other softwares when I am working ;)&lt;br /&gt;
   &lt;br /&gt;
   

  &lt;h2&gt;Conclusion&lt;br /&gt;
  &lt;/h2&gt;
  DrPython is one of the smartest, nicest of the list in my opinion, Eric3 and
  WingIde are rocking too. But at this time, I go for SPE, because it is a
  very fast moving project, and will probably fullfill all my wishes
  soon.&lt;br /&gt;
   &lt;br /&gt;
 </content>

  <id>tag:blogs.nuxeo.com:sections:blogs:tarek_ziade:2005_11_01_choosing-an-ide-for</id>
  <link rel="service.edit" type="application/atom+xml"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2005_11_01_choosing-an-ide-for/atom?2005_11_01_choosing-an-ide-for"
        title="Edit Here - Choosing an IDE for Python (updated)" />
</entry>

  
  
      <entry xmlns="http://purl.org/atom/ns#"
       xmlns:dc="http://purl.org/dc/elements/1.1/">
     
  <title mode="escaped" type="text/html">We'll miss you Zyon</title>
  <link rel="alternate" type="text/html"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2005_10_29_we-ll-miss-you-zyon" />
  <issued>2005-10-29T14:20:02Z</issued>
  <modified>2005-10-29T14:20:02Z</modified>
  <created>2005-10-29T14:16:44Z</created>
  <draft xmlns="http://purl.org/atom-blog/ns#">false</draft>
  <author>
    <name>tziade</name>
  </author>
  
  
  <summary type="text/html" mode="escaped">
  Jérôme Sandarnaud from the french Zope community (aka Zyon),
  who was just one of the greatest guy out there, is gone.
   
    
  
  
  We'll miss you so bad my friend !
  
   
 </summary>

  <content type="text/html" mode="escaped"
           xml:space="preserve">
  Jérôme Sandarnaud from the french Zope community (aka Zyon),&lt;br /&gt;
  who was just one of the greatest guy out there, is gone.&lt;br /&gt;
   &lt;br /&gt;
   &amp;nbsp;&lt;img style="width: 108px; height: 142px;"
  src="http://afpy.org/Members/tarek/afpynews.2005-10-28.4537965019/image" /&gt;
  &lt;br /&gt;
  &lt;br /&gt;
  We'll miss you so bad my friend !&lt;br /&gt;
  &lt;br /&gt;
   &lt;br /&gt;
 </content>

  <id>tag:blogs.nuxeo.com:sections:blogs:tarek_ziade:2005_10_29_we-ll-miss-you-zyon</id>
  <link rel="service.edit" type="application/atom+xml"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2005_10_29_we-ll-miss-you-zyon/atom?2005_10_29_we-ll-miss-you-zyon"
        title="Edit Here - We'll miss you Zyon" />
</entry>

  
  
      <entry xmlns="http://purl.org/atom/ns#"
       xmlns:dc="http://purl.org/dc/elements/1.1/">
     
  <title mode="escaped" type="text/html">Merging RSS and Atom feeds from various sources</title>
  <link rel="alternate" type="text/html"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2005_10_16_merging-rss-atom-feeds" />
  <issued>2005-10-16T08:18:19Z</issued>
  <modified>2005-10-16T08:18:19Z</modified>
  <created>2005-10-16T08:05:27Z</created>
  <draft xmlns="http://purl.org/atom-blog/ns#">false</draft>
  <author>
    <name>tziade</name>
  </author>
  
  
    <dc:subject>python</dc:subject>
  
  
    <dc:subject>semantic_web</dc:subject>
  
  
    <dc:subject>web</dc:subject>
  
  
  <summary type="text/html" mode="escaped">
  I have a lot of Python rss/atom feeds in my aggregator and entries are
  doubled all over the place.
   
   Could'nt find any tool that would merge entries from several sources out
  there, in a smart way, by trying to find doublons. 
   
   I wrote a little script, extending Mark Pilgrim's feedparser we use in 
  CPSRSS, to merge several sources, using the difflib module and the rss
 ...</summary>

  <content type="text/html" mode="escaped"
           xml:space="preserve">
  I have a lot of Python rss/atom feeds in my aggregator and entries are
  doubled all over the place.&lt;br /&gt;
   &lt;br /&gt;
   Could'nt find any tool that would merge entries from several sources out
  there, in a smart way, by trying to find doublons. &lt;br /&gt;
   &lt;br /&gt;
   I wrote a little script, extending Mark Pilgrim's &lt;a
  href="http://feedparser.org/"&gt;feedparser&lt;/a&gt; we use in &lt;a
  href="http://www.cps-project.org/static/doc/api/current/public/CPSRSS-module.html"&gt;
  CPSRSS&lt;/a&gt;, to merge several sources, using the difflib module and the rss
  rendering we have in &lt;a
  href="http://blogs.nuxeo.com/sections/blogs/eric_barroca/2005_08_19_cpsblog-now-support"&gt;
  CPSBlog&lt;/a&gt;.&lt;br /&gt;
   &lt;br /&gt;
   It calculates the diff ratio on the title and content of each entry to
  decide wheter &lt;br /&gt;
   it's the same entry. When the ratio is &amp;lt;= 0.2 it's the same entry
  (hopefully :) )&lt;br /&gt;
   &lt;br /&gt;
   Here's an example ran on these:&lt;br /&gt;
   

  &lt;ul&gt;
   &lt;li&gt;&lt;a
   href="http://www.planetpython.org/rss20.xml"&gt;http://www.planetpython.org/rss20.xml&lt;/a&gt;&lt;/li&gt;

   &lt;li&gt;&lt;a
   href="http://www.artima.com/buzz/feeds/python.rss"&gt;http://www.artima.com/buzz/feeds/python.rss&lt;/a&gt;&lt;/li&gt;

   &lt;li&gt;&lt;a
   href="http://blogs.nuxeo.com/sections/aggregators/all_posts/exportrss"&gt;http://blogs.nuxeo.com/sections/aggregators/all_posts/exportrss&lt;/a&gt;&lt;/li&gt;

   &lt;li&gt;&lt;a
   href="http://aspn.activestate.com/ASPN/Cookbook/Python/index_rss"&gt;http://aspn.activestate.com/ASPN/Cookbook/Python/index_rss&lt;/a&gt;&lt;/li&gt;
  &lt;/ul&gt;
  &lt;br /&gt;
   The result is &lt;a
  href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/metafeed.xml"&gt;here&lt;/a&gt;&lt;br /&gt;

   (It's a one-shot xmlfile, made today, so it's not a real feed&lt;br /&gt;
   &amp;nbsp;it is still readable by any client though)&lt;br /&gt;
   &lt;br /&gt;
   Now I've been told that this was pretty useless, and that i would better
  make some clean in my feeds and do more interesting stuff in my spare
  time.&lt;br /&gt;
   &lt;br /&gt;
   But i can't help it: everytime i see a feed related to python I just add
  the stuff&lt;br /&gt;
   &amp;nbsp;to my client :'). So for an unorganized person like me, a CPRSS
  personnal website with this merging capability, where i can drop tons of
  feeds would be perfect. &lt;br /&gt;
   &lt;br /&gt;
 </content>

  <id>tag:blogs.nuxeo.com:sections:blogs:tarek_ziade:2005_10_16_merging-rss-atom-feeds</id>
  <link rel="service.edit" type="application/atom+xml"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2005_10_16_merging-rss-atom-feeds/atom?2005_10_16_merging-rss-atom-feeds"
        title="Edit Here - Merging RSS and Atom feeds from various sources" />
</entry>

  
  
      <entry xmlns="http://purl.org/atom/ns#"
       xmlns:dc="http://purl.org/dc/elements/1.1/">
     
  <title mode="escaped" type="text/html">Neckar Zope 3 sprint - summary</title>
  <link rel="alternate" type="text/html"
        href="http://blogs.nuxeo.com/sections/blogs/tarek_ziade/2005_10_11_neckar-zope-3-sprint" />
  <issued>2005-10-11T15:06:22Z</issued>
  <modified>2005-10-11T15:06:22Z</modified>
  <created>2005-10-11T15:06:20Z</created>
  <draft xmlns="http://purl.org/atom-blog/ns#">false</draft>
  <author>
    <name>tziade</name>
  </author>
  
  
    <dc:subject>sprint</dc:subject>
  
  
    <dc:subject>zope3</dc:subject>
  
  
  <summary type="text/html" mode="escaped">
  I went to the 
  Neckar Sprint last week in Tubingen,
  Germany. 
  
  A lot of cool things were done/started there for Zope 3:

  
   Twisted integration

   Http publisher puggable sub-protocol
   

   Viewlet/portlet framework

   A static version of apidoc

   Some Zope3.org work

   Customizable container views, from the proposal 
   here

   XML-RPC introspection ...</summary>

  <content type="text/html" mode="escaped"
           xml:space="preserve">
  I went to the &lt;a
  href="http://www.zope.org/Wikis/DevSite/Projects/ComponentArchitecture/NeckarSprint"&gt;
  Neckar Sprint&lt;/a&gt; last week in &lt;a
  href="http://www.germany-tourism.de/e/city_tuebingen.html"&gt;Tubingen&l