On Thu, Dec 29, 2005 at 11:22:28PM -0700, Jeff Shell wrote:
> Again, this is to have URLs like:
> myapp/@@tags/zope/viewlet
> And turn that into a catalog search for anyof {'zope', 'viewlet'}
>     def publishTraverse(self, request, name):
>         namestack = request.getTraversalStack()
>         if name not in namestack:
>             namestack.append(name)
>         namestack.reverse()
>         tags = tuple(namestack)
>         request.setTraversalStack([])
>         results = TaggedArticleFinder(self.__name__,self.__parent__,tags)
>         results.prepareSearch(request)
>         return results
> The 'TaggedArticleFinder' then provides an interface that a view can
> be found for that displays the results. So I've got it all working
> now...

My coworker Albertas recently implemented something like this in
SchoolTool (I've CCed him).  Unfortunately it turned out to have some
unforeseen consequences, for example, request.URL does not contain the
path elements you "eat" manually, breaking self-posting forms (those
that use <form tal:attributes="action request/URL">) and our login

> I was wondering - is this the best way to do this? Is there a better
> recipe floating around out there?

I would also like to know that.

Marius Gedminas
Any sufficiently advanced Operating System is indistinguishable from Linux.
                -- Jim Dennis

Attachment: signature.asc
Description: Digital signature

Zope3-users mailing list

Reply via email to