<div>I tried this:</div>
&lt;a tal:attributes="href string:${here/a_script}?doc=${x}"&gt;

<div>but got this error:<br>
<STRONG>Error Type: TypeError<br>
Error Value: a_script() takes exactly 1 argument (0 given)</STRONG><br>
Next, I rewrote the script to put in a try statement for the variable, to test that, but before I even got to test I looked at the rendered code from the above line and it gave me this:<br>
&lt;<SPAN class=start-tag>a</SPAN><SPAN class=attribute-name> href</SPAN>=<SPAN class=attribute-value>"&amp;lt;html&amp;gt;&amp;lt;body&amp;gt;nope&amp;lt;/body&amp;gt;&amp;lt;/html&amp;gt;?doc=0"</SPAN>&gt;<br>
So it doesn't look like the "string:${..." workaround worked :(<br>
And I don't think I need to URLquote.<br>
TIA,<br>
Tony<br>
<br>
<br>
-----Original Message-----<br>
From: Chris Withers &lt;chris@simplistix.co.uk&gt;<br>
To: tonylabarbara@aol.com<br>
Cc: lists@zopyx.com; zope@zope.org<br>
Sent: Wed, 15 Aug 2007 11:05 am<br>
Subject: Re: [Zope] How Do I "Structure" This?<br>
<br>
</div>


<div id=AOLMsgPart_0_518a2dd8-cf95-4fb2-8cb8-0555fbc64257 style="FONT-SIZE: 12px; MARGIN: 0px; COLOR: #000; FONT-FAMILY: Tahoma, Verdana, Arial, Sans-Serif; BACKGROUND-COLOR: #fff">Ah Tony,&nbsp;<br>
&nbsp;<br>
looks like the penny is yet to drop...&nbsp;<br>
&nbsp;<br>
<A href="mailto:tonylabarbara@aol.com">tonylabarbara@aol.com</A> wrote:&nbsp;<br>
&gt; Bummer. Well, I'm trying to call a script that will render content to the Web, like this:&nbsp;<br>
&gt; &lt;a tal:attributes="href python:here.a_script(str(x))"&gt;&nbsp;<br>
&nbsp;<br>
My guess is that what you're _really_ trying to do here is:&nbsp;<br>
&nbsp;<br>
&lt;a href=""&nbsp;<br>
&nbsp;tal:attributes="href string:${here/a_script/absolute_url}?avar=${x}"/&gt;&nbsp;<br>
&nbsp;<br>
...but next you'll be wondering how to url quote x.&nbsp;<br>
&nbsp;<br>
I feel we're fighting a loosing battle here...&nbsp;<br>
&nbsp;<br>
Chris&nbsp;<br>
&nbsp;<br>
-- Simplistix - Content Management, Zope &amp; Python Consulting&nbsp;<br>
&nbsp; - <A href="http://www.simplistix.co.uk/" target=_blank>http://www.simplistix.co.uk</A>&nbsp;<br>
</div>
<!-- end of AOLMsgPart_0_518a2dd8-cf95-4fb2-8cb8-0555fbc64257 --><div class="AOLPromoFooter">
<hr style="margin-top:10px;" />
AOL now offers free email to everyone.  Find out more about what's free from AOL at <a href="http://www.aol.com?ncid=AOLAOF00020000000437" target="_blank"><b>AOL.com</b></a>.<br />
</div>