Zwiki now supports PageTemplate, for version 0.10.0. Details are currently in ChangeLog?.

CC'd from the zope list:


Simon Michael, 2002/08/09 17:51 GMT (via mail):
Simon Michael <simon@joyful.com> writes:
> Hi Mark, thanks for your post.
>
> Mark Bucciarelli <mark@easymailings.com> writes:
> > I didn't find it that hard to integrate zwiki into an otherwise totally
>> zpt site. The hard part as far as moving to zpt is to pull all the
>> layout code (dtml statements) from the python. For example, all the '
>> href' stuff.
>
> I'm not sure what you mean here. What did you do with zwiki, exactly ?
>
>> I think it would be better to have the python process a DTML document,
>> and return some data structure (list or a dictionary) that the zpt
>> template lays out.
>
> Yes, I became a little clearer on this yesterday. Here's how I think zwiki
> could approach ZPTs? (can I call them Page Templates, or are they Zope
> Presentation Templates ?):
>
> 1. allow the "forms" - editform, subscribeform & backlinks - to be defined
> as ZPTs?. Would mean changing editform(), backlinks() & subscribeform().
>
> 2. allow the main page layout to be defined as a ZPT
> ("standard_wiki_page", "page_layout", "mainview" ?). Would mean
> changing (or adding new) render_ methods. Currently they all render and
> pre/append the DTML methods to the rendered page content as their final
> step. Instead they would now render the ZPT, passing the rendered page
> data into it's namespace for inclusion (right ?).
>
> At this stage,
>
> - you should be able to fully control the wiki's appearance by editing
> these four ZPTs?.
>
> - ZWikiPage still inherits from DTML Document, and dtml-enabled wikis and
> pages such as zwikidotorg's default UserOptions?, RecentChanges? and
> SearchPage? still execute embedded dtml.
>
> - the ZPT provides an additional dynamic parsing stage for the page, where
> you can do site-wide, admin controlled stuff - sounds useful
>
> 3. implement UserOptions?/RecentChanges?/SearchPage? in some other way than
> DTML, allowing you to purge DTML entirely from your wiki. For those who
> want that. :) (Personally, I want embedded restricted python).
>
> 4. make it so that each zwiki page is a ZPT. This should make it easier to
> edit a page with WYSIWYG tools. After an edit, zwiki would extract the
> essential body (eg strip the header & footer) for inclusion in the
> standard site ZPT.
>
> -Simon


Simon Michael, 2002/08/09 17:55 GMT (via mail):
Simon Michael <simon@joyful.com> writes:
> Re step 4 - actually we can take that approach with the current "links +
> HTML" or "HTML" page types. So we don't need ZPT-based pages to support
> WYSIWYG editing, but we might want them to support safe WYSIWYG editing of
> pages with user-editable dynamic content.


2002/08/11 23:53 GMT (via web):
Re Step 4: ZPT macros allow you to support this "extracting of essential body" already. The ZPT source would define the content section as a "slot". But then I'm not sure I like WYSIWYG for Wiki anyway. STX is good, HTML is ugly. I wonder if there is a way of allowing stx inside a ZPT, e.g. createa TAL attribute that says "render the content inside this tag as stx". I think that goes against the grain of ZPT though I think. In any case, ZPT for customization of a wiki is the way to go I think

DylanJay?