Hi,

On Thu, Feb 08, 2007 at 04:54:51PM +0100, Florian Lindner wrote:
> Am Mittwoch, 7. Februar 2007 07:50 schrieb Jürgen Kartnaller:
> > Florian,
> > if you want the url to your current site implement this :
> >
> >
> > class SiteUrlView(object):
> >
> >      def __call__(self):
> >          return absoluteURL(hooks.getSite(), self.request)
> >
> > And register a page :
> >
> >    <page
> >        name="site_url"
> >        for="*"
> >        class=".views.SiteUrlView"
> >        permission="zope.Public"
> >        />
> >
> > Now you can use context/@@site_url anywhere.
> 
> Hi,
> this works perfect when using it like:
> 
> <a tal:attributes="href context/@@site_url">home</a> 
> 
> but when I try to directly link to a view registered with the object site_url 
> returns:
> 
> <a tal:attributes="href context/@@site_url/@@search.html">suche</a>

Try

 <a tal:attributes="href string:${context/@@site_url}/@@search.html">suche</a>

Regards,

Frank
_______________________________________________
Zope3-users mailing list
Zope3-users@zope.org
http://mail.zope.org/mailman/listinfo/zope3-users

Reply via email to