[Zope] Turn static HTML dynamic?

Ben Leslie benno@sesgroup.net
Mon, 11 Oct 1999 22:38:06 +1000


Moin User!

User Webteam schrieb am Montag, den 11. Oktober 1999:

> Hi!
> 
> We´re thinking about using Zope for our University website. Now we face
> following problem:
> We need a simple solution for people who don´t want to care about DTML
> to publish their documents using Composer or similar WYSIWYG tools.
> These documents should be rendered with some standard HTML-code
> (navigation and the like). Is there any possibility to do this without
> having to teach everyone <dtml-var> etc.? We tested various things
> (access rules) but in the best case we end up with nested <html> tags.
> Unfortunately, we have no python experts here and we´re not learning
> fast enough to present a solution within time.
> 
> Some background info: we have to ensure that virtually erveryone here
> has a simple way to put information on the net. Most of these people
> have little or no HTML knowledge but use Composer, HotMetal or even word
> to create their documents. So it seems unacceptable to our bosses to
> bother anyone with manipulating sources. We would really like to use
> Zope because of its great management features, user management and
> expandibility (and its price ;-), so any hints would be highly
> appreciated.
> 
> Chris


Mmm.. The best solution I can think of is to go  and edit the source.

I think if you tried editing the manage_upload, manage_edit etc in 
/lib/python/OFS/DTMLDocument.py to strip everything up to the <BODY>
tag and replace it with your <dtml-standard_html_header> and
everything after </BODY> with <dtml-var standard_html_footer>. That means
you will probably lose some of the information in the <HEAD> tag
(like meta-tags and the like), so depending on how useful these are
to you in this situation. 

Of course this solution means learning python, although I have found
that if you have programmed in other languages before it is pretty
easy to pick up quickly.


Then again there may be some much easier way to do this which 
I don't know about. 

Benno


(I may even end up implementing this tonight since it seems pretty easy
todo and would be useful to many people, however don't hold me to that)