RE: [Zope] ZCatalog dynamic sites

2000-07-21 Thread Chris McDonough

Dimitris,

Yes, ZCatalog cannot index methods which require call arguments.  Pages
generated from SQL data either use "brains" of SQL methods or squery
string arguments of a DTML method, and therefore need to be passed
arguments and cannot be cataloged.


-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]]
Sent: Friday, July 21, 2000 2:44 AM
To: [EMAIL PROTECTED]
Subject: [Zope] ZCatalog  dynamic sites


Hi all,
I have a Zope site that uses MySQL to dynamically create some pages.
What I want is the ability to search throughout the site, INCLUDING
the pages that are database-driven. It seems to me that ZCatalog only 
finds items that exist *in zope*.

Is it something ZCatalog can't do or am I missing anything obvious ?
--
Dimitris 
http://atlas.central.ntua.gr:8000/~mc94068

___
Zope maillist  -  [EMAIL PROTECTED]
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 )




[Zope] RE: [ Zope] ZCatalog dynamic sites

2000-07-21 Thread Corey Zimmet


Write a brains class that you would call to catalog and uncatalog
insert/update/delete ZSQLmethods:

For example:

class MyObject:
"""
Some arbitrary object - MyObjectID - the id of your object
MyCatalog -  the catalog you want to use to
index the sql
MyText1 -metadata column in your catalog
MyText2 -an additional metadata column in
your catalog
"""

def FullText(self):
"an index in your catalog"
return "%s %s" % (self.MyText1, self.MyText2)

def catalogObject(self):
"Catalog me"
self.MyCatalog.catalog_object(self, self.MyObjectID)

def uncatalogObject(self):
"Uncatalog me"
self.MyCatalog.uncatalog_object(self.MyObjectID)




Hope this helps,
Corey




___
Zope maillist  -  [EMAIL PROTECTED]
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 )




Re: [Zope] ZCatalog dynamic sites

2000-07-21 Thread Dieter Maurer

  I have a Zope site that uses MySQL to dynamically create some pages.
  What I want is the ability to search throughout the site, INCLUDING
  the pages that are database-driven. It seems to me that ZCatalog only=20
  finds items that exist *in zope*.
  
  Is it something ZCatalog can't do or am I missing anything obvious ?
ZCatalog catalogues objects.

Objects must help ZCatalog by providing attributes and/or
parameterless methods. When the object is indexed, ZCatalog
accesses the attributes/methods to obtain the terms the
object should be indexed for.
And the objects must be URL addressable,
because they are itentified inside the catalog by their URL.

ZCatalog can index any object that satisfies these
requirements.

You probably must work that your dynamic objects with database
contents do that.


Dieter

___
Zope maillist  -  [EMAIL PROTECTED]
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 )