[Zope] Aquisition questions

Ian Sparks Ian Sparks" <isparks@wmute.u-net.com
Fri, 2 Jun 2000 16:02:15 +0100


Shane, your idea about extending the URL and putting in an extra folder in
the path will work but its a bit of a fix rather than a solution. Right now
this isn't a RealLife(TM) problem for me, just part of my trying to get to
grips with Zope and its potential pitfalls.

>>
Isn't there a way to cause the SQLMethods to provide "UserRowID" and
"FlavorRowID" instead?  That would be the most logical solution.
<<

Again, this is a good idea but it doesn't solve the fundamental problem
which is that URL's are meant to be traversed in a particular way, if the
"clever" user traverses them in a different way than intended you *could*
end up in a mess.

- Ian.


----- Original Message -----
From: "Shane Hathaway" <shane@digicool.com>
To: "Ian Sparks" <isparks@wmute.u-net.com>
Cc: <zope@zope.org>
Sent: Friday, June 02, 2000 3:40 PM
Subject: Re: [Zope] Aquisition questions


Ian Sparks wrote:
> Is there a way to enforce URL's be traversed in a set way? Thus making :
>
> mysite.com/Users/Fred/Flavor/Cherry/test
>
> valid while mysite.com/Flavor/Cherry/Users/Fred/test becomes invalid.

You could set up an object called "Users" that would be found only if
the user goes through "Flavor" first.  Your example will have to be
modified to get it to work.

should work: mysite.com/Users/Fred/FlavorFolder/Flavor/Cherry/test

should not work: mysite.com/FlavorFolder/Flavor/Cherry/Users/Fred/test

FlavorFolder is a folder at the same level as Users.  It contains an SQL
query called Flavor and an object called Users.  The Users object in
this folder raises an exception, telling the clever user to back off.

Just a possibility.

> Also, assuming that both SQLMethods provide a "RowID", how do I specify
> explicitly which one I want, in OO terms :
>
> Users.RowID or Flavor.RowID

Isn't there a way to cause the SQLMethods to provide "UserRowID" and
"FlavorRowID" instead?  That would be the most logical solution.

Shane

_______________________________________________
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 )