Until the gurus find time to jump in with `the right` solution...
On 2/5/07, Florian Lindner <[EMAIL PROTECTED]> wrote:
The line in the template.pt: <a tal:attributes="href context/@@index.html/@@absolute_url">home</a> works fine as long as context is an IXGM, because index.html is registered for IXGM. But if a view from the IBlog is called is it also rendered in the template.pt but context now is a IBlog which does not have an index.html (or at leat not the one I want) and therefore fails.
Your template *assumes* the context will always have an `index.html` view. So it can not be used for a context that doesn't have it. At any rate, context is not the best object you can use to link to home. It's better to use site root for that purpose. Something like: <a tal:attributes="href view/siteroot/@@index.html/@@absolute_url">home</a> Where you find site root using zope3 APIs in view code and assign it to siteroot. Disclaimer: I have been away from Zope3 for a long time and my knowledge was not advanced even then. So if I am talking non-sense, you can safely ignore me :-) Mohsen, _______________________________________________ Zope3-users mailing list [email protected] http://mail.zope.org/mailman/listinfo/zope3-users
