> -----Original Message-----
> From: Jim Fulton [mailto:[EMAIL PROTECTED]]
> Sent: Thursday, August 10, 2000 9:51 PM
> To: David C. Kankiewicz
> Cc: Jay, Dylan; '[EMAIL PROTECTED]'
> Subject: Re: [Zope-dev] OFS.objectManager checking object Ids
> "David C. Kankiewicz" wrote:
> > 
> > "Jay, Dylan" wrote:
> > >
> > > As I said, when the url is quoted there is no problem.
> > >
> > > 
> http://azonia.auslabs.lucent.com/Auslabs/AuslabsFAQ/Where%20is%20X%3f
> > >
> > > causes no problems. The above object is sitting happily 
> inside Zope with a
> > > question mark at the end. I had to let the bad_id check 
> let it pass but is
> > > there any reason why it shouldn't?
> > 
> > bad_id=ts_regex.compile('[^a-zA-Z0-9-_~\,\. ]').search #TS
> > 
> > The .search was .match
> > Changing it back restores the behavior, who changed it and 
> why is the
> > question?
> I don't know who changed it, but the why is obvious.
> 'match' was clearly a bug, since it only found an 
> invalid character if it was at the beginning of an id.
> I think that it's a bad idea to allow '?'s in ids
> and am sorry if it was allowed. In general, I don't
> like to see characters in ids that need to be quoted.
> I'm not happy that ' ' was added, although 
> I understand why.

It may seem like a wise idea not to allow such chars into an id but I'd to
explore this issue a little more as I think it is not quite as trivial as it

The proposition I'm putting forward is that, if Zope copes with it why not
let it. In dtml your already have to quote things like sequence-item becuase
its not valid python but people cope with that. What we are talking about is
have a sensible match between what an item is and what its called. I know
that that is what the title property is for however look at the example that
lead me to this problem in the first place.

I want an FAQ that people in my department can all add too. None of the
existing FAQ's are good enough. They arn't flexible or customizable enough.
So I decided to use ZWiki which is flexible and customizable. But ZWiki
needs WikiNames which become the object ids. A FAQ contains questions.
Questions don't make good wiki names but structured text lets me make
anything into a WikiName eg [How do I turn a ZWiki into a collaborative
So I create a dtml method that appends this text to the end of a wiki page
and create the resulting question page (with the question mark in the id).
This makes it a reasonably usable FAQ system with all the benifits of a
ZWiki. People can move questions around my cutting and pasting. I can let
people see who is editing what with a little bit of coding here and there.

So without the question directly in the id I'm left with the "how to create
a unique id" and then I have reference it within pages using the title
anyway becuase I don't want people seeing the random ID. Why should I have
to go to so much trouble when I can just call the object by the title anyway
and Zope has no problem with it. It makes it easier for me and I'm sure it
will make it easier for other uses to. Resorting to random names in urls is
ugly and unneccerily complicated. If Zope fundumentally can't cope with
strange ids then say so but I've seen no evidence of this.

Anyway, thats my 2c worth.

Zope-Dev maillist  -  [EMAIL PROTECTED]
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope )

Reply via email to