[Zope3-Users] Re: are aliases for content objects possible?
Derrick Hudson
dman at dman13.dyndns.org
Fri Aug 26 09:47:29 EDT 2005
On Thu, Aug 25, 2005 at 08:31:26AM +0200, Stefan Rank wrote:
| on 24.08.2005 16:32 Stéphane Brunet said the following:
| >Stefan Rank wrote:
| >>
| >>The main idea is to give an object several aliases.
| >>I would like to avoid having empty proxy-objects that fill the folder.
| >>The object itself would know about its different names and a
| >>presentation view could choose, e.g., the shortest one when used in a
| >>list or as an html page title, and the others would be displayed below.
| >>
| >I am not sure if I quite understand what you want to do but... Creating
| >custom views which changes the presentation would probably do the job,
| >without need to create aliases. You can select the view you want by
| >adding "/@@name_of_view" after the object in the url.
| >
|
| I don't think that would do it. The views would not provide two
| equivalent names for one object. And I actually do not want to have two
| different presentations, only two equivalent names.
| From my first mail::
|
| 'Equivalent' meaning you should be able to access it with
| scheme:host/path/name1 and scheme:host/path/name2 without any
| differences, and it should be in the catalog as only one object
|
| A practical example: A text that describes a book.
| I want to link to it as
| - http:/host/TheBookAboutLifeTheUniverseAndEverything
| - and http:/host/HinzKunzETAL2004
I would take a look at schoolbell, if I were you, and see how they do
it. Schoolbell is a calendar application. A calendar contains
events. The calendar can be viewed by day, week, or month eg
http://localhost/calendar/2005-08-26 or
http://localhost/calendar/2005-w31. The same events are shown in the
different views, but the event is a single object.
I think you want to create your own container type to hold your
objects. This container's __getitem__ can do whatever you want in
order to find the book, in the example above, when asked for either
name.
HTH,
-D
--
The righteous hate what is false,
but the wicked bring shame and disgrace.
Proverbs 13:5
www: http://dman13.dyndns.org/~dman/ jabber: dman at dman13.dyndns.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
Url : http://mail.zope.org/pipermail/zope3-users/attachments/20050826/424b30ce/attachment.bin
More information about the Zope3-users
mailing list