[Zope] Using standard_html_header to display banner
EvH
edward_van_h@bigfoot.com
Mon, 29 Apr 2002 01:03:34 +0200
--=====================_47712557==_.ALT
Content-Type: text/plain; charset="us-ascii"; format=flowed
Hi,
I've been checking out Zope by reading the Zope Book, and am stuck with
something: I'm building an intranet to contain documents. Each document
should have a banner to display the document's Title and a bitmap whose id
is the document's title and ".png" appended.
For instance, a document called "widget.html" will have a Title section
called "Quick & Dirty Guide to Widgets", and the Image object displayed
along the title in the banner should be widget.html.png .
1. Here's the standard_html_header DTML Method:
<html>
<head><title><dtml-var title></title></head>
<body>
<table border="0" width="100%">
<tr>
<td width="70%"><h1><dtml-var title></h1></td>
<td align="right"><img src="<dtml-var id>.png"></td>
</tr>
</table>
2. And here's the index_html DTML Method that includes code to display a
list of sub-folders:
<dtml-var standard_html_header>
<table width=100% border=0>
<dtml-in expr="objectValues('Folder')">
<tr>
<td><a href="&dtml-absolute_url;"><dtml-var title_or_id></a></td>
<td><dtml-var bobobase_modification_time fmt="aCommon"><td>
</tr>
</dtml-in>
</table>
<dtml-var standard_html_footer>
Problem:
- If I use a DTML Method object for a document, <dtml-var title> in the
standard_html_header shows the container's Title (!) instead of the
document's Title
- If I use a DTML Document instead, <dtml-var title> does show the
document's Title as expected, but the <dtml-in ...> code is not run.
Do you know of any easy way to let writers include a banner by just
including <dtml-var standard_html_header> ?
Thx a bunch for any tip
EvH.
--=====================_47712557==_.ALT
Content-Type: text/html; charset="us-ascii"
<html>
Hi,<br><br>
I've been checking out Zope by reading the Zope Book, and am stuck with
something: I'm building an intranet to contain documents. Each document
should have a banner to display the document's Title and a bitmap whose
id is the document's title and ".png" appended. <br>
For instance, a document called "widget.html" will have a Title
section called "Quick & Dirty Guide to Widgets", and the
Image object displayed along the title in the banner should be
widget.html.png .<br><br>
1. Here's the standard_html_header DTML Method:<br><br>
<html><br>
<head><title><dtml-var
title></title></head><br><br>
<body><br>
<table border="0" width="100%"><br>
<tr><br>
<td
width="70%"><h1><dtml-var
title></h1></td><br>
<td
align="right"><img src="<dtml-var
id>.png"></td><br>
</tr><br>
</table><br><br>
2. And here's the index_html DTML Method that includes code to display a
list of sub-folders:<br><br>
<dtml-var standard_html_header><br><br>
<table width=100% border=0><br><br>
<dtml-in expr="objectValues('Folder')"><br>
<tr><br>
<td><a
href="&dtml-absolute_url;"><dtml-var
title_or_id></a></td><br>
<td><dtml-var bobobase_modification_time
fmt="aCommon"><td><br>
</tr><br>
</dtml-in><br><br>
</table><br><br>
<dtml-var standard_html_footer><br><br>
Problem:<br>
- If I use a DTML Method object for a document, <dtml-var title> in
the standard_html_header shows the container's Title (!) instead of the
document's Title<br>
- If I use a DTML Document instead, <dtml-var title> does show the
document's Title as expected, but the <dtml-in ...> code is not
run.<br><br>
Do you know of any easy way to let writers include a banner by just
including <dtml-var standard_html_header> ?<br><br>
Thx a bunch for any tip<br>
EvH.</html>
--=====================_47712557==_.ALT--