Re: [Zope] Re: Best Practice for including Javascript in Zope Applications
Andreas Jung wrote: ... Larger JS frameworks like Dojo tend to be split across several files and directories. The fun starts when such frameworks load/reload stuff using relative URLs. A co-worker using Dojo intensively had to invest some time in order to integrate such a JS monster properly. As far as I remember Extjs also uses multiple files (but not as much as Dojo does)..so please check in advance. Another point: consider using CMF and putting your library files into a directory system view on the filesystem. This makes your life much easier. Or just upload via WEBDAV. One of the biggest advantages of Zope is the isolation from physical file system. Regards Tino ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] Re: Best Practice for including Javascript in Zope Applications
--On 2. Januar 2008 06:16:06 +0100 Andreas Jung <[EMAIL PROTECTED]> wrote: --On 1. Januar 2008 21:16:21 -0500 Tres Seaver <[EMAIL PROTECTED]> wrote: What should I do to use these libraries? Is there a canned solution for this sort of thing? The simplest route: - Create a "File" object in the ZMI for each separate javascript library (e.g., 'extlibrary.js'). - Upload the static content of the library file to that object. - Include a link to the JS library in your master page template, e.g.:: Larger JS frameworks like Dojo tend to be split across several files and directories. The fun starts when such frameworks load/reload stuff using relative URLs. A co-worker using Dojo intensively had to invest some time in order to integrate such a JS monster properly. As far as I remember Extjs also uses multiple files (but not as much as Dojo does)..so please check in advance. Another point: consider using CMF and putting your library files into a directory system view on the filesystem. This makes your life much easier. -aj pgpttdu7ndSoF.pgp Description: PGP signature ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
Re: [Zope] Re: Best Practice for including Javascript in Zope Applications
--On 1. Januar 2008 21:16:21 -0500 Tres Seaver <[EMAIL PROTECTED]> wrote: What should I do to use these libraries? Is there a canned solution for this sort of thing? The simplest route: - Create a "File" object in the ZMI for each separate javascript library (e.g., 'extlibrary.js'). - Upload the static content of the library file to that object. - Include a link to the JS library in your master page template, e.g.:: Larger JS frameworks like Dojo tend to be split across several files and directories. The fun starts when such frameworks load/reload stuff using relative URLs. A co-worker using Dojo intensively had to invest some time in order to integrate such a JS monster properly. As far as I remember Extjs also uses multiple files (but not as much as Dojo does)..so please check in advance. Andreas pgpIbHpEqBnzc.pgp Description: PGP signature ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
[Zope] Re: Best Practice for including Javascript in Zope Applications
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Matt Hollingsworth wrote: > I'm new to developing for zope, and I have a quick question regarding some > best practices when using Javascript in zope applications. > > > I would like to use Ext JS (http://www.extjs.com/ ) in an application that I > am writing. It is a fairly extensive library, so I didn't really want to > copy/paste every single file into a dtml method. I looked all over the > place for some discussion on this subject, but only found things relating to > plone (which apparently has a javascript registry); however, I wish to stay > away from plone for this particular application. > > What should I do to use these libraries? Is there a canned solution for > this sort of thing? The simplest route: - Create a "File" object in the ZMI for each separate javascript library (e.g., 'extlibrary.js'). - Upload the static content of the library file to that object. - Include a link to the JS library in your master page template, e.g.:: Tres. - -- === Tres Seaver +1 540-429-0999 [EMAIL PROTECTED] Palladion Software "Excellence by Design"http://palladion.com -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.6 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFHevP1+gerLs4ltQ4RAvjPAJ9DzvRiALdpBCJWmgk/Iy5NE+WTgACfSwkP GpI0Nt2CC08qn7o4B+e/xcw= =dijk -END PGP SIGNATURE- ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
[Zope] Best Practice for including Javascript in Zope Applications
Hello, I'm new to developing for zope, and I have a quick question regarding some best practices when using Javascript in zope applications. I would like to use Ext JS (http://www.extjs.com/ ) in an application that I am writing. It is a fairly extensive library, so I didn't really want to copy/paste every single file into a dtml method. I looked all over the place for some discussion on this subject, but only found things relating to plone (which apparently has a javascript registry); however, I wish to stay away from plone for this particular application. What should I do to use these libraries? Is there a canned solution for this sort of thing? Thank you much! -Matt ___ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )