This is a pre-production deployment of Warehouse, however changes made here WILL affect the production instance of PyPI.
Latest Version Dependencies status unknown Test status unknown Test coverage unknown
Project Description

This package try to bring the functionality of z3c.template and
z3c.pagelet to grok.

z3c.template gives us a alternative for the zpt:metal layout based system in grok.
The z3c.pagelet has the advantage that it´s possible to register layouts with
help of
the zope-component-architecuture this allows us to change or modify layouts
without touching the *master* macro.

This means you have megrok.pagelet.Layout component which holds
the layout. Instead of using grok.View you have to take
megrok.pagelet.Pagelet for normal BrowserViews.

If you need more information about z3c.template please look here [1].

The Layout

The first thing we have to do is set up a layout for our pagelet.

class MyLayout(megrok.pagelet.Layout):


This configures the template ('') as a layout for the given
context and layer. Of course it´s possible to specify different
layouts for different layers or contexts.

In the content of is something like this:

<div class="layout" tal:content="structure view/render">
here comes the content

The Pagelt (View)

Ok instead of using the common grok.View for our BrowserViews we use now
megrok.pagelet.Paglet. This component has one difference to a normal
grok.View. This difference is in the __call__ method of the megrok.pagelet.Pagelet.
This means that the __call__ method of a Pagelet does not only return the renderd
"template" of the Pagelet. The __call__ first search for the layout in given context
and layer and then it renders the "template" in this layout.

class View(megrok.pagelet.Pagelet)

def render(self)
return "..."

Now if you point your browser on .../view you sould see the renderd view in the
given layout.


trunk (2009-03-24)

- xxx

0.1 (2009-03-24)

Initial release as egg.
Release History

Release History


This version

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

Download Files

Download Files

TODO: Brief introduction on what you do with files - including link to relevant help section.

File Name & Checksum SHA256 Checksum Help Version File Type Upload Date
megrok.pagelet-0.1.tar.gz (9.0 kB) Copy SHA256 Checksum SHA256 Source Mar 24, 2009

Supported By

WebFaction WebFaction Technical Writing Elastic Elastic Search Pingdom Pingdom Monitoring Dyn Dyn DNS HPE HPE Development Sentry Sentry Error Logging CloudAMQP CloudAMQP RabbitMQ Heroku Heroku PaaS Kabu Creative Kabu Creative UX & Design Fastly Fastly CDN DigiCert DigiCert EV Certificate Rackspace Rackspace Cloud Servers DreamHost DreamHost Log Hosting