Re: [Zope-dev] SVN: zope2book/trunk/ Lot's of updates over the weekend!
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Hanno Schlichting wrote:
Log message for revision 96569: Lot's of updates over the weekend!
Changed: A zope2book/trunk/TODO.txt A zope2book/trunk/old/ A zope2book/trunk/old/AdvDTML.rst A zope2book/trunk/old/DTML.rst U zope2book/trunk/source/Acquisition.rst D zope2book/trunk/source/AdvDTML.rst
I think it is too premature to be moving the DTML chapters out of the book: if we arent just updating the book to be current with 2.12, then we probably need to discuss what kind of book we want, before chopping it apart. At the moment, the book is largely a guide to what can be done with Zope TTW. DTML is still part of that store: it isn't gone, nor even deprecated: its just that most core developers prefer not to use it in most cases. Note that there is still no replacement for DTML for at least one major TTW use case (SQL methods). Rewriting the "when to use ZPT vs. DTML bits, and making them more prominent earlier in the book, would be a sensible change. Tres. - -- =================================================================== Tres Seaver +1 540-429-0999 tseaver@palladion.com 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 iD8DBQFJmDiA+gerLs4ltQ4RAhIHAKCzo/z1InRyAx5rz2GI0grrHwC9/ACfa6oL 4YOVh5HtzRuLYEkhCDNncpE= =LDwp -----END PGP SIGNATURE-----
Tres Seaver wrote at 2009-2-15 10:45 -0500:
... At the moment, the book is largely a guide to what can be done with Zope TTW. DTML is still part of that store: it isn't gone, nor even deprecated: its just that most core developers prefer not to use it in most cases. Note that there is still no replacement for DTML for at least one major TTW use case (SQL methods).
In addition, CSS and Javascript is easier generated with DTML than with page templates. -- Dieter
Dieter Maurer wrote:
Tres Seaver wrote at 2009-2-15 10:45 -0500:
... At the moment, the book is largely a guide to what can be done with Zope TTW. DTML is still part of that store: it isn't gone, nor even deprecated: its just that most core developers prefer not to use it in most cases. Note that there is still no replacement for DTML for at least one major TTW use case (SQL methods).
In addition, CSS and Javascript is easier generated with DTML than with page templates.
You should really not generate CSS ;) And JS is best generated with Jason :-) Regards Tino
On Tue, Feb 17, 2009 at 12:08, Tino Wildenhain <tino@wildenhain.de> wrote:
You should really not generate CSS ;) And JS is best generated with Jason :-)
You need to generate CSS when you want to use absolute paths for images referred to in your CSS. This can easily be done with ZPT: <tal:css define="portal python:request['PARENTS'][1]; portal_url portal/portal_url" replace="string: .ac_loading { background: white url('$portal_url/spinner.gif') right center no-repeat; } " /> The above code snippet is taken from a current project; the portal_url dance is there because this is a browser:resource template and such a template only has access to the request, not a context. We also generate some JS to provide client-side code with translated labels. Alternatively you can do this with hidden elements in your main template as well, but the generated JS way was more maintainable as this keeps the labels and the code close together. -- Martijn Pieters
Previously Martijn Pieters wrote:
On Tue, Feb 17, 2009 at 12:08, Tino Wildenhain <tino@wildenhain.de> wrote:
You should really not generate CSS ;) And JS is best generated with Jason :-)
You need to generate CSS when you want to use absolute paths for images referred to in your CSS. This can easily be done with ZPT:
Very often you don't need to do that though, and it actively breaks the ability to do prototyping with your html and css outside of the application. Wichert. -- Wichert Akkerman <wichert@wiggy.net> It is simple to make things. http://www.wiggy.net/ It is hard to make things simple.
On Tuesday 17 February 2009, Wichert Akkerman wrote:
You need to generate CSS when you want to use absolute paths for images referred to in your CSS. This can easily be done with ZPT:
Very often you don't need to do that though, and it actively breaks the ability to do prototyping with your html and css outside of the application.
You could also port z3c.zrtresource to Zope 2, which solves this exact problem. Regards, Stephan -- Stephan Richter Web Software Design, Development and Training Google me. "Zope Stephan Richter"
participants (6)
-
Dieter Maurer -
Martijn Pieters -
Stephan Richter -
Tino Wildenhain -
Tres Seaver -
Wichert Akkerman