[Zope-dev] BTreeFolder w/ Customizer support

2000-08-29 Thread Steve Alexander

Shane Hathaway wrote:

 Bill Anderson wrote:
  Any chance at a BTree Folder w/customizer support in the near future? :)
 
 It should be quite easy to do.  I vaguely recall Steve A or Steve S
 might have done it.

I want to include a BTreeFolder w/ Customizer support in the next 
release of DataSkinAddons.

If anyone's done one, and you're happy for it to be included in 
DataSkinAddons, please let me know.

Otherwise, I'll work on this later today.

I've just produced a BTreeDataSkin:

BTreeDataSkin is a DataSkin that is an ObjectManager.
The ObjectManager stores subobjects in a BTree that is directly in the
object (not stored in an attribute provider).
On __getattr__, subobject ids are searched before the datamanager is
asked to provide attributes.


--
Steve Alexander
Software Engineer
Cat-Box limited
http://www.cat-box.net








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




Re: [Zope-dev] New version of BTreeFolder

2000-08-29 Thread Kapil Thangavelu

Kapil Thangavelu wrote:
 
 Shane Hathaway wrote:

  BTW has anyone done any semi-formal speed tests?  It's rumored that a
  custom getattr in Python can cause a bit of a slowdown.  We could write
  a custom getattr in C to solve the problem.  But we don't want to do
  any premature optimization.
 
  Shane
 
 I'll work on some tests.
 
 Kapil


semi-formal test

i ran some basic tests comparing a btree folder against a folder. i'm
not sure about my testing methodology but here are the results. the test
code is at the end of this email. 

the first pair of numbers is a timed creation test for size xxx of DTML
Documents.

the second pair of numbers is a timed test for len(objectIds())

the third pair of numbers is a timed test for attribute access with a
call to 
int(dtmldoc.title_or_id()) # all the ids are stringed numbers

my test box is running mandrake 7.1 with 512 M ram, dual proc celerons
550s (oc'd)

some quick conclusions. the btree folder is slower on average for
creation by anywhere from 15-25% andt btree's __getattr is on average
almost twice as slow as the folder's getattr.


order folder followed by btreefolder

for size 100
0.0974419116974 :::0.126843929291
0.000378012657166 :::0.000354051589966
0.0101770162582 :::0.0186030864716

for size 100
0.0978569984436 :::0.125252962112
0.000376105308533 :::0.000353932380676
0.0101470947266 :::0.0185579061508

for size 500
0.52112698555 :::0.657492995262
0.00154399871826 :::0.00154197216034
0.0524510145187 :::0.0956329107285

for size 500
0.53660595417 :::0.714686989784
0.00154197216034 :::0.00157594680786
0.0532569885254 :::0.100463986397

for size 1000
1.11411702633 :::1.4010369
0.00302505493164 :::0.00306105613708
0.105547070503 :::0.193196058273

for size 1000
1.12388503551 :::1.58762395382
0.00370097160339 :::0.00381696224213
0.106634020805 :::0.194367051125

for size 2000
2.60056698322 :::3.20675897598
0.007483959198 :::0.00741696357727
0.216197967529 :::0.396993994713

for size 2000
2.64964604378 :::3.26421093941
0.0074850320816 :::0.00761103630066
0.214147925377 :::0.40997505188

for size 5000
9.50434195995 :::11.0002789497
0.0184400081635 :::0.018413901329
0.533676981926 :::0.997251987457

just to be fair i reversed the positions and
did a second set of runs with only 1 run per size as
the results were consistent with the first set.

for size 100
0.128319978714 :::0.10124707222
0.000413060188293 :::0.000383019447327
0.018816113472 :::0.0104240179062

for size 100
0.12813603878 :::0.101204037666
0.00040602684021 :::0.000380039215088
0.0188159942627 :::0.0105849504471

for size 500
0.681550979614 :::0.546862006187
0.00152194499969 :::0.00160706043243
0.0983099937439 :::0.0540620088577


for size 1000
1.47808301449 :::1.17385303974
0.00308799743652 :::0.00319290161133
0.197283029556 :::0.108732938766

for size 5000
11.1204429865 :::9.15097498894
0.015163064003 :::0.0150960683823
1.00954806805 :::0.535046935081


Despite this evidence. at size 5000, looking at the btreefolder contents
in the management screen was near instaneous while the folder took
almost a minute. based on the above evidence though that has more to do
with the interface than the underlying speed of the folder methods.

night.

Kapil

test code to follow.

external method


import time
import os
import Products.BTreeFolder

def btest(self, REQUEST, =None):
''' '''
if not : =100

results = []
bf = Products.BTreeFolder.BTreeFolder.BTreeFolder()
bf.id = 'btree_test_b'  
self._setObject(bf.id, bf)  

id = 'btree_test_f'
rf = self.manage_addFolder(id)

# creation test for completeness

stime = time.time()
for num in xrange():
self.btree_test_b.manage_addDTMLDocument(str(num))
etime = time.time()

result = etime-stime
#self.get_transaction().commit()

stime = time.time()
for num in xrange():
self.btree_test_f.manage_addDTMLDocument(str(num))
etime = time.time()

results.append(result, etime-stime)

# access test   
stime = time.time()
len(self.btree_test_b.objectIds())
etime = time.time() 
result = etime-stime

stime = time.time()
len(self.btree_test_f.objectIds())
etime = time.time()
results.append(result, etime-stime)

# iteration test
stime = time.time()
for oid, item in self.btree_test_b.objectItems():
int(item.title_or_id())
etime = time.time()
result=etime-stime

stime = time.time()
for oid, item in self.btree_test_f.objectItems():
int(item.title_or_id())
etime = time.time()
results.append(result, etime-stime)

return results

___
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts 

[Zope-dev] Help: mod_python+ZPublisher and authentication

2000-08-29 Thread Gilles Lavaux

Hello,

This is not exactly a Zope question, but I hope that some of you will be
able to help me:

I am using mod_python + ZPublisher + Ztemplate on a apache server and now I
would like to restrict the access of some
 pages served by the ZHandler.py.

How to do it??

Do I have to put a rewrite rule in apache? The Zhandler.py seams to reply
all the time a 200 code to apache, do I have
 to modify it to send back an 'Unauthorized' code??( I don't know how to
raise the 'Unauthorized' error from the python
 module I am publishing)



Thanks for any help


Gilles Lavaux



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




RE: [Zope-dev] Re: ANNOUNCE: Zope 2.2.1 released - breaks my zclass instances too.

2000-08-29 Thread Brian Lloyd

 Brian, the tranalyser reported a clean (old) data.fs and I 
 don't use any
 python base classes for any of my zclasses - however, in the interests
 of my own sanity, I'm pleased to report success with an old recipe - I
 started with a fresh Data.fs and cleaned out some cruft from 
 my Products
 folder. After removing all the stuff I'm not using now (ZopePTK and
 ZDConfera/ZDiscussions products in particular), I was able to 
 import my
 zclasses and then the major application folder - everything looks fine
 now and seems to work.
 
 Lesson may be that a Data.fs which works with an earlier zope version
 may fail when upgrading to 2.2.1 - if so, try 

No - thats not the lesson (at least not the right one)... It looks 
like something in the "cruft" didn't want to be unpickled in the 
new installation (most likely due to a missing piece - a required 
product or base class needed by a piece of cruft didn't get moved 
to the new install). A Data.fs from an earlier version should 
always work with a later version so long as all add-ons are 
replicated in the new installation.

Brian Lloyd[EMAIL PROTECTED]
Software Engineer  540.371.6909  
Digital Creations  http://www.digicool.com 



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




Re: [Zope-dev] New version of BTreeFolder

2000-08-29 Thread Shane Hathaway

Kapil Thangavelu wrote:
 semi-formal test
 
 i ran some basic tests comparing a btree folder against a folder. i'm
 not sure about my testing methodology but here are the results. the test
 code is at the end of this email.
 
 (snip)
 
 some quick conclusions. the btree folder is slower on average for
 creation by anywhere from 15-25% andt btree's __getattr is on average
 almost twice as slow as the folder's getattr.

I must say thank you!

Your results look very conclusive.  It would appear, then, that storing
the objects in a BTree actually slows down reads and writes
considerably.  And the only thing that needs to be improved about
folders is the user interface.

The problem with the current Folder UI, you see, is that each object is
loaded from the database every time you look at the folder contents
view.  Additionally, browsers have trouble rendering large tables. 
BTreeFolder gets the contents listing from the _objects attribute and
generates a simple list.  It's just lucky that all platforms I know of
can handle thousands of items in a simple list without any slowdown.

This provided us the data we needed for improving folders.  Thanks
again!

Shane

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




[Zope-dev] ZPatterns bug: Customizers don't rename well

2000-08-29 Thread Steve Alexander

ZPatterns 0-4-1snap1
Zope 2.2.1

To reproduce the error, do this:

  Create a Folder with Customizer support

  Give it a Customizer

  Rename that Customizer

  Press the "Customizers" tab in the folder


Zope Error

Error Type: AttributeError
Error Value: __customizerRegistry__

Traceback (innermost last):
  File /lib/python/ZPublisher/Publish.py, line 222, in publish_module
  File /lib/python/ZPublisher/Publish.py, line 187, in publish
  File /lib/python/Zope/__init__.py, line 221, in
zpublisher_exception_hook
  File /lib/python/ZPublisher/Publish.py, line 171, in publish
  File /lib/python/ZPublisher/mapply.py, line 160, in mapply
(Object: manage_main)
  File /lib/python/ZPublisher/Publish.py, line 112, in call_object
(Object: manage_main)
  File /lib/python/App/special_dtml.py, line 120, in __call__
(Object: manage_main)
(Info: /lib/python/Products/ZPatterns/www/PlugInGroup.dtml)
  File /lib/python/DocumentTemplate/DT_String.py, line 528, in __call__
(Object: manage_main)
  File /lib/python/App/special_dtml.py, line 120, in __call__
(Object: manage_below)
(Info: /lib/python/Products/ZPatterns/www/showCustomizers.dtml)
  File /lib/python/DocumentTemplate/DT_String.py, line 528, in __call__
(Object: manage_below)
  File /lib/python/DocumentTemplate/DT_In.py, line 630, in renderwob
(Object: manage_registry)
  File /lib/python/Products/ZPatterns/Customizers.py, line 63, in
manage_registry
AttributeError: (see above)


The error occurs because the rename method redirects to:

http://puffin.cat-box.net:7080/test/Customizers_

Pressing the "customizers" tab yields the url:

http://puffin.cat-box.net:7080/test/Customizers_/Customizers_/manage_workspace

--
Steve Alexander
Software Engineer
Cat-Box limited
http://www.cat-box.net

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




[Zope-dev] Caching a tree tag

2000-08-29 Thread Jeffrey Harris

Hello!

I've got a site set up using Zope, I'm very pleased with it for the most 
part, but I have some complicated threaded discussion pages that use the 
tree tag, and they're taking FOREVER to load.

I'm not completely certain which part of the system is taking so long.  My 
first question is, is there an easy way to profile python routines?  I 
don't know of a quick way, I'd love to hear suggestions.

The second question I have is about the tree tag.  I suspect that my pages 
are taking so long to render because my branches methods are pretty 
expensive.  One possibility for me is to optimize this code.  But I don't 
think this will really solve the problem.

What I'd like to do is cache the tree structure.  I don't want to cache the 
objects, just references to the nodes.  Would this take just a little 
tweaking of the zope internals, or a lot?  Again, I'd love any suggestions.

Finally, how much overhead do you get from the tree tag, relative to an in 
tag, if the branches method is cheap?  If I can't cache Zope's tree 
structure, I will probably make my own tree object storing references to 
the appropriate objects.  Would recursing over this object with an in tag 
give me any performance improvement?

Thanks!

In community,
Jeffrey Harris,
Skyhouse Consulting



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




[Zope-dev] CLIDAzope

2000-08-29 Thread Leonardo Kenji Shikida

how is the status of CLIDAzope ?
will we have it this year?

regards

Kenji

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




Re: [Zope-dev] Re: ANNOUNCE: Zope 2.2.1 released - breaks my zclass instances too.

2000-08-29 Thread Dr. Ross Lazarus

I'm a little confused - which is not unusual, so please bear with me.

I'm absolutely sure that NONE of the things which were broken in the
original Data.fs had the slightest/faintest connection with any of the
products I expunged. It was removing the cruft alone which fixed the
problem. 

Doesn't this (and the other episode reported by Andy) raise the issue of
what we can do to ensure that a broken product or piece of a product
doesn't stop a healthy product and its instances (completely independent
in the sense of not using any of the broken product's base classes or
classes) from working? 

The instances which were broken were multi-level zclasses which included
ObjectManager and CatalogAware in their base classes. The relevant
products were entirely healthy. The things I got rid of included two
broken things which I never tried to fix (ZDConfera, ZDiscussions) plus
some left over stuff (ZopePTK, PTKBase, PTKDemo, Wizard, Membership,
LoginManager and a few other bits and pieces which I didn't need
although they didn't appear broken..) - none of which had any connection
to the broken zclasses in terms that I can understand - other than
sharing/breaking an otherwise healthy ZODB.


Brian Lloyd wrote:

 
  Lesson may be that a Data.fs which works with an earlier zope version
  may fail when upgrading to 2.2.1 - if so, try
 
 No - thats not the lesson (at least not the right one)... It looks
 like something in the "cruft" didn't want to be unpickled in the
 new installation (most likely due to a missing piece - a required
 product or base class needed by a piece of cruft didn't get moved
 to the new install). A Data.fs from an earlier version should
 always work with a later version so long as all add-ons are
 replicated in the new installation.
 
 Brian Lloyd[EMAIL PROTECTED]
 Software Engineer  540.371.6909
 Digital Creations  http://www.digicool.com

-- 

Dr Ross Lazarus
Associate Professor and Sub-Dean for Information Technology
Faculty of Medicine, Room 114, A27, University of Sydney,
Camperdown, NSW 2006, Australia
Tel: (+61 2) 93514429   Mobile: +61414872482  
Fax: (+61 2) 93516646   Email: [EMAIL PROTECTED]

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




[Zope-dev] Redirection and Authentication

2000-08-29 Thread Christian Scholz

Hi!

I had a little problem and just wanted to ask if someone knows an explanation..

The goal: 
I want to show a list of newsitems to the user. If an administrator wants
to change it he should be able to log in and see the same list but with edit-
buttons.

The setup is:

/folder/list- public accessible dtml method which show the list
/folder/edit- protected dtml method

The edit method is protected so that the login requester pops up and asks
for a passwort.
Originally I was simply redirecting back to the list page inside the edit document by

dtml-call "RESPONSE.redirect('./list')"

(the only line in the document)

In list I then check for a login with

dtml-if "REQUEST['AUTHENTICATED_USER'].has_permission('whatever',this())"
.. show edit button here ...
/dtml-if

The problem is now that after the Redirect AUTHENTICATED_USER is again set to
Anonymous (which I tested by printing AUTHENTICATED_USER). If I do no redirect
but put a normal link back to the list document, everything works as expected
(thus showing the edit button).

So has anyone an explanation? (Version is 2.2.0)
(right now I directly include the list again in the edit document by
using dtml-var. Works for this little thing but I assume this only being
a workaround..)

(I also remember having some strange problems with a redirect from python some
time ago. Back then it did not commit the database transaction in Oracle. After
putting a get_transaction().commit() before the redirect made things work again.)

cheers,
  Christian

-- 
Christian Scholz   MrTopf@IRC
COM.lounge  http://comlounge.net/
communication  design   [EMAIL PROTECTED]

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




Re: [Zope-dev] Enhanced permissions for DTMLMethod and DTMLDocument?

2000-08-29 Thread R. David Murray

On Tue, 29 Aug 2000, Christopher J. Kucera wrote:
 I've got a question about permissions of DTMLMethods and DTMLDocuments.  It
 seems to me that if you've given a role the "View management screens"
 permission, any user with that role should be able to view the source code
 for Methods and Documents.  Is there any concurrence here?

No. grin

 I can understand if you don't want that kind of feature bundled in with
 "View management screens," but if that's the case then I think there should
 be a different role that grants these permissions.

My understanding (which may be wrong!) is that 'View management screens'
gives one permission (by convention?) to use 'manage_' methods.  *Which*
manage methods you can use (or even see on the management tabs) is
controlled by other permissions.  So if such an auxiliarry permission
for viewing the contents doesn't exist, it probably would be
useful to create it.  But I don't think view management screens
should automatically give you access to the source code.

--RDM


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




[Zope-dev] Re: [Zope] dtml-tree question

2000-08-29 Thread Hugo Ramos

- Original Message -
From: "Dieter Maurer" [EMAIL PROTECTED]
To: "Hugo Ramos" [EMAIL PROTECTED]
Cc: "ZOPE" [EMAIL PROTECTED]; "EUROZOPE" [EMAIL PROTECTED]
Sent: Tuesday, August 29, 2000 10:22 PM
Subject: Re: [Zope] dtml-tree question


 Hugo Ramos writes:
   Is there a way to use my own self made '+' icon in a tree tag?
   I'dd like to use my own icon only IF i want to... and not change the
python
   source to use my own icon all the time!
 The code is partially there, but incomplete and commented out.

 If you do not mind other extensions as well, I could provide
 a TreeTag patch for several extensions, including the
 icon customization.


hello Dieter,

I've tryied to hack the treetag source already... but there's some kind of
bug in it:

line 566 (original source):
s.append([id,[]])

Why is this trying to append to 's' when 's' has become a tupple somewhere
before this line???... tupples don't accept append!!

This bug is really making me crazy... because it makes an error when
clicking the + icon in a dtml-tree that I must use...



Another thing:
I hacked the source of treetag.py to accept 2 more parameters in the
dtml-tree... icon_mi and icon_pl

The hacked source is in the attach.
Changes go from line 411-427. Of course i defined the 2 new parameters as
None in the file top.

Please somebody help me... I'm running out of ideias...

regards

=
Hugo Ramos - [EMAIL PROTECTED]
ZopersORG - http://www.zopers.org
=
Do not meddle in the affairs of programmers, for they are easy to annoy,
and have all the source code!!!


##
# 
# Zope Public License (ZPL) Version 1.0
# -
# 
# Copyright (c) Digital Creations.  All rights reserved.
# 
# This license has been certified as Open Source(tm).
# 
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
# met:
# 
# 1. Redistributions in source code must retain the above copyright
#notice, this list of conditions, and the following disclaimer.
# 
# 2. Redistributions in binary form must reproduce the above copyright
#notice, this list of conditions, and the following disclaimer in
#the documentation and/or other materials provided with the
#distribution.
# 
# 3. Digital Creations requests that attribution be given to Zope
#in any manner possible. Zope includes a "Powered by Zope"
#button that is installed by default. While it is not a license
#violation to remove this button, it is requested that the
#attribution remain. A significant investment has been put
#into Zope, and this effort will continue if the Zope community
#continues to grow. This is one way to assure that growth.
# 
# 4. All advertising materials and documentation mentioning
#features derived from or use of this software must display
#the following acknowledgement:
# 
#  "This product includes software developed by Digital Creations
#  for use in the Z Object Publishing Environment
#  (http://www.zope.org/)."
# 
#In the event that the product being advertised includes an
#intact Zope distribution (with copyright and license included)
#then this clause is waived.
# 
# 5. Names associated with Zope or Digital Creations must not be used to
#endorse or promote products derived from this software without
#prior written permission from Digital Creations.
# 
# 6. Modified redistributions of any form whatsoever must retain
#the following acknowledgment:
# 
#  "This product includes software developed by Digital Creations
#  for use in the Z Object Publishing Environment
#  (http://www.zope.org/)."
# 
#Intact (re-)distributions of any official Zope release do not
#require an external acknowledgement.
# 
# 7. Modifications are encouraged but must be packaged separately as
#patches to official Zope releases.  Distributions that do not
#clearly separate the patches from the original work must be clearly
#labeled as unofficial distributions.  Modifications which do not
#carry the name Zope may be packaged in any form, as long as they
#conform to all of the clauses above.
# 
# 
# Disclaimer
# 
#   THIS SOFTWARE IS PROVIDED BY DIGITAL CREATIONS ``AS IS'' AND ANY
#   EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
#   IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
#   PURPOSE ARE DISCLAIMED.  IN NO EVENT SHALL DIGITAL CREATIONS OR ITS
#   CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
#   SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
#   LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
#   USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
#   ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
#   OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
#  

[Zope] ANN: NewsCenter0.0.8

2000-08-29 Thread Kapil Thangavelu


Link:
http://www.zope.org/Members/k_vertigo/ZopeProducts/NewsCenter/index_html

Changes:

ZCatalog Searches
PyXML distro download link updated
Minor fixes.

Caveats:

IF YOU"RE USING ZOPE 2.2.1 - ZCatalog now generates log messages for
attempts to uncatalog items not in the catalog. The update methods tries
to uncatalog before updating and cataloging, otherwise older news items
might still exist in the catalog.  hence you will see lots of catalog
errors fly by the when a channel is initially published. this is
harmless but annoying.

Testing:
I tested it on a fresh compile of 2.2.1 and retrieved an ocs channel
list, rss channels, published/unpublished them, and searched the
channels.


Kapil

___
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] Wanted: Procedure to produce binary release from source release

2000-08-29 Thread Soren Roug

I support a couple of UNIX platforms, that are DC doesn't provide binary
releases for. So what I would like to do is roll my own binary release
and then send it to my system administrators.

However, trying to do this from the source release is no easy task, so I
would like to know if DC has a script that does this automatically and
are they willing to share it? Preferably downloadable from www.zope.org.

Best regards

Soren Roug

___
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] Where is news section how-to?

2000-08-29 Thread Kapil Thangavelu

Radim Gelner wrote:
 
 Hello,
 
 few weeks ago, on Zope site I came across a document describing how to
 build news section with features like displaying with five most recent
 items from a folder, etc.
 
 But now I can't recall, where it was. Can someone point me in a right
 direction.

something along the lines of 

dtml-in "objectValues(['NewsItem', 'DTML Document'])
sort=bobobase_modification_time reverse size=5

dtml-with sequence-item
a href="dtml-var.absolute_url;"dtml-var title_or_id/a
/dtml-with

/dtml-in


Kapil

___
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] List of object's name in a ZClass

2000-08-29 Thread Kapil Thangavelu

Vincent wrote:
 
Part 1.1Type: Plain Text (text/plain)
Encoding: 7bit

from your heirarchy ZClass B is contained in zclass A. and you're
looking for contained instances which is easy.

the dtml method in a (assuming a inherits from objectmanager)

ul
dtml-in "objectIds(['ZCLASSB_METATYPE'])"
lidtml-var sequence-item/li
/dtml-in
ul

___
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] Help: mod_python+ZPublisher and authentication

2000-08-29 Thread Gilles Lavaux

Hello,

This is not exactly a Zope question, but I hope that some of you will be
able to help me:

I am using mod_python + ZPublisher + Ztemplate on a apache server and now I
would like to restrict the access of some
 pages served by the ZHandler.py.

How to do it??

Do I have to put a rewrite rule in apache? The Zhandler.py seams to reply
all the time a 200 code to apache, do I have
 to modify it to send back an 'Unauthorized' code??( I don't know how to
raise the 'Unauthorized' error from the python
 module I am publishing)



Thanks for any help


Gilles Lavaux



___
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] Question relating to a zope product 'Tracker': email problems

2000-08-29 Thread Julian Harris

Hi all

I'm having fun with Tracker (a Zope product) -- certainly it's looking to be
a very useful tool for us.

But I'm having a problem submitting issues. I get this error when trying to
submit an issue:

Error Type: SMTPSenderRefused
Error Value: (555, 'syntax error (#5.5.4)', '[EMAIL PROTECTED]')


We sniffed the header and it seems that the mail line below is the culprit:

mail FROM: [EMAIL PROTECTED]

(what you can't see is that there's a rogue space after [EMAIL PROTECTED]
which causes the syntax error on our server)

Tracker uses the smtp libraries in Zope. Anyone encountered this kind of
problem before? Any suggestions about how to fix this? Either in code, or
what I have to do to configure it differently...?

thanks so much in advance!

PS if I wanted to make a change to the source on my machine, do I have to
compile it? I see these PYC files everywhere but I thought Python was an
interpreted language? How would I make a change if I found that I had to
tweak the code a little?

--
Phone: +34-93-508-8550 or 667-914-832 if urgent


___
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] Problem with SiteAccess 1.0.1

2000-08-29 Thread William JOYE

 From: William JOYE [EMAIL PROTECTED]
  I have some minor problems with SiteAccess 1.0.1 and Zope 
 2.1.6 + hotfix.
 
  1. When click on the folder that contain SiteRoot, I need 
 to enter again
  login and password. Why ?
 
 Most likely, because you have a Base set in your SiteRoot 
 that differs from
 the base URL you had logged into.  Your browser will not send your
 authentication information to a URL with a different host name.

In my Zope root directory, I have created a folder by site. So I have
folders : Site1, Site2,... I have included in each folder a Siteroot object
with the following parameters :
For Site1 (subfolder site1) :
Base: http://www.site1.com
Path: /

For Site2 (subfolder site2) :
Base: http://www.site2.com
Path: /
 
And so on...

In the Apache configuration, I have also set a rewrite rule for each domain
like this :

VirtualHost xxx.xxx.xxx.xxx

ServerName www.site1.com


RewriteEngine on

RewriteCond %{HTTP:Authorization}  ^(.*)

RewriteRule ^/(.*) /home/httpd/cgi-bin/Zope/Site1/$1
[e=HTTP_CGI_AUTHORIZATION:%1,t=application/x-httpd-cgi,l]
/VirtualHost

Is it correct ?

I have another strange behavior. When I copy an object from Site1 folder, I
can't past it in the Site2 folder. Is it normal ?

___
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] ZCatalog and foreign characters

2000-08-29 Thread Radim Gelner

Hello,

is it possible to make ZCatalog work correctly with words containing
characters other then those given in ISO-8859-1.

Now, it reports "no found" for all such queries even when these words
are present inside the documents on site.


Thank you,

Radim 

___
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] CatalogAware

2000-08-29 Thread Yapo Sébastien



Hi !

I useobjects from a class which inherits from 
CatalogAware.
The objects index themselves into the ZCatalog but 
I get strange results when I try to search in this ZCatalog... The problem is 
solved after reindexing the object via the reindex_object() method but this 
works only for manage_edit ... I can't index my object properly in the 
manage_add method (I get the same problem)
Newlyindexed objects seem to be added to the 
ZCatalog with the indexes from the previous cataloged object (or something like 
that)

Is there a bug I should be 'awared' to or am I 
doing something the wrong way ?

 
SY


Re: [Zope] Patch for Netscape 'tree' bug?

2000-08-29 Thread Tony McDonald

At 10:09 am +0200 18/8/00, Pierre-Julien Grizel wrote:
** Reply to message from [EMAIL PROTECTED] on Fri, 18 Aug 2000
04:36:34 +0100 (BST)

[Hoping you didn't receive my previous message.]

If you talk about the www.xlogx.org patch, I've made the site available again,
you can find it at http://www.xlogx.org/Zope/TreeTag.query_expr.patch
Be careful, it has a problem with trees deeper than 3 levels, I think it's not
a big work to correct this but I hate html and I don't have time to do it. I
should take time those weeks, but I can't promise

Regards,

Thanks Pierre, we've downloaded it and installed it. It looks better, 
but as you say, it gets confused with trees deeper than 3 levels. We 
don't have time to look at the code to try and fix it at the moment, 
but thanks for your help. We'll probably stick with 3 level trees for 
the time being.

There's been some talk on the Zope list about rewriting the tree tag 
somewhat. Can I make a plea that this is considered too?

cheers
tone.

--
Dr Tony McDonald,  FMCC, Networked Learning Environments Project 
http://nle.ncl.ac.uk/
The Medical School, Newcastle University Tel: +44 191 222 5116
Fingerprint: 3450 876D FA41 B926 D3DD  F8C3 F2D0 C3B9 8B38 18A2

___
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] Where is news section how-to?

2000-08-29 Thread J. Atwood

It is also in the Tutorial.

Enjoy,
J

 From: Kapil Thangavelu [EMAIL PROTECTED]
 Date: Mon, 28 Aug 2000 20:55:34 -0700
 To: Radim Gelner [EMAIL PROTECTED]
 Cc: [EMAIL PROTECTED]
 Subject: Re: [Zope] Where is news section how-to?
 
 Radim Gelner wrote:
 
 Hello,
 
 few weeks ago, on Zope site I came across a document describing how to
 build news section with features like displaying with five most recent
 items from a folder, etc.
 
 But now I can't recall, where it was. Can someone point me in a right
 direction.
 
 something along the lines of
 
 dtml-in "objectValues(['NewsItem', 'DTML Document'])
 sort=bobobase_modification_time reverse size=5
 
 dtml-with sequence-item
 a href="dtml-var.absolute_url;"dtml-var title_or_id/a
 /dtml-with
 
 /dtml-in
 
 
 Kapil
 
 ___
 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 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] REQUEST.form.set ???

2000-08-29 Thread Brian Withun


Is it possible for DTML to create or modify a form value?

I understand that REQUEST.form is a dictionary, but I cannot
seem to add dictionary elements.

I've tried

dtml-call expr="REQUEST.form['test']='value'"
dtml-call expr='REQUEST.form["test"]="value"'
dtml-call expr="REQUEST.form.set('test','value')"

but none of them work.

What am I doing wrong here?


Brian Withun

___
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] ZCatalog: Time for a new look?

2000-08-29 Thread Chris Withers

Radim Gelner wrote:
 is it possible to make ZCatalog work correctly with words containing
 characters other then those given in ISO-8859-1.

With some hacking, maybe :S

Is it just me or is the Catalog and the BTree implementation gettign a
little long in the tooth?

cheers,

Chris

___
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] Re. Advice for new zope installation

2000-08-29 Thread Chris Withers

"Spicklemire, Jerry" wrote:
 Zope does do some logging, but I don't know much about that.
 Maybe someone could answer?
 
 - any advice about migrating an existing site ?

Well Zope produces logs, which are in a standard format apparently.
Also, if you run Zope behind Apache using ProxyPass or PCGI, then you
get Apache's logging too :-)

cheers,

Chris

___
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] ZClass -- Product

2000-08-29 Thread Chris Withers

"Nestor A. Diaz L." wrote:
 I want to know if there is any utility that let translate a ZClass to a
 Product, i'm worry using the frames based interface, so i'm considering to
 switch to a Product a utility that let that would be usefull howevere a
 HOWTO on doing this would be fine.

Not sure abotu what you're asking...
If you want to convert your ZClass-based product to a pythno based
product so you don't have to do development through the managemetn
interface, then the answer is sorry, no you can't.

However, if it's just the through-the-web part of developing a
ZClass-based product that's causing you problems, have you considered
editing the ZClasses using FTP or WebDAV?

cheers,

Chris

___
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] CatalogAware Problems?

2000-08-29 Thread Chris Withers

 Yapo Sébastien wrote:
 Is there a bug I should be 'awared' to or am I doing something the
 wrong way ?

Maybe if you said what the bug was and included a traceback, more people
would be able to help?

Also, posting in HTML means a lot of people can't read what you post...

cheers,

Chris

___
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] CatalogAware Problems?

2000-08-29 Thread Bill Anderson

Chris Withers wrote:
 
  Yapo Sébastien wrote:
  Is there a bug I should be 'awared' to or am I doing something the
  wrong way ?
 
 Maybe if you said what the bug was and included a traceback, more people
 would be able to help?
 
 Also, posting in HTML means a lot of people can't read what you post...

And of those of us who can, many won't.

--
Do not meddle in the affairs of sysadmins, for they are easy to annoy,
and have the root password.

___
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] REQUEST.form.set ???

2000-08-29 Thread Daren Lunsford

maybe this will help:

dtml-call "REQUEST.set('lname',REQUEST.form['Last_Name'])"


 From: "Brian Withun" [EMAIL PROTECTED]
 Date: Tue, 29 Aug 2000 12:02:42 -0400
 To: "Zope mailing list" [EMAIL PROTECTED]
 Subject: [Zope] REQUEST.form.set ???
 
 
 Is it possible for DTML to create or modify a form value?
 
 I understand that REQUEST.form is a dictionary, but I cannot
 seem to add dictionary elements.
 
 I've tried
 
 dtml-call expr="REQUEST.form['test']='value'"
 dtml-call expr='REQUEST.form["test"]="value"'
 dtml-call expr="REQUEST.form.set('test','value')"
 
 but none of them work.
 
 What am I doing wrong here?
 
 
 Brian Withun
 
 ___
 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 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] SQL question...I think

2000-08-29 Thread George

I know nothing about sql so forgive me this idiotic question:-) All I
know so far I had learnt from ZOPE tutorials and HOW-TO's. Here is the
question:
I have a database connection working. I created a couple of tables and
filled them up with stuff. I know how to insert data in to the table,
search and such. I can not find any info on how to embed the data in my
dtml-html code to show it to the world. I know how to create a form for
the visitors to search for the stuff. What I need is simply include some
data in my documents without any interaction.
If I have for instance a table that contains a columns: product_id,
price, weight. How do I display the values one by one? (not the whole
table) I have some data in the table that I do not want to display on
every page. Can I choose just one row and column and display just that
data in that single cell? Say only the price of the product number
1?

Regards,
George


___
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] Announce: Squishdot 0.7.0 now available!

2000-08-29 Thread Chris Withers

Squishdot 0.7.0 is now available from 
http://www.zope.org/Members/chrisw/Squishdot/
http://www.squishdot.org/Download/Squishdot

The following changes were made:

 - Changes to the Demo Sites and Squishdot core to make them Zope 2.2 
   compatible.

 - Updated Cataloging to use the Traversal Interface. This means 0.7.0 
   will not work with versions of Zope earlier than 2.2.0!

 - Added in some html_quoting. The Demo Sites could do with a lot more.

 - Some small changes to the management screens.

I'm not 100% happy about how the 2.2 support was achieved, so expect a
0.7.1 release in the near future.

If you run into problems, remember Squishdot has a mailing list at 
eGroups and a bug collector on SourceForge.

cheers,

Chris

___
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 and foreign characters

2000-08-29 Thread Aleksander Salwa


On Tue, 29 Aug 2000, Radim Gelner wrote:

 is it possible to make ZCatalog work correctly with words containing
 characters other then those given in ISO-8859-1.
 

Yes, I did it very simply.
You have to patch file lib/python/SearchIndex/Splitter.c
very slightly.

Just add line:
#include locale.h
somewhere beside include lines (~ line 86)

and line:
setlocale(LC_ALL, "pl_PL");
in function initSplitter, line no. ~493.

It works for polish characters, and all other characters in iso-8859-2
set, so it should satisfy you :)

P.S. You need to compile it, of course:
 gcc --shared -O2 Splitter.c -I/usr/include/python1.5 -o Splitter
 (include path for RH Linux)
 Probably you will need some include files from source distribution.


[EMAIL PROTECTED]

/--\
| `long long long' is too long for GCC |
\--/


___
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] SSL and PGP

2000-08-29 Thread Diego Rodrigo Neufert

Hi...

Anyone know how to send a pgp cryped email in zope? (using dtml-sendmail or
anything else)

and

How to run a SSL server with ZServer?

Thanks...

-- 
---
Diego Rodrigo Neufert
-webmaster
---
(Magic Web Design)
(email) ([EMAIL PROTECTED])
(curitiba) (pr)

___
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 Python edit debug cycle

2000-08-29 Thread Chui Tey


"Phlip" [EMAIL PROTECTED] wrote in message
news:8oefpc$ve8$[EMAIL PROTECTED]...
 Newsgroupies.

 I installed ZOPE on Win32, and noticed it came with a bunch of
 "Products"; each a kind of "soft driver" written in some language
 (typically Python) to drive the ZObject space  build Web pages.

 Then I tried to edit a py file and see the new output. I had to use
 this sequence to see my tiny change:

 make the change
 save the change
 Stop the ZOPE service
 Start the ZOPE service
 Refresh the ZOPE Web page
 Inspect the change.

 If I had a syntax error, ZOPE throws it away and I never get to read
 it.


Tips:
#1. Start with -D option
#2. Use the PythonWin to run your changes through a tab nanny. (Side note:
edit.com messes up the tabs in the python code badly, use notepad if you
really have to), before restarting.
#3. Run from command line instead of a service
#4. just before where you changed the python code, insert
  import pdb
  pdb.set_trace()
  Have a look through the python debugger docos if you're not familiar.
This way you can step through your code.
  Setting breakpoints? download the latest pdb.py/bdb.py from
sourceforge, otherwise setting breakpoints is hard.
#5. you might be able to reload modules if your changes are small.

 The inner question: How, in ZOPE land, do you ask it to refresh its
 concepts of all the Python files without stopping and restarting the
 service?

 The outer question: What does a healthy edit/debug cycle look
 like?


#1. Get as much of your code working without Zope first.
#2. Fix as much code as you can before restarting. With Zope, really you
lose a lot of the interactivity in debugging code the python way.

 --
  Phlip
 === http://users.deltanet.com/~tegan/home.html ===


 Sent via Deja.com http://www.deja.com/
 Before you buy.

I've copied this in to the Zope.org mailing list. See you there!





___
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] ZServer stepping on Content-Type and Content-Length?

2000-08-29 Thread Dieter Maurer

Jeff Hoffman writes:
  
  In the index_html method, I have:
  
RESPONSE.setHeader('Content-Type', 'video/foo')
RESPONSE.setHeader('Content-Length', 1212)
  
  However, when I telnet to my web port and do:
  
HEAD /path/to/myfile.mpg HTTP/1.0
  
  I get:
  
Content-Type: video/mpeg
Content-Length: 0

The problem is, that a HEAD request does not execute
"index_html".
Instead, the "HEAD" method from "webdav.Resource" is
called.
It uses a "content_type" and "get_size" attribute/method
to set the "Content-Type" and "Content-Length" HTTP header.
If there is no "content_type" attribute/method, the
content type is guessed (via "mimetypes.guess_type").
If there is no "get_size", the "Content-Length" is 0.


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 )




Re: [Zope] Showing the name of a file-type form variable

2000-08-29 Thread Dieter Maurer

Jean Jordaan writes:
tdinput type="file" 
   name="file"
   dtml-if file value="dtml-var "file"" /dtml-if
   /td 
  
  Which returns::
  
ZPublisher.HTTPRequest.FileUpload instance at 131dc48
This is a perfect receipt where you should look for information:

[Zope/lib/python/]ZPublisher/HTTPRequest.FileUpload

You will find there:

File upload objects

File upload objects are used to represent file-uploaded data.

File upload objects can be used just like files.

In addition, they have a 'headers' attribute that is a dictionary
containing the file-upload headers, and a 'filename' attribute
containing the name of the uploaded file.

Consequently, you will use

dtml-var "file.filename"


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 )




Re: [Zope] How to get URL of folder (name unknown) with a certain property?

2000-08-29 Thread Dieter Maurer

Tim Hicks writes:
  I am trying to figure out how to get hold of the URL (using
  absolute_url I presume) of a folder with a property called
  "sehs_root_folder" set to "yes".
Have a look at "ZopeFind" (it is the function implementing
Zope's "find" tab).
It is documented in the Object Reference (-- zdp.zope.org),
maybe in the Zope 2.2 help system, too.

You need to use a relatively new Zope (2.2.1), because
older Zope installations raise unjustified "Unauthorized"
exceptions due to a bug in "ZopeFind".


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 )




Re: [Zope] unauthorized when accessing /manage in zope 2.2.1

2000-08-29 Thread Dieter Maurer

Philipp Dunkel writes:
  I have a Zope Product that makes use of different nested classes.
  When I create an instance of this product I always get an
  "unauthorized" error when clicking the instance in the management interface
  (=accessing instance/manage)
  even if I am logged in as a manager or superuser.
Looks like a Zope bug.

However, you must at least include the traceback in order for us to
say more. Probably, you must even package your Zope Product
and give it away, such that someone of us can analyse
your problem in detail.


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 )




Re: [Zope] Problem with SiteAccess 1.0.1

2000-08-29 Thread Dieter Maurer

William JOYE writes:
  I have some minor problems with SiteAccess 1.0.1 and Zope 2.1.6 + hotfix.
  
  1. When click on the folder that contain SiteRoot, I need to enter again
  login and password. Why ?
  2. When I delete an object, I have always an script error message. Why ?

We use SiteAccess 1.0.1 with Zope 2.1.6 and do not see
your problems.

I know, this does not answer your questions,
but it may give you hope that the problem is not in SiteAccess
per se, but in the way you are using it.


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 )




Re: [Zope] Advice for new zope installation

2000-08-29 Thread Dieter Maurer

Henk Schets writes:
  After reading all the info about zope, I am very impressed with the
  possibilities it can deliver.  However, before I migrate our existing site,
  I need to be certain about certain topics :
  - how easy and reliably can I manage my virtual hosts (about 8 sites
  right now) ? Very important.
You probably will need a Zope product called SiteAccess.

With "SiteAccess" alone, virtual hosting would have been
a matter of about 1/2 an hour.

With Apache (ProxyPass) and SiteAccess, it was a matter of about
1 day. This should now be a matter of parts of an hour, too,
because a contributor wrote a HowTo, how to patch Apache
to let it propagate HOST information.

  - how stable is Zope regarding to Apache on Linux ?
Sometimes, images must be forced with a SHIFT-reload to
be shown correctly. I do not know of other problems.

  - we have a MySql database, is it easy to connect with Zope ?
Yes. Install MySQLDA. Then it is as easy to connect to it
as it is to connect to any other relational database:
add a connection object to a folder.

  - can I access the Zope internal database with e.g. ODBC ?
No.

But you can access it via HTTP, FTP, Webdav, XML-RPC and
soon via XPath.

  - can I use log analyzers to get some statistics about our site ?
Zope's logfiles are compatible with (e.g.) logs written by Apache

  - any advice about migrating an existing site ?
Where do you come from?
What special features do you use/need?
What techniques do you use now? How many script do you have?



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 )




Re: [Zope] SSL and PGP

2000-08-29 Thread Terry Kerr

We have done this in our Etailer product...grab the source and take a look...
http://e-tailer.adroit.net/.  Basically we just pipe the string to be encrypted
to the gnu pgp program on a linux box.  Take a look at
http://www.pgpi.org/products/gnu/gpg/.

terry


Diego Rodrigo Neufert wrote:

 Hi...

 Anyone know how to send a pgp cryped email in zope? (using dtml-sendmail or
 anything else)

 and

 How to run a SSL server with ZServer?

 Thanks...

 --
 ---
 Diego Rodrigo Neufert
 -webmaster
 ---
 (Magic Web Design)
 (email) ([EMAIL PROTECTED])
 (curitiba) (pr)

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

--
Terry Kerr ([EMAIL PROTECTED])
Adroit Internet Solutions Pty Ltd (www.adroit.net)
Phone:   +613 9563 4461
Fax: +613 9563 3856
Mobile:  +61 414 938 124
ICQ: 79303381




___
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] [ANN] FSSession-0-4-2

2000-08-29 Thread Pavlos Christoforou

Hello Zopistas

FSSession 0-4-2 is available at:
http://www.zope.org/Members/gaaros/FSSession 

FSSession 0-4-2 corrects a
bug on Windows platforms where os.rename fails if the renamed file already
exists. This version has also been tested under many "unusual" situations
(calling FSSession twice, two users having the same SessionUID) and it
seems to be very robust.

Regards

Pavlos


___
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] REQUEST.form.set ???

2000-08-29 Thread Dieter Maurer

Brian Withun writes:
  Is it possible for DTML to create or modify a form value?
It is possible to extend any dictionary, especially
"REQUEST.form". You use the dictionary "update" method
as in

dtml-call "REQUEST.form.update({'a':1, 'b':2})"

It will, however, not work as you might expect.
This is because the DTML namespace *does not* look into "REQUEST.form"
but into the dictionary "REQUEST.other".
During "REQUEST" construction, the "other" dictionary is updated
with the "form" dictionary. Therefore, you see form variables, too,
in the DTML namespace. However, later updates to "REQUEST.form"
are not automatically propagated to "REQUEST.other" (and
therefore not seen via the DTML namespace).

You can use
dtml-call "REQUEST.other.update({'a':1, 'b':2})"

or (as someone else suggested) "REQUEST.set".



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 )




Re: [Zope] ZCatalog and foreign characters

2000-08-29 Thread Dieter Maurer

Radim Gelner writes:
  is it possible to make ZCatalog work correctly with words containing
  characters other then those given in ISO-8859-1.
  
  Now, it reports "no found" for all such queries even when these words
  are present inside the documents on site.
I have made a very crude patch to "splitter.c" which lets it
treat every non-ascii character as a letter.

Obviously, this is not correct. It may include punctution into
words. This will lead to not find the words unless searched for
with the exact same punctuation.
Furthermore, non-ascii letters are not translated to lowercase.

Up to now, it gives acceptable results for us.
However, we did not yet make stress tests.

For a correct solution, splitter must be informed about
the encoding and a unicode letter classification and
case transformation must be applied.


If you work with a fixed locale, you can use the "-L" switch
to inform Zope about your locale. Then the splitter should
work correctly (for your locale).



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 )




Re: [Zope] SQL question...I think

2000-08-29 Thread Dieter Maurer

George writes:
  
  I know how to insert data in to the table,
  search and such. I can not find any info on how to embed the data in my
  dtml-html code to show it to the world.
Because, you can already search, you do already embed data in
dtml-html to show it to the world.
You just do not yet realized it

Okay, one step further:

 * In your "Available Objects", you will find an entry
   Z Search Interface.

   Add it to a folder!

   It will ask for a connection id, and id for the search form
   and the report.

 * The report presents search results to the world.
   It is a DTML method.
   Look at it, look at the DTML documentation,
   try to understand "dtml-in" and its parameters.

 * Change the report by removing columns (the columns, you
   do not want to show).

 * Play with the "size" and the "orphan" (these are 
   dtml-in arguments).

 * If you still do not yet get, what you want
   (then you will already have high requirements),
   then notice the following facts:

- the result of an Z SQL method behaves like a sequence

- "_.len" gives its length, i.e. the number of hits

- "...[i]" gives you the "i"th hit

- each hit behaves as an object with the columns as attributes

   Do not be frustrated, if you do not get this handled at the
   first trial.


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 )




Re: [Zope] CatalogAware

2000-08-29 Thread Dieter Maurer

Yapo =?ISO-8859-1?Q?S=E9bastien?= writes:
  I use objects from a class which inherits from CatalogAware.
  The objects index themselves into the ZCatalog but I get strange results =
  when I try to search in this ZCatalog... The problem is solved after =
  reindexing the object via the reindex_object() method but this works =
  only for manage_edit ... I can't index my object properly in the =
  manage_add method (I get the same problem)
This is a bug, I recently found in "GlobbingLexicon".
It may be, too, in a normal "Lexicon".

The collector (URL:http://classic.zope.org/Collector) contains
a patch for "GlobbingLexicon".
The patch is applied in Zope 2.2.1.


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 )




[Zope] FTP crashing Zope?

2000-08-29 Thread Dario Lopez-Kästen

Hello!

I have latest Zope, buitl from source on a RedHat 6.2 machine.

Using FTP Explorer I crashed (killed) my Zope instance while ftping in to
port 8021. This was achieved by not setting FTP Explorer to use PASSIVe
connections. Using Passive it works like a charm.

Is this a bug in latest Zope (2.2.1) or is this expected behaviour? If, the
latter is the case, what can I do to a) turn off FTP access, b) make sure
that my Zope is up and running automagically after a crash?

Thnx

/Dario



___
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] How to logout users when using LoginManager?

2000-08-29 Thread Brad Clements

I've searched the zope website for tips on how to truly logout users, but I 
can't find any information.

I'm using LoginManager, with GenericUserFolder. I see mention of 
cookie auth methods, but I have no idea how to use this. So, I'm using 
basic auth (I assume).

Can anyone share some tips on how to logout users from a web page, 
using cookies or otherwise, allowing them to relogin as another user 
without having to quit/start their browser?

Thanks..


Brad Clements,[EMAIL PROTECTED]   (315)268-1000
http://www.murkworks.com  (315)268-9812 Fax
netmeeting: ils://ils.murkworks.com   AOL-IM: BKClements

___
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] ZClass -- Product

2000-08-29 Thread Karl Anderson

Chris Withers [EMAIL PROTECTED] writes:

 "Nestor A. Diaz L." wrote:
  I want to know if there is any utility that let translate a ZClass to a
  Product, i'm worry using the frames based interface, so i'm considering to
  switch to a Product a utility that let that would be usefull howevere a
  HOWTO on doing this would be fine.
 
 Not sure abotu what you're asking...
 If you want to convert your ZClass-based product to a pythno based
 product so you don't have to do development through the managemetn
 interface, then the answer is sorry, no you can't.

I always put python base classes under my ZClasses, even if the
baseclass doesn't do anything at the start.  Then it's easy to
move attributes from the ZClass to the baseclass, or throw simple
test/debug/prototype methods in the ZClass temporarily.

Likewise, I usually put a ZClass on top of my python base classes,
even if the ZClass doesn't do much at the start (which is more often).

 However, if it's just the through-the-web part of developing a
 ZClass-based product that's causing you problems, have you considered
 editing the ZClasses using FTP or WebDAV?

What FTP editing options are there for ZClass definitions?  I've never
been able to do much.  What I have done is use folderish ZClasses,
edit DTML methods contained in the *instance* thru FTP, and then moved
them to the definition latler, but that's kind of hacky - it adds a
little more confusion about finding things with large projects.

-- 
Karl Anderson  [EMAIL PROTECTED]

___
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] Question relating to a zope product 'Tracker': emailproblems

2000-08-29 Thread R. David Murray

On Tue, 29 Aug 2000, Julian Harris wrote:
 PS if I wanted to make a change to the source on my machine, do I have to
 compile it? I see these PYC files everywhere but I thought Python was an
 interpreted language? How would I make a change if I found that I had to
 tweak the code a little?

If the .py file changes, then the next time python rereads the file
(read: when you restart Zope) a new pyc file will be generated.  The
pyc is a 'pcode' sort of thing, essentially a preparsed version
of the source code providing a considerable load-time optimization
for python apps.

--RDM


___
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] FSSession problems...

2000-08-29 Thread Curtis Maloney

On Tue, 29 Aug 2000, Pavlos Christoforou wrote:
 On Mon, 28 Aug 2000, Curtis Maloney wrote:
  /dtml-if
 
  This was aparently working fine for quite some time (about a month of
  public usage), until last week.  We have examined logs, and seen that one
  person accidentaly used the system under someone elses ReturnerID, and
  then rectified their mistake.

 If he did rectify the mistake then that should not have resulted in a
 problem. In any case the problem should have been isolated to that user
 only. Could it be that the cookie is cached somewhere? I am not familiar
 with the underlying pricinciples of the apache Proxy directives.


The user 'rectified' the problem by submitting the request again under their 
own ID.  I don't know when/how they noticed, and am not able to contact them 
for further comment.

As for the cookie being cached, I don't know.  It is possible, as I said, 
that Apache is causing problems.  ProxyForward means that when a URL matches 
a rule, it will be 'forwarded' to another server, and the returned page 
issued as if from Apache.

From the benchmarks I've seen, this is the fastest way to run Zope.  However, 
I can see how it could confuse Zope into thinking two different users 
requests are from the same machine, since all the requests are coming from 
Apache.  However, I am hoping (going to check on this, of course :)  that the 
smart folks at Apache have made it 'proxy' properly, to avoid this sort of 
problem.

 Pavlos

Curtis

___
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] Nested dtml???

2000-08-29 Thread Curtis Maloney

On Tue, 29 Aug 2000, Tim Hicks wrote:
 I am trying to work my way up through folders, checking whether each
 folder has a property named 'site_root_folder'.  Logically (in *my*
 head anyway), what I have written below is what I want to do, but I'm
 not sure that I'm really writing this the write way.  I vaguely
 remember reading that I can't nest dtml-if tags within dtml-in tags.

 I'd really appreciate any help on this

 tim

 dtml-let level=0
 dtml-in level
 dtml-if "PARENTS[level].hasProperty('site_root_folder')"
 dtml-var "PARENTS[level].absolute_url()"
 dtml-else level="level+1"
 /dtml-in
 /dtml-let


Hmm.. it may be slower, but I would normally use a recursive function in this 
case.

DTML Method  findRoot

dtml-if "PARENTS[rootLevel].hasProperty('site_root_folder')"
  dtml-return PARENTS[rootLevel].absolute_url()"
dtml-else
  dtml-return "findRoot(_.None, _, rootLevel=rootLevel+1)"
/dtml-if


Use as:

dtml-var "findRoot(_.None, _, rootLevel=0)"

 Tim:  [EMAIL PROTECTED]


If you don't mind my asking, why do you need to hunt down this folder?  Is 
there no way Acquisition could be used to simplify your life?

Have a better one,
Curtis

___
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] symbolic links or invisible objects..?

2000-08-29 Thread Geoffrey L. Wright


Zopistas:


Am working on a simple content management system for about 6 sites, and so
far, so good.  It's my first medium-sized Zope project and Zope has been
wonderful to work with so far.

However, I've been tasked with the project of creating the simplest
possible interface for some very non-technical content managers.  So the
first thing I did was abstract out the content from some fairly complex
formatting.  This was easy, and now I have a site where all the content
that theae people need to touch always lives in an object called
page_content.  Objeects by this name now exist at many points in the site.

Aparently the fact that a number of other non-content objects are visible
at the same level of heirarchy in the site is a problem.  So my question
is this:


 Is there any way to make zope understand something like a UNIX symbolic
 link?  If so, I could easily create a single directory with a symlinks to
 all the appropriate objects in the site.  Content managers would then
 have access only to this dir and would therefor see all appropriate
 objects.

 Or perhaps there is a way to make other objects invisable to those w/out
 the necessary permission to use them?  I've played with Zope permissions
 a but, and haven't yet found a way to do this.

 Or is the some other way entirely to look at this problem?


TIA for any help on this.



//glw


___
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] SSL and PGP

2000-08-29 Thread R. David Murray

On Tue, 29 Aug 2000, Diego Rodrigo Neufert wrote:
 Anyone know how to send a pgp cryped email in zope? (using dtml-sendmail or
 anything else)
 
 and
 
 How to run a SSL server with ZServer?

Search for M2Crypto on zope.org.  It does both.

--RDM


___
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] Re: ZOPE Python edit debug cycle

2000-08-29 Thread Loren Stafford

From: "Karl Anderson" [EMAIL PROTECTED]

 "Chui Tey" [EMAIL PROTECTED] writes:

 [quoting someone]

   Then I tried to edit a py file and see the new output. I had to use
   this sequence to see my tiny change:
  
   make the change
   save the change
   Stop the ZOPE service
   Start the ZOPE service
   Refresh the ZOPE Web page
   Inspect the change.
  
   If I had a syntax error, ZOPE throws it away and I never get to read
   it.

 You can see the error if you try to access the broken product
 definition in the control panel.

 I keep a link to the product and the restart button handy to reduce
 the pain.


There's also the Refresh product
(http://www.zope.org/Members/hathawsh/Refresh) which helps reload some
(most) products without restarting Zope.

-- Loren



___
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] symbolic links or invisible objects..?

2000-08-29 Thread R. David Murray

On Tue, 29 Aug 2000, Geoffrey L. Wright wrote:
 Aparently the fact that a number of other non-content objects are visible
 at the same level of heirarchy in the site is a problem.  So my question
 is this:
 
  Is there any way to make zope understand something like a UNIX symbolic
  link?  If so, I could easily create a single directory with a symlinks to
  all the appropriate objects in the site.  Content managers would then
  have access only to this dir and would therefor see all appropriate
  objects.
 
  Or perhaps there is a way to make other objects invisable to those w/out
  the necessary permission to use them?  I've played with Zope permissions
  a but, and haven't yet found a way to do this.
 
  Or is the some other way entirely to look at this problem?

How about creating a custom management page that just lists the
objects they need to change?  You could do this by hand if the
object list is static.  If, as is more likely, it changes, you
could create a Catalog that indexes meta_type or (if body_content
is not a specialized class) id, and thereby be able to pull up a
list of all body_content objects and list them on the custom
management page using dtml-in.  You can even use dtml-in batching
to keep the page size down if there are lots of these things.

--RDM


___
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] dtml-tree question

2000-08-29 Thread Dieter Maurer

Hugo Ramos writes:
  Is there a way to use my own self made '+' icon in a tree tag?
  I'dd like to use my own icon only IF i want to... and not change the python
  source to use my own icon all the time!
The code is partially there, but incomplete and commented out.

If you do not mind other extensions as well, I could provide
a TreeTag patch for several extensions, including the
icon customization.


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 )




Re: [Zope] Nested dtml???

2000-08-29 Thread Tim Hicks

- Original Message -
From: "Dieter Maurer" [EMAIL PROTECTED]
To: "Tim Hicks" [EMAIL PROTECTED]
Cc: "zope" [EMAIL PROTECTED]
Sent: Tuesday, August 29, 2000 11:10 PM
Subject: Re: [Zope] Nested dtml???


 Tim Hicks writes:
   I am trying to work my way up through folders, checking whether
each
   folder has a property named 'site_root_folder'.  Logically (in
*my*
   head anyway), what I have written below is what I want to do, but
I'm
   not sure that I'm really writing this the write way.  I vaguely
   remember reading that I can't nest dtml-if tags within dtml-in
tags.
 There is no problem whatsoever to use "dtml-if" inside "dtml-in".

   dtml-let level=0
   dtml-in level
   dtml-if "PARENTS[level].hasProperty('site_root_folder')"
   dtml-var "PARENTS[level].absolute_url()"
   dtml-else level="level+1"
   /dtml-in
   /dtml-let
 "dtml-in" works with sequences.

 In your example, however, you give it an integer ("level").
 It will not be happy with this.

 You may try:

 dtml-in PARENTS
   dtml-let PARENT="_.getitem('sequence-item')"
 dtml-if "PARENT.hasProperty
 


Excellent.  Here is what I have managed to make work.

dtml-in PARENTS
dtml-let PARENT="_.getitem('sequence-item')"
dtml-if "PARENT.hasProperty('site_root_folder')"dtml-var
"PARENT.absolute_url()"/dtml-if
/dtml-let
/dtml-in

I really appreciate it.  And thanks for the reply on my other
(related) post.  Don't think I'll mess with ZopeFind for now; I don't
always have access to Zope 2.2.x, but more usually 2.1.6.

Thanks again.

tim


___
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] Nested dtml???

2000-08-29 Thread Tim Hicks

- Original Message -
From: "Curtis Maloney" [EMAIL PROTECTED]
To: "Tim Hicks" [EMAIL PROTECTED]; "zope" [EMAIL PROTECTED]
Sent: Wednesday, August 30, 2000 12:24 AM
Subject: Re: [Zope] Nested dtml???


 On Tue, 29 Aug 2000, Tim Hicks wrote:
  I am trying to work my way up through folders, checking whether
each
  folder has a property named 'site_root_folder'.  Logically (in
*my*
  head anyway), what I have written below is what I want to do, but
I'm
  not sure that I'm really writing this the write way.  I vaguely
  remember reading that I can't nest dtml-if tags within dtml-in
tags.
 
  I'd really appreciate any help on this
 
  tim
 
  dtml-let level=0
  dtml-in level
  dtml-if "PARENTS[level].hasProperty('site_root_folder')"
  dtml-var "PARENTS[level].absolute_url()"
  dtml-else level="level+1"
  /dtml-in
  /dtml-let
 
 
 Hmm.. it may be slower, but I would normally use a recursive
function in this
 case.

 DTML Method  findRoot

 dtml-if "PARENTS[rootLevel].hasProperty('site_root_folder')"
   dtml-return PARENTS[rootLevel].absolute_url()"
 dtml-else
   dtml-return "findRoot(_.None, _, rootLevel=rootLevel+1)"
 /dtml-if


 Use as:

 dtml-var "findRoot(_.None, _, rootLevel=0)"


Thanks for the ideas, but I have managed to do what I wanted to do
using the code below (with help from Dieter Maurer).

dtml-in PARENTS
dtml-let PARENT="_.getitem('sequence-item')"
dtml-if "PARENT.hasProperty('site_root_folder')"dtml-var
"PARENT.absolute_url()"/dtml-if
/dtml-let
/dtml-in

  Tim:  [EMAIL PROTECTED]
 

 If you don't mind my asking, why do you need to hunt down this
folder?  Is
 there no way Acquisition could be used to simplify your life?


I have made a couple of 'sites' that need to be portable so that they
can be placed on any server, with their 'root' directory having any
name without needing to edit anything. Therefore, in every link/URL
within the site, I do something like the following,

href="dtml-var path/link/to/whatever.html"

The path method is what contains the code that I have shown above.  In
this way, all the links work no matter what server they are placed on
(zope of course!).  I don't think I could have just used relative
links as my standard_html_header/footer contains links/images.  With
relative links, when the header/footer was placed into a document that
was not in the site's root folder, they were broken.

Does that make any sense?  Have I gone about it a bit backwards?

Anyway, you did ask :-)

tim


 Have a better one,
 Curtis



___
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] help

2000-08-29 Thread duc huynh

hi!

I am a new user.  I just download the new version of zope 2.2.0.  After i 
finish install it on my computer.  I ran the "start.bat" in the website 
folder but i get the error.
The error is :
" pROBLEM(100) zSERVER COMPUTING DEFAULT HOSTNAME"

Would you please tell me what is the problem with that message.

Thank you for your time.

_
Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com.

Share information about yourself, create your own public profile at 
http://profiles.msn.com.



___
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] Logfile analyzer

2000-08-29 Thread Ian Bicking

I've been making some log analysis code on my site, and have realized
that a lot of other analyzers aren't that great -- or, at least, that
it's nice to have the control that editting the actual code can give.
(for instance, I ignore all requests that come from my ISP, since I
don't need to know what my surfing habits are; I ignore all pages
that end in "manage.*"; etc.)

Anyway, I've been thinking of polishing and expanding what I've
written some, so it's suitable for public use (or at least use by
people who know Zope/Python fairly well).  But this requires work that 
I probably wouldn't do for myself -- so I'm writing to see if there
are enough people who have interest in this to make it worth it.  [Or
if this already exists and I just haven't found it]

Cheers,
  Ian

___
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] How to Delete ZClass Instances programmatically??

2000-08-29 Thread Dieter Maurer

Jean Jordaan writes:
  I've found the "How-To: Adding ZClass Instances Programmatically",
  but now I'm looking for the *Deleting ZClass Instances* one!
  
  I'm trying this as a beginning (hacked from the Zope management
  interface)::
  
  dtml-if "AUTHENTICATED_USER.has_role('ContentManager')"
input type="submit" name="manage_delObjects:method" value="Delete"
/form
  /dtml-if
  
  Problems: 
  
   - it sends me to the management screen afterwards, and I'm 
 calling it from the public interface. 
This means, you want to look at the source of "manage_delObjects"
(- "OFS.ObjectManager") to see, how it sends you to the management interface.

You will see, that it contains:

if REQUEST is not None:
  return self.manage_main(self,REQUEST,update_menu)

Thus, do not pass it a REQUEST.

This implies, that you do not call it directly from the form,
but call a dtml method from the form, that then calls
"manage_delObjects" with the "ids" and no REQUEST.

It may be necessary to set a proxy role for this method.

   - I don't necessarily want to give the 'ContentManager' rights
 to delete objects; I'd rather manage this through a delete 
 method with the appropriate proxy role.
Then, this should get your method mentioned above.



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 )




Re: [Zope] updating only zCatalog ?

2000-08-29 Thread Dieter Maurer

Philipp Dunkel writes:
  I'd like to use it for my Products, but I don't have the time now to port
  everything to the new zope version.
  Is it possible to only use the new catalog and which files do I have to
  change/update ?
It is possible.

You would use the folder "SearchIndex" from Zope 2.2
and the attached patch.


Dieter

.
diff -u ../ZopeCVS/lib/python/Products/ZCatalog/Vocabulary.py 
lib/python/Products/ZCatalog/Vocabulary.py
--- ../ZopeCVS/lib/python/Products/ZCatalog/Vocabulary.py   Sat Aug 19 15:56:53 
2000
+++ lib/python/Products/ZCatalog/Vocabulary.py  Sat Aug 19 15:58:13 2000
@@ -128,7 +128,7 @@
  'help': ('ZCatalog', 'Vocabulary_Query.stx')},
 )
 +Item.manage_options
-+AccessControl.Role.RoleManager.manage_options
+#+AccessControl.Role.RoleManager.manage_options
 )
 
 __ac_permissions__=(
diff -u ../ZopeCVS/lib/python/Products/ZCatalog/ZCatalog.py 
lib/python/Products/ZCatalog/ZCatalog.py
--- ../ZopeCVS/lib/python/Products/ZCatalog/ZCatalog.py Sat Aug 19 15:56:42 2000
+++ lib/python/Products/ZCatalog/ZCatalog.pySat Aug 19 15:58:48 2000
@@ -101,7 +101,7 @@
 from SearchIndex import UnIndex, UnTextIndex
 from Vocabulary import Vocabulary
 import IOBTree
-from AccessControl import getSecurityManager
+#from AccessControl import getSecurityManager
 
 
 manage_addZCatalogForm=HTMLFile('addZCatalog',globals())
@@ -614,9 +614,9 @@
 
 
 class td(TemplateDict):
-
-def validate(self, inst, parent, name, value, md):
-return getSecurityManager().validate(inst, parent, name, value)
+pass
+#def validate(self, inst, parent, name, value, md):
+#return getSecurityManager().validate(inst, parent, name, value)
 
 def expr_match(ob, ed, c=InstanceDict, r=0):
 e, md, push, pop=ed
diff -u ../ZopeCVS/lib/python/Products/ZCatalog/__init__.py 
lib/python/Products/ZCatalog/__init__.py
--- ../ZopeCVS/lib/python/Products/ZCatalog/__init__.py Fri Jun  9 03:22:14 2000
+++ lib/python/Products/ZCatalog/__init__.pySun Aug 20 07:42:25 2000
@@ -109,6 +109,6 @@
 context.registerBaseClass(ZCatalog.ZCatalog)
 context.registerBaseClass(CatalogAwareness.CatalogAware)
 
-context.registerHelp()
-context.registerHelpTitle('Zope Help')
+#context.registerHelp()
+#context.registerHelpTitle('Zope Help')
 
diff -u ../ZopeCVS/lib/python/Products/ZCatalog/addZCatalog.dtml 
lib/python/Products/ZCatalog/addZCatalog.dtml
--- ../ZopeCVS/lib/python/Products/ZCatalog/addZCatalog.dtmlSat Jul 29 11:24:43 
2000
+++ lib/python/Products/ZCatalog/addZCatalog.dtml   Sun Aug 20 07:51:21 2000
@@ -6,7 +6,10 @@
 BODY BGCOLOR="#FF" LINK="#99" VLINK="#55"
 H2Add Catalog/H2
 
+dtml-comment
 dtml-var "HelpSys.HelpButton('ZCatalog_Add.stx', 'ZCatalog')"
+/dtml-comment
+
 
 FORM ACTION="manage_addZCatalog" METHOD="POST"
 TABLE CELLSPACING="2"

___
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] ZCatalog in 2.2.x

2000-08-29 Thread Terry Kerr

Hi,

I have a python product which uses a ZCatalog and CatalogAware
products.  The catalog has a number of Field and TextIndex indexes.
Search the ZCatalog has worked fine when my product is instantiated in
2.1.6.  But now when I instantiate my product in 2.2.0 or 2.2.1,
searching only works when I search using a field index.  Searching using
a textindex always results in an empty result, even tho I can see the
words I am searching for in the Vocabulary!  Any suggestions?  I have
tried reindexing, completey recreating the Zcatalog, recreating the
Vobulary and reindexing, and nothing has changed the behaviour.  Are
textindexes simply broken?


ZCatalog seems very volatile to me!  Every time I have upgraded way back
from zope2.1.3, something in zcatalog has changed and boken my product.
So far I have managed to find fixes, but this one has got me baffled!!

--
Terry Kerr ([EMAIL PROTECTED])
Adroit Internet Solutions Pty Ltd (www.adroit.net)
Phone:   +613 9563 4461
Fax: +613 9563 3856
Mobile:  +61 414 938 124
ICQ: 79303381




___
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] help

2000-08-29 Thread Chris McDonough

This is a normal message, please ignore it..

 -Original Message-
 From: duc huynh [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, August 29, 2000 1:26 AM
 To: [EMAIL PROTECTED]
 Subject: [Zope] help
 
 
 hi!
 
 I am a new user.  I just download the new version of zope 
 2.2.0.  After i 
 finish install it on my computer.  I ran the "start.bat" in 
 the website 
 folder but i get the error.
 The error is :
 " pROBLEM(100) zSERVER COMPUTING DEFAULT HOSTNAME"
 
 Would you please tell me what is the problem with that message.
 
 Thank you for your time.
 
 __
 ___
 Get Your Private, Free E-mail from MSN Hotmail at 
 http://www.hotmail.com.
 
 Share information about yourself, create your own public profile at 
 http://profiles.msn.com.
 
 
 
 ___
 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 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 in 2.2.x

2000-08-29 Thread pja

Terry Kerr [EMAIL PROTECTED] said: 

 Hi,
 
 I have a python product which uses a ZCatalog and CatalogAware
 products.  The catalog has a number of Field and TextIndex indexes.
 Search the ZCatalog has worked fine when my product is instantiated in
 2.1.6.  But now when I instantiate my product in 2.2.0 or 2.2.1,
 searching only works when I search using a field index.  Searching using
 a textindex always results in an empty result, even tho I can see the
 words I am searching for in the Vocabulary!  Any suggestions?  I have
 tried reindexing, completey recreating the Zcatalog, recreating the
 Vobulary and reindexing, and nothing has changed the behaviour.  Are
 textindexes simply broken?
 
 
 ZCatalog seems very volatile to me!  Every time I have upgraded way back
 from zope2.1.3, something in zcatalog has changed and boken my product.
 So far I have managed to find fixes, but this one has got me baffled!!
 

My experience has been that if field indexes are unspecified, the catalog 
will only match where those fields are empty.  In other words, by not 
specifing anything for the field indexes, you are actually specifying that 
for a match, they need to be empty.
To get around this, I put another method between the form for entering what 
you wish to search for, and the method that actually searches the form.  This 
method looks at the field indexes, and if nothing has been specified, it 
doesn't pass them on to the method that does the actual search.
An alternative to this, is to use names for the field indexes that aren't in 
the catalog index, and then at the start of the search method, check those 
names, and if they have a value associated with them, add to REQUEST what the 
names in the index are with the appropriate values.

There may be a better way, I'm still pretty new to Zope and DTML sort of 
stuff.

Peter Armstrong

___
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] how to keep stuff out of undo

2000-08-29 Thread Roman Milner

Hi. We have a product (an mp3 jukebox) that uses the ZODB to store a large
data structure of all the albums and track names.  Many people are
allowed to add/remove albums from the database.  The problem is, when
they do this the entire data structure is backed up for undo.  So, by
the end of each day, our ZODB has grown so large we are out of disk space.

Is is possible make something presistent but keep it from being
backed up when it is changed?

Thanks,
^Roman


___
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] how to keep stuff out of undo

2000-08-29 Thread Chris McDonough

Oo.  That's bad.  There is no way to selectively make something
persistent but non-historying using FileStorage.

I would suggest possibly using dbmStorage (or its brother
BerkeleyStorage) to store this big data structure, as it does not
perform undo.

You might be successful using these storages in conjunction with the
"mountable storage" option, whereby you can "mount" additional storages
into your folder structure.  Perhaps use FileStorage for "normal"
operations but place the product's instances into the "mounted" section
of your site (backed by dbmStorage or BerkeleyStorage, where it won't be
historied).  I've never used mounted storages, so I can't explain how
it's done, but I'm sure other folks here can.

Mounted storages fall down with versions (do not use versions in
conjunction with mounted storages, it will do bad things to you).

 -Original Message-
 From: Roman Milner [mailto:[EMAIL PROTECTED]]
 Sent: Tuesday, August 29, 2000 11:29 PM
 To: [EMAIL PROTECTED]
 Subject: [Zope] how to keep stuff out of undo
 
 
 Hi. We have a product (an mp3 jukebox) that uses the ZODB to 
 store a large
 data structure of all the albums and track names.  Many people are
 allowed to add/remove albums from the database.  The problem is, when
 they do this the entire data structure is backed up for undo.  So, by
 the end of each day, our ZODB has grown so large we are out 
 of disk space.
 
 Is is possible make something presistent but keep it from being
 backed up when it is changed?
 
 Thanks,
 ^Roman
 
 
 ___
 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 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] Automatic creation of searchable documents from Oracle DB tables

2000-08-29 Thread Kapil Thangavelu

Chris Beaumont wrote:
 
Part 1.1Type: Plain Text (text/plain)
Hi Kapil, (and fellow Zopatistas)

Well, it's been difficult, but I finally feel as if I'm on the verge 
or understanding this a bit better..

Thank you for taking the time to explain this.
I would think, it's a fairly simple thing I'm trying to do. Hehehe.. 
Famous last words.. huh?

#
#Kapil
###
i say it all the time:)

before i go on i should probably say that i'm not sure about the
benefits of using zclass  presentation of sql data in this case. you're
trying to enforce a one-to-one object to event ratio but to what
benefit, the only one thats readily apparent to me are the urls.
The functionality for display could easily be done with a few pages and
some sql methods in instead.

#

So, anyway, I've been staying up till 2 am almost every night trying 
to absorb as much of this as I can, but I have an (extensive) web 
development, but not a programmer's background, and I'm very much a 
Zope newbie, so I need to ask you some more questions.. I hope you 
don't mind..

You can get a feel for what I am talking about by looking at any of 
the programs or workshops on the website I manage, www.msri.org.
Currently, I'm doing this site by rendering these fields of info 
through templates into static pages in Frontier, but I'd like to 
transition to Zope.
(Its the old webmaster's dream of the "self-maintaining site"  *LOL*)

So here's where I'm at so far.. I have built an Oracle 7 database to 
hold the event info.. Everything fine there, everything works.. now 
for the fun stuff..

I have several tables in this "event" section of the database, 
programs, workshops and talks. (there actually is one other table for 
other kinds of events) Each kind of event is treated somewhat 
differently in the schema. It's a very simple setup with nothing 
exotic going on..  Logically, a given workshop is usually tied to a 
program..and a given talk is usually tied to a parent workshop.


###


#

I have been successful in setting up the basic web-database 
interaction. I made the basic insert and query forms that are 
described in the ZSQL Users Guide, and  as I said in my previous 
posting my next goal is to be able to create separate documents from 
the data in the individual records that are inserted into the 
tables.. I'd like to be able to search them along with the other Zope 
documents on the site, at once, (using a ZCatalog..hopefully)


#

ZCatalog searches of the RDBMS are generally not possible or
recommended(size concerns). It might be possible catalog the objects
based on an sql method within the zclass that takes no args. Search the
mailing lists for more on this. doing this would probably require doing
this as a base python product with a zclass inheriting from it, so you
can create the sql method with the proper syntax without an arg.

Another possibility since you're using oracle is intermedia/context
indexing, although i'm not sure if it exists in oracle 7, and its a pain
to setup (see technet.oracle.com and www.arsdigita.com/bboard for help).



I also need to be able to quickly build several different kinds of 
automatically-maintained lists from SQL queries that home in on 
various subsets of the event data. (Ultimately, this system will be 
expanded to handle "people" data, which will involve some very large 
lists of people spanning over 20 years, so this system needs to have 
decent performance with large datasets...But, even then, the result 
set of a given query will always be quite small..)

#

if you're trying to change your zope object heirarchy based on these
lists you should just do the whole thing in sql which is designed for
relations. IMO object dbs are designed for interaction.


#

Starting with (on the insert record side) I have an SQL Method for 
each event type that describes the permissable arguments, and the 
code describing the multi-field  insert.

(I have a sequence and trigger already working on the database side 
of things that implements a unique ID -the primary key- for each new 
program, so the ID is not one of the arguments passed through the 
ZSQL Method..should I change this? - I could do this some other way..)

###

keep your sequence. in your insert method do an sql delimter and select
the id of the inserted record, assign this as either a property or the
id of the zclass. the property might be better if you want to have a url
which has some semantic sense to it.

###


I also have another SQL method for each type of event that does a 
select * from event_type so that I can implement pulldowns in the 
select form for the child workshops of a program. (This is really 
nice and is one of the reasons I think Zope will be great for 
building a highly useable web interface to this database,  widgets 
like this make it easy to keep referential integrity..)

Re: [Zope] Logfile analyzer

2000-08-29 Thread Kapil Thangavelu

Ian Bicking wrote:
 
 I've been making some log analysis code on my site, and have realized
 that a lot of other analyzers aren't that great -- or, at least, that
 it's nice to have the control that editting the actual code can give.
 (for instance, I ignore all requests that come from my ISP, since I
 don't need to know what my surfing habits are; I ignore all pages
 that end in "manage.*"; etc.)
 
 Anyway, I've been thinking of polishing and expanding what I've
 written some, so it's suitable for public use (or at least use by
 people who know Zope/Python fairly well).  But this requires work that
 I probably wouldn't do for myself -- so I'm writing to see if there
 are enough people who have interest in this to make it worth it.  [Or
 if this already exists and I just haven't found it]
 
 Cheers,
   Ian

Hi Ian,

zope's logs are in a pretty standard format so most of your loganalyzers
should handle them well and several of them can be customized to ignore
certain ips or urls.

i've been told that http://www.webalizer.org/ is pretty nice.

a zope web logs analyzer that makes images with PIL integrated into the
control panel, is on my list of things to do although its pretty low at
the moment.

Cheers

Kapil

___
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] Generic Workflow Products?

2000-08-29 Thread Kapil Thangavelu

albert boulanger wrote:
 
 Kapil Thangavelu [EMAIL PROTECTED] wrote:
 
The PTK has been undergoing radical changes as of late. Its worth taking
another look at as the current design is much more supportive of
alternative workflow designs.
 
 Disclamer: This is my gleaming -- I could be off.  I have done a
 keyword search on the Zope-PTK list for workflow to understand the
 recent discussion on workflow design within PTK. It seems to me that
 workflow is tied to strongly with documents in the design plan. In the
 model of workflow being discussed there, documents march through
 workflow steps. What if a workflow step is a computation and requires
 multiple data sources to be done? Instead, a workflow step needs to
 have an explicit representation with data items (documents) associated
 with it having some kind of version info associated with them. This
 need comes from the use cases that I deal with in setting up workflow
 for science and engineering computation.
 
 For a good review of workflow requirements see:
 
 http://www.ics.uci.edu/pub/endeavors/docs/AdvancedWorkflow.pdf

i haven't had time to read through the links, although i will once i get
some more of that mystical free time stuff, but i wanted to clarify
about PTK workflows. most of the existing workflow structs in PTK were
doc based with simple workflows, but there has been a concerted effort
to refactor PTK into Singleton objects which give abilities to all
objects vs. the old method of inheritance for abilities. In this
scenario workflow objects can be plugged into the architecture. Another
item that gives support for complex workflows is the
event/subscriber/publisher system being developed right now. check out
the later half of the PTK archives for August to get some more
background. if you want to influence the project, now is the time, make
your voice/needs heard.


Cheers

Kapil

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