[Zope] dtml-if question

Paul Zwarts paz@oratrix.com
Tue, 12 Jun 2001 16:17:59 +0200


Well, from what I can think a good method is to have the images in the names
of the variable passed into the tokens querystring. Thus:

<dtml-if "_.has_key('tokens')">
   <dtml-let getimage='_.getitem('tokens')">
      <dtml-var getimage>
   </dtml-let>
</dtml-if>

Or something along the lines of that. So as long as you have all of the
images present for the variable that is passed in the querystring, you'll
get the image that is correct for it.

Hope that helps,
Paz


-----Original Message-----
From: zope-admin@zope.org [mailto:zope-admin@zope.org]On Behalf Of James
van der Veen
Sent: 12 June 2001 13:57
To: 'Zope@zope.org'
Subject: [Zope] dtml-if question


Hi all,

I have a question about The dtml-if.

I would like to call an image depending on the url I am at.

Lets say Somsone searches for an article on school I have the folowing URL:

http://codenamefuture.hurrah.com/nieuws/zoek?SearchableText=&Subject%3Atoken
s=school

If I wnated to write a dtml-method telling it should load the school image
in stead of the standard image how would I call that image?

Hope someone can help me on this.

James

_______________________________________________
Zope maillist  -  Zope@zope.org
http://lists.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists -
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope-dev )