[Zope-PTK] Search engine woes solved, sorta
Mike Pelletier
mike@digicool.com
Wed, 8 Mar 2000 13:57:46 -0500 (EST)
On Wed, 8 Mar 2000, Nolan Darilek wrote:
> I'm using the management interface, and don't see any of the
> PortalContent objects (Document, Link, NewsItem, etc.) in the list.
Oh dear, you're correct, they're not there. I must have broken this
recently. I'll see what I can do about it shortly.
> How exactly does the cut-n-paste mechanism work? Does it use cookies,
> or something else?
It uses cookies.
> I'm using emacs/w3, which basically places each page in an emacs
> buffer. So once I cut the item, I switch to the buffer containing the
> destination page, reload it, and try to click on 'Paste'. This doesn't
> work for me, though, and it may be due to bugs with w3's cookie
> support.
Yeah, it sounds as though it's not sharing cookies between browsers.
> Also, what is the difference between Portal Folder and Folder? I've
> been creating regular folders; should I convert these to Portal
> Folders?
The Portal Folder implements a bunch of methods which support the
Content Manager's interface. (My Stuff) I would have preferred to put
these methods on the portal and allow the folder to acquire them, but that
doesn't work so well. I think I might know why now, so they may go away
sometime soon.
You should use Portal Folders anyplace you intend to add Portal
Content. Sorry.
> What happens to an object when its owner's
> user is erased but the object still remains? Is its owner changed to
> the superuser or manager?
Presently, I think the object would become 'unowned', but it may stay
owned by the nonexistant userid. I'm not certain. The behaviour is
defined by the local roles machinery. (Ownership is just a local role.)
I don't know what happens to a user's local roles if they are deleted...
> Cool -- looking forward to seeing it! My next project is a Newsletter
> Z Class; something which basically squeezes several documents and
> images together into one single Z Class.
I was unclear. The code is in the CVS, but it's not imported anywhere
at the moment. So, it's available to examine, but it's not available to
use unless you modify your __init__.py module to import it.
> As another completely random question, I have several classes which
> weren't distributed with Python source, but which I'd like to make
> more portal-aware. I'm using ZRTChat, for example. I'd like to hack it
> so that it only allows you to enter the room under your Zope username,
> and not any arbitrary name. I'm also using an ad banner system (I
> can't remember which one ATM) and I'd like to make it portal-aware so
> that I can use the Ad wizard which I've partially created so that
> folks can upload ad banners. I could derive a class if I had the
> Python source, but what if the products are only distributed as
> .zexp's? Is it possible to modify these products so that they work as
> PortalContent?
If you're feeling superstudly, you can modify a ZClass's base classes
in-place. So, you could insert PortalContent. If your database slaps you
around, insults your fashion sense and self-corrupts, you're on your own.
The other posibility is to simply subclass the ZClass, mixing in
PortalContent. This is untried, but aughta work. To be honest, though, I
haven't tested ZClass-based portal content objects in a while. Let me
know how it works out if you try it.
Mike.
--
Mike Pelletier email: mike@digicool.com
Mild mannered software developer icq: 7127228
by day, super villain by night. phone: 519-884-2434