[Zope] I'm missing something really basic
Eric Walstad
eric@walstads.net
Thu, 07 Jun 2001 09:05:57 -0700
Hi Chris,
Well, this may just be an email typo, but I think there's a problem with
your query parameter string. Try changing:
http://localhost:8080/about/news?product=Xdata?newstype=review
to:
http://localhost:8080/about/news?product=Xdata&newstype=review
Aside from the funny looking URL, I just tried duplicating it like this
(notice the dtml-with tags):
DTML Method "test"
<dtml-var standard_html_header>
Product type: <dtml-var product><br>
News type: <dtml-var newstype><br>
<hr>
<dtml-with f1>
<dtml-var content>
</dtml-with>
<hr>
<dtml-var REQUEST>
<dtml-var standard_html_footer>
In folder "f1", below folder containing test, I have a DTML Method named
"content":
Product type: <dtml-var product><br>
News type: <dtml-var newstype><br>
Then I call it in the browser like this:
http://localhost:8080/test?product=Xdata&newstype=review
And everything renders nicely.
Hope that helps.
Eric.
> -----Original Message-----
> From: zope-admin@zope.org [mailto:zope-admin@zope.org]On Behalf Of Chris
> Ryland
> Sent: Wednesday, June 06, 2001 5:50 PM
> To: zope@zope.org
> Subject: [Zope] I'm missing something really basic
>
>
> I've been using Zope for a couple of weeks now fairly intensely, and
> learning fast. But then I run into the most obvious question in the world,
> and I'm stumped (perhaps it's too obvious). I've scoured the
> documentation,
> but I can't find it. So here goes.
>
> How does a dtml document refer to the URL parameters passed to it?
>
> E.g., I have a top-level index_html dtml method containing:
>
> <dtml-var standard_html_header>
> <dtml-var content fmt=structured-text>
> <dtml-var standard_html_footer>
>
> and a dtml document 'content' at each level in my tree with stx.
> So far, so
> good.
>
> But now I want to pass two parameters to one of these 'content'
> document, as
> in
>
> http://localhost:8080/about/news?product=Xdata?newstype=review
>
> I can't for the life of me figure out how to get those two
> parameters. They
> don't seem to be in the context, and they're only in the REQUEST
> in the raw
> parameter string (which I guess I could parse).
>
> Is it because this is a non-forms document that I don't get the
> parameters?
> --
> Cheers!
> Chris Ryland
> Em Software, Inc.
> www.emsoftware.com
>
>
>
> _______________________________________________
> 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 )