[ZIZope] un modo semplice per customizzare le viewlet

Yuri <[email protected]>
Newsgroups gmane.comp.web.zope.italian
Message-ID <[email protected]>
http://mockit.blogspot.com/2007/11/viewlets-are-simple-again.html


      Viewlets are simple again
      <http://mockit.blogspot.com/2007/11/viewlets-are-simple-again.html>

Recently there's been some debate on the difficulty in customizing Plone 
3. Yesterday, Mikko Ohtamaa asked in a blog post if it couldn't be 
made easier to customize 
<http://blog.redinnovation.com/2007/11/26/could-it-be-possible-to-make-viewlets-simple-again> viewlets. 
Sure it can.


Inspired by Torvald de Boskat <http://torvald.jottit.com/>, the testing 
underground is proud to present z3c.jbot  
<http://svn.zope.org/z3c.jbot/trunk/README.txt>(just a bunch of templates).

Here's how it works. First you need to register a template overrides 
directory.

|  <include package="z3c.jbot" file="meta.zcml" />
  <browser:templateOverrides
      directory="templates" />
|

Say you want to provide a different template for 
/plone/app/layout/viewlets/logo.pt.

Simply put a file called plone.app.layout.viewlets.logo.pt in your 
template overrides directory, restart, and you're done.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.