RE: [Zope-dev] a beginners question ...

2001-06-13 Thread Loren Stafford

The quick answer is Yes. One method is described by
http://www.zope.org/Members/lstaffor/ZClientMethod. You can also use
XML-RPC.

On the other hand, Zope is an integrated programming environment for web
applications. It includes the capabilities offered by servlets within its
programming system; DTML methods, Script (Python), Script (Perl), SQL
Methods are all servlet-like functions. So you might ask yourself whether
you couldn't do better inside Zope what the servlets are doing for you
outside Zope.

-- Loren

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of
Brian Gorrie
Sent: Wednesday, June 13, 2001 18:01
To: [EMAIL PROTECTED]
Subject: [Zope-dev] a beginners question ...



Hi,

Forgive my lack of Zope knowledge I am fairly new to Zope.

Question:  From zope can I take a block of text returned by a web link ( say
some dhtml returned by a servlet ) and
include that in the source of a web page.  So I can build the sections of a
web page through successive calls to
Servlets ?

Cheers,

Brian.


___
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] Does creating REAL over-the-web Python code become realistic with Zope 2.4?

2001-05-31 Thread Loren Stafford

Coincidently, I was just trying to edit a file on the filesystem with an FTP
client going thru Zope/FTP and a LocalFS. It didn't work. The LocalFS
instance didn't look like a directory to FTP so FTP could neither read nor
write to the directory.

Does that throw a monkey wrench into your idea?

-- Loren

 -Original Message-
 From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf
 Of Joachim Werner
 Sent: Thursday, May 31, 2001 15:54
 To: [EMAIL PROTECTED]
 Subject: [Zope-dev] Does creating REAL over-the-web Python code become
 realistic with Zope 2.4?


 Hi!

 When I read about the reload functionality of Zope 2.4, an old vision came
 back to my mind:

 If we can reload Python code at runtime, and we can also edit,
 generate and
 store files (containing code)  via the web (as LocalFS or extFile prove),
 then it should be perfectly possible to have something like ZClasses (it
 terms of the over-the-web front-end) that spits out and dynamically loads
 REAL Python classes instead of the rather experimental simulation
 of classes
 we get with ZClasses, right?

 I'll skip the part about why we should not be able to manipulate Zope code
 over the web, which can be discussed separately ...

 What do you think about this idea? If it finds some friends, I'll set up a
 formal proposal for something like ZClass-like features to build
 REAL Zope
 Python classes over the web.

 Joachim




 ___
 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 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] Xron error!!!

2001-05-24 Thread Loren Stafford

1. If you can use the management interface, you can disable a Xron Scheduled
Method by deleting it from the Schedule catalog or setting its reschedule
interval to null.

2. If you delete (or just rename __init__.py to something else in) the Xron
Product. And restart Zope, there will be no Dispatcher to execute Xron
Scheduled Methods; so looping will stop.

3. The messages in the log file should indicate what kind of error the Xron
Dispatcher is encountering. If this is some kind of environmental condition,
perhaps you can fix it external to Zope and the Dispatcher will stop
looping.

4. The Dispatcher is designed to cancel erring Xron Scheduled Method,
precisely so that it will not go into a loop. The fact that it seems to be
looping indicated some very unusual condition. Please let us know what the
log file says.

5. You can truncate the bloated tail end of a Data.fs file using standard
system tools. I don't remember how right at the moment, but a search in the
mail archives on trucate and data.fs might be fruitful. Don't throw away the
original file, because you might truncate other transactions that you wanted
to save. IOW, finding the right spot to truncate is the trick.

-- HTH
-- Loren


 -Original Message-
 From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf
 Of Espen Sorbye Frederiksen
 Sent: Thursday, May 24, 2001 13:06
 To: [EMAIL PROTECTED]
 Subject: [Zope-dev] Xron error!!!


 My Xron file has gone crazy and does not stop running. I have stopped my
 server and started it again, but the xron file is still running. This
 causes the Z2.log file and Data.fs files to
 grow to enormous files and I struggle to be able to log into the system.

 First: Can I delete the overloaded Data.fs file in the var/ directory, or
 will this cause serious trouble?

 Secondly: Is there a cure against that void Xron file of mine or must I
 manually delete it from were my own files are stored?

 Thanks for any kind of help,

 Espen


 ___
 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 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] Manage Interface

2001-05-24 Thread Loren Stafford


 Does DC plan to have site developer make their own management interface?

 The site-developer wouln't mind using the management interface for their
 work, but most of them will reject the common users using it.  Of cause
 there were security issues also.

 Allow the site developer to make new interface on specific branch of the
 object tree will easy their jobs.

Using basic Zope, yes. If you want end-users to manage content in any way,
you have to create the end-user interface and expose the underlying
management interface through it as you see fit.

The Content  Management Framework (CMF) Zope product ([EMAIL PROTECTED]) is
another approach for portal-like environments. CMF is specifically designed
to delegate content management using a common, more user-friendly interface.

-- Loren


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

2001-05-11 Thread Loren Stafford

This is a known problem. Search back thru the archives of [EMAIL PROTECTED] for
Xron and you will find some helpful information. I'll also try to find the
relevant email and forward it to you separately.

-- Loren (lstaffor)

 -Original Message-
 From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf
 Of Homan Els
 Sent: Friday, May 11, 2001 06:23
 To: [EMAIL PROTECTED]
 Subject: [Zope-dev] Xron


 Hi,

 I did install the xron product from Istaffor, but it doesn't work.

 I am using Zope - .2.3.2, and installed xron. But, when I want to access
 the zope - server, I get a zero response back.

 Does anyone no the answer to this problem ?

 Thanks,

 Els Homan

 __



 ___
 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 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] : XCRON

2001-05-11 Thread Loren Stafford

1. Be sure to use the STUPID_LOG_FILE or run Zope in debug mode. That's the
only way you will know what Xron's Dispatcher is doing.

2. Xron DTML Methods run as Anonymous User. You may have to give your Xron
DTML Methods proxy roles so that they can execute the functions you want
them to. This is a common problem for Xron DTML Methods that send email.
They have to have permission to use mailhost services.

3. Beware of the Catalog bug in 2.3.1bx.

4. Search the archives of [EMAIL PROTECTED] for Xron. You will find helpful
information about issues that other users have already discovered.

-- Loren

 -Original Message-
 From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf
 Of Espen Sorbye Frederiksen
 Sent: Friday, May 11, 2001 06:35
 To: Homan Els
 Cc: [EMAIL PROTECTED]
 Subject: Re: [Zope-dev] : XCRON


 Hi, I have installed it as well and can neither get it to work. It does
 nearly what it is supposed to by scheduling the scripts to execute, but
 the final execution does never occur. ANy tricks out there are good news
 for me as well,

 Espen

  On Fri, 11 May 2001, Homan Els
 wrote:

  Hi,
 
  I did install the xron product from Istaffor, but it doesn't work.
 
  I am using Zope - .2.3.2, and installed xron. But, when I want to access
 
  the zope - server, I get a zero response back.
 
  Does anyone no the answer to this problem ?
 
  Thanks,
 
  Els Homan
 
  Ps. Log-file:
 
 
  --
  2001-05-11T09:55:30 INFO(0) ZServer HTTP server started at Fri May 11
  11:55:30 2001
  Hostname: localhost
  Port: 8080
  --
  2001-05-11T09:55:30 INFO(0) ZServer FTP server started at Fri May 11
  11:55:30 2001
  Hostname: speedy
  Port: 8021
  --
  2001-05-11T09:55:30 INFO(0) ZServer PCGI Server started at Fri May 11
  11:55:30 2001
  Unix socket: /usr/local/Zope-2.3.1-linux2-x86/var/pcgi.soc
  --
  2001-05-11T10:12:44 INFO(0) zdaemon zdaemon: Fri May 11 12:12:44 2001:
  Houston, we have forked
  --
  2001-05-11T10:12:44 INFO(0) zdaemon zdaemon: Fri May 11 12:12:44 2001:
  Hi, I just forked off a kid: 2548
  --
  2001-05-11T10:12:44 INFO(0) zdaemon zdaemon: Fri May 11 12:12:44 2001:
  Houston, we have forked
  --
  2001-05-11T10:12:44 INFO(0) zdaemon zdaemon: Fri May 11 12:12:44 2001:
  Houston, we have forked
  --
  2001-05-11T10:12:44 INFO(0) zdaemon zdaemon: Fri May 11 12:12:44 2001:
  Hi, I just forked off a kid: 2550
  --
  2001-05-11T10:12:44 INFO(0) zdaemon zdaemon: Fri May 11 12:12:44 2001:
  Houston, we have forked
  --
  2001-05-11T10:12:50 INFO(0) Products.Xron.Loggerr Created new Schedule
 
  __
 
 
 
  ___
  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 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 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] Database indexing using Z Catalogs

2001-04-12 Thread Loren Stafford

http://www.zope.org/Members/rbickers/cataloganything

 -Original Message-
 From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf
 Of Honey George
 Sent: Thursday, April 12, 2001 00:46
 To: [EMAIL PROTECTED]
 Subject: [Zope-dev] Database indexing using Z Catalogs
 
 
 Hello,
   I am not able to find a way to index and external
 database say PostgreSQL using Z Catalogs and search
 the contents. Can anybody help me in this. I couldn't
 find a complete documentation in the zope site. It
 will be helpfull to me if somebody can explain to me
 using an example.
 
 Regards,
Honey
 
 __
 Do You Yahoo!?
 Get email at your own domain with Yahoo! Mail. 
 http://personal.mail.yahoo.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 )
 

___
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] Windows FAQ / Help area?

2001-04-09 Thread Loren Stafford

Especially, how to set up permissions on the server machine and file servers
so that database connections and Local File Systems work. One problem I have
now and haven't found a good solution to is how to ensure that, when Zope is
started at (NT 4) system initialization, it has the right permissions for
all the DB connections, NFS connections, and Local File Systems.

 -Original Message-
 From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf
 Of Bryan Baszczewski
 Sent: Monday, April 09, 2001 13:11
 To: 'Andy McKay'; [EMAIL PROTECTED]
 Subject: RE: [Zope-dev] Windows FAQ / Help area?


 How about database access (i.e. ODBC adapters)

 -Original Message-
 From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf
 Of Andy McKay
 Sent: Monday, April 09, 2001 3:51 PM
 To: [EMAIL PROTECTED]
 Subject: [Zope-dev] Windows FAQ / Help area?


 Just thinking how many little tidbits I know related to running Zope on
 Windows that are very platform and installation specific. Do
 people think it
 would be a good idea to start at least a wiki / faq section somewhere
 covering this? Do other windows users think there is enough stuff
 to put in
 there?

 Things I can think of off the top of my head: windows service, getting
 stdout when running as a service and I was about to add ZEO, but
 thats been
 fixed...

 Cheers.
 --
   Andy McKay.




 ___
 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 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 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] access db linux

2001-03-29 Thread Loren Stafford

No. But you could leave the Access DB on its Win box, and either

1. Use a Linux ODBC driver to access it (something I've never tried)

...or...

2. Install a copy of Zope on the Win box to access the DB with a Win ODBC
driver, then use some kind of remote procedure call (e.g. XML_RPC or
ZClient) from your main Zope to the Win Zope. I know this works.

-- Loren

 -Original Message-
 From: [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED]]On Behalf
 Of danchik
 Sent: Thursday, March 29, 2001 14:02
 To: zope-dev
 Subject: [Zope-dev] access db linux


 does anyone know if there a way to have an access db to be
 placed onto linux
 box with zope running on it and have it be able to access
 that db... I
 don't really want to convert the entire database.




 ___
 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 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] Re: Xron for Zope: Asking for Help

2001-01-30 Thread Loren Stafford

I don't have much experience with this either. You should direct your
question to the Zope mailing list where others can share their expertise
with you (not to mention replying promptly).

-- Loren

- Original Message -
From: "R. Herold" [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Sunday, January 07, 2001 7:31 AM
Subject: Xron for Zope: Asking for Help


 Dear Loren Stafford,

 thank You for providing the Xron product, which I would like to regularly
 update ZCatalogs of parts of our site. However, I can't figure out
 what I have to put into the Xron DTML Method. The site catalog should be
 updated every 2 hours and cleared and renewed every 12 hours. I just don't
 know how to translate the management interfaces URL for the catalog
 (e.g. site_catalog/?manage_catalogReindex%3Amethod=+Update+Catalog)
 into a Xron dtml-call - Coud You help me, please?

 I am using Xron 0.0.9 with Zope 2.2.4 (under Linux and Windows).
 Thanks for any tip,
 Greetings, Ralf Herold


 -- Dr. med. Ralf Herold
 | Koordinationszentrale Kompetenznetz Pdiatrische Onkologie und
Hmatologie
 | Charit Campus Virchow-Klinikum Medizinische Fakultt
Humboldt-Universitt
 | D-13353 Berlin, Augustenburger Platz 1, Raum 4.3412 4. Etage Mittelallee
8
 | Tel. +49(30)450-66834 Fax -66906 Sprach-/Faxbox +49(180)505254-873936
 | mailto:[EMAIL PROTECTED]  http://www.knm-poh.charite.de/




___
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: How to make a zclass as default Xron methods?

2001-01-30 Thread Loren Stafford

Best to address questions to the Zope mailing list. You'll get more prompt
answers coupled with the collective experience of hundreds of users.

I'm not sure exactly what you are asking, but I'll try to clarify, anyway...

self.executeAt is the property that holds the next scheduled execution time.
This property is set by manage_addXronDTMLMethod to hold the first scheduled
execution time, and changed periodically by 'reschedule'.

Could change addXronDTMLMethod.dtml to expose only executeAt but not
periodDays or you could do the same by changing manage_addXronDTMLMethod
(which is invoked by addXronDTMLMethod.dtml).

-- Hope that helps
-- Loren

- Original Message -
From: "Dirksen Lau" [EMAIL PROTECTED]
To: "Loren Stafford" [EMAIL PROTECTED]
Sent: Monday, January 01, 2001 7:51 PM
Subject: How to make a zclass as default Xron methods?


 Hi Loren,

 I want to subclass Xron method, and provide default action and reschedule
 interval, leaving the initial time for customization. Which method to
 override so as to preset the Scheduled Method?

 cheers
 Dirksen





___
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] (Cc || Bcc) dtml-sendmail

2001-01-19 Thread Loren Stafford

Here's an example from one of my workinig tech-support forms. I used to have
a Bcc: right after the Cc:

dtml-with "PARENTS[-1]"dtml-sendmail mailhost=MailHost
To: [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED], [EMAIL PROTECTED], dtml-var ReplyTo
Reply-to: dtml-var ReplyTo
From: [EMAIL PROTECTED]
Subject: New Employee Setup

Name:   dtml-var mvxfname dtml-var mvxminitial dtml-var mvxlname
Manager:dtml-var mvxmanager
Start Date: dtml-var mvxsdate
Department: dtml-var mvxdept
Cubicle:dtml-var mvxcubicle

Office Phone: dtml-var mvxNumbers. dtml-var mvxVoiceMail.

E-Mail: dtml-var mvxEmail missing="off"

dtml-if mvxaliases
Aliases:
dtml-in mvxaliases
dtml-var sequence-item
/dtml-in mvxaliases
/dtml-if mvxaliases

dtml-if mvxEmailLists
E-Mail Distribution Lists:
dtml-in mvxEmailLists
dtml-var sequence-item
/dtml-in mvxEmailLists
/dtml-if mvxEmailLists


-- end --

/dtml-sendmail/dtml-with "PARENTS[-1]"

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of Jeff
Peterson
Sent: Friday, January 19, 2001 11:41
To: Zope@Zope. Org
Subject: [Zope] (Cc || Bcc)  dtml-sendmail


We built our intranet on ZOPE 2.2.x, mostly it is a tech support app that
ensures our techs only deliver the info we need.  Anyway, the method of
doing this is sending a form via email with the info.

The Problem:  I would like to Cc or Bcc the originator of the request with a
copy of the request for record keeping purposes. I cannot however seem to
get Cc or Bcc, written as headers much like the To and From, to work with
dtml-sendmail.  In addition, all documentation of dtml-sendmail I have
seen does not talk about either Cc or Bcc.  Is there a way to do this?

Thanks in advance...

__
Jeffrey D. Peterson
Webmaster/Web  Web Applications Developer
Range TV  Broadband
1813 E. 3rd Ave.  Hibbing, MN 55746
[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 )



___
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] ZClasses and title property

2001-01-19 Thread Loren Stafford

"title" is a "reserved" property; i.e. most objects automatically get a
title property when you create them, but you are trying to add another
property with the same name. Either use the "built-in" title property or use
a different id for your title.

-- Loren

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf
Of Tim Moore
Sent: Friday, January 19, 2001 14:59
To: [EMAIL PROTECTED]
Subject: [Zope] ZClasses and "title" property


Let me start by introducing myself...My name is Tim Moore and I'm new
to the list and Zope in general.  I'm still figuring out how
everything works, so forgive me if I'm missing something basic here
:-)

I'm creating several ZClasses for the site I'm working on.  In one of
them I'd like to have a property called "title", but when I try to add
it, I get the following error:

Error Type: Bad Request
Error Value: The id "title" is invalid--it is already in use.

I'm confused, because this seems to happen even when I make a
bare-bones minimal class, but a few of the examples I've found on the
web site have ZClasses with title properties.

I'm using version 2.3b1...is this a recent change in behavior or am I
doing something wrong?  If this is a change, does this mean I have to
use a different property name, or is there some other way I can edit
this title property?

thanks,
--
Tim Moore

___
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] Using images as submit buttons

2001-01-18 Thread Loren Stafford

You might look into a javascript onClick this.submit. I haven't actually
done this yet, so I don't have the exact syntax at hand, but I'm sure you
could find it on one of the javascript sites.

-- Loren

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of
[EMAIL PROTECTED]
Sent: Wednesday, January 17, 2001 18:29
To: [EMAIL PROTECTED]
Subject: [Zope] Using images as submit buttons


Has anyone figured a reasonable way of getting multiple image submit
buttons for a single form? I tried

  input type="image" name="goMethod:method" src="go.png"

but that didn't work for obvious reasons.

  button value="submit" name="goMethod:method" type="submit"img
src="images/go.png"/button

didn't work under Netscape 4.75 - I didn't get a button on the form...

Suggestions? If nothing is suggested, I think I'll have to suggest that the
first form "be fixed". Ick.


Richard

--
Richard Jones
[EMAIL PROTECTED]
Senior Software Developer, Bizar Software (www.bizarsoftware.com.au)

___
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] FW: Variable sort and multiple sort in dtml-in

2001-01-18 Thread Loren Stafford



-Original Message-
From: Adam Karpierz [mailto:[EMAIL PROTECTED]]
Sent: Thursday, January 18, 2001 02:08
To: Loren Stafford
Subject: Re: Variable sort and multiple sort in dtml-in


- Original Message -
From: "Loren Stafford" [EMAIL PROTECTED]
To: [EMAIL PROTECTED]; [EMAIL PROTECTED]; [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Sent: Thursday, January 18, 2001 4:16 AM
Subject: Variable sort and multiple sort in dtml-in


 On 02 July 2000, Adam Karpierz, posted a patch that would allow an
 expression for the sort specification for the dtml-in tag. Did that patch,
 or something like it, ever find its way into the Zope core?

 I also seem to remember some discussion of sorting on multiple items (but
 can't find any trace of it in the archives). For example, in an employee
 directory, sort on employee name within department. Anyone know how?

Hi Loren

(sorry for my "approximate english":)

There is a good news in this matter.
I'v noticed that in Zope 2.3.0b1 was included stricte similar way
as my patch.
Only names of variables was changed:
My name of variable was sort-python, now exists  sort_expr
Additionally DC guys added reverse_expr variable.

Here is a example of use (from my patch but translated to use sort_expr)

dtml-call "REQUEST.set('sortstrvar', _.string.lower('tItLe')+','+'id')"

html
pre

1."Hardcoded"
===
dtml-in "objectItems(['Image'])" sort=title,id
dtml-var iddtml-var title
/dtml-in

2.Indirectly

dtml-in "objectItems(['Image'])" sort_expr="'title,id'"
dtml-var iddtml-var title
/dtml-in

3.Indirectly

dtml-in "objectItems(['Image'])" sort_expr="sortstrvar"
dtml-var iddtml-var title
/dtml-in

4.Indirectly

dtml-in "objectItems(['Image'])"
sort_expr="_.string.lower('tItLe')+','+'id'"
dtml-var iddtml-var title
/dtml-in

/pre
/html


 I'm trying to provide user-specified sorting on the records I pull from a
 SQL database. When the user specifies sorting on Department, I assume he
 wants the records order by Name within each department, but I can't see
how
 to do that with ZSQL or dtml-in.

User would specify multiple keys sort (dr Lazarus patch which is included
to core from Zope 2.2.2 (?))
eg:

dtml-call "REQUEST.set('usersort', 'department,name')"

html
pre

dtml-in recordset sort_expr="usersort"
dtml-var departmentnbsp;dtml-var name
/dtml-in

/pre
/html

But best news for you is that sort_expr patch may be very
simply implemented for Zope 2.2.4 and 2.2.5
Simply copy the file:
Zope230b1/lib/python/DocumentTemplate/DT_In.py
to
Zope224|5/lib/python/DocumentTemplate/DT_In.py
thats all you need :)
It is possible because nothing else except sort_expr patch
was changed in this file, without dependences and influences
for other pieces of Zope

Best Regards

Adam

--
Adam Karpierz
[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] Setting the sort var in dtml-in ...sort=sortVar

2001-01-18 Thread Loren Stafford

See the concurrent thread "Variable sort ..."

-- Loren

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of Max M
Sent: Wednesday, January 17, 2001 15:58
To: Zope@Zope. Org
Subject: [Zope] Setting the sort var in dtml-in ...sort=sortVar


Does anybody know if it is possible to programatically set the sort
parameter in something like: dtml-in getAllComments sort=fwd_thread

It's the fwd_thread in "sort=fwd_thread" i want to set via dtml to avoid:

dtml-if "sortBy=='fwd_thread'"
dtml-in getAllComments sort=fwd_thread
Do sorted stuff
/dtml-in
dtml-elif "sortBy=='author'"
dtml-in getAllComments sort=author
Do sorted stuff
/dtml-in
etc.
etc.
/dtml-if

Or alternativley, is it possible to use the sort from dtml-in in a Python
Product as a method on the list that getAllComments() returns?

Yes I could roll my own but it would be easier to use Zope's, if I knew how
to.

regards Max M

Max M. W. Rasmussen,Denmark.   New Media Director
private: [EMAIL PROTECTED] work: [EMAIL PROTECTED]
-
Specialization is for insects.  -  Robert A. Heinlein


___
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] Variable sort and multiple sort in dtml-in

2001-01-17 Thread Loren Stafford

On 02 July 2000, Adam Karpierz, posted a patch that would allow an
expression for the sort specification for the dtml-in tag. Did that patch,
or something like it, ever find its way into the Zope core?

I also seem to remember some discussion of sorting on multiple items (but
can't find any trace of it in the archives). For example, in an employee
directory, sort on employee name within department. Anyone know how?

I'm trying to provide user-specified sorting on the records I pull from a
SQL database. When the user specifies sorting on Department, I assume he
wants the records order by Name within each department, but I can't see how
to do that with ZSQL or dtml-in.

-- 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] Z-Commerce components

2000-12-28 Thread Loren Stafford


Check out: http://www.codeit.com/codeit/964459526/index_html

-- Loren

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of Jason
Cunliffe
Sent: Wednesday, December 27, 2000 16:10
To: [EMAIL PROTECTED]
Subject: [Zope] Z-Commerce components


Hi

Looking for an e-commerce tool to use for a Zope-based site for artists to


___
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-dev] Xron fragility

2000-10-12 Thread Loren Stafford


From: "Kapil Thangavelu" [EMAIL PROTECTED]


[snip]
   Xron has a single dispatcher thread. This thread knows how long to
sleep
   for until the next job needs to run.

 this model has problems when new jobs (for immeadiate execution) are
 entered after the system sleeps. i think it should it taken into
account
 that people will use this dispatching thread to achieve async
operations
 on a request, and that these might need to be done immeadiately.


This is not (or should not be) a problem in current Xron design. The
Dispatcher wakes up early if the Schedule catalog is changed.

-- Loren




___
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] Xron fragility

2000-10-12 Thread Loren Stafford

  What if you want a small job to be done every 30 seconds?

 I generally don't... I'm satisfied with cron granularity, although
others
 might not be.  Do you have this requirement?

I thought a little about the granularity issue and decided to go with
the most general solution. I have no requirement for 30-second
intervals, but I wanted to avoid support requests from those who might
have such a need.

Also, I have no need for large numbers of scheduled methods. But I used
a heavy-duty data structure (Catalog) and the sleeping dispatcher model,
just so there would be no arbitrary limits that would cause me support
headaches later.


It uses Client.py to run a job.
  
   Why is this?  This doesn't make any sense to me on its face.  Why
not
 just
   call the method from a separate thread?
 
  Which separate thread? Do you create a new ZODB thread? That sounds
as
  if it might use quite a few resources.
 
  Is there a Zope API for making ZODB threads call methods on objects,
as
  signalled by other threads? I'm guessing the easiest way to do that
is
  to use Client.py to make a new http request.


Yes, using Client.py was the easiest way to do that. The biggest problem
with Client.py is its dependency on HTTP. If your server is set up to
only accept HTTPS, then you can't use Xron -- not a desirable trade-off.
We need another mechanism that achieves the same goal -- simulating the
environment of a request -- without going all the way back to the
socket.

-- Loren



___
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] Future of Xron and method scheduling in Zope

2000-10-12 Thread Loren Stafford

I would be happy to turn development of  Zope scheduling capabilities
over to someone else, because I currently have no demand for scheduling
capabilities and am not actively working on Xron.

This could take any of the following forms:

1.  Transfering Xron to another developer. For historical reasons, Xron
uses GPL.

2. Starting a new product from scratch, without reference to the Xron
product. The new product could carry a different license. I would be
happy to give up the Xron name, in this case, if anyone wanted it for
the new product.

3. Building scheduling capabilities into Zope core.

Any takers?

-- Loren



___
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] Should I use ZODB or not ?

2000-09-19 Thread Loren Stafford

From: "Jerome Alet" [EMAIL PROTECTED]



[snip]
 Our needs are to store hundreds, and possibly thousands of MPEG2 and MPEG4
 (generally short) video movies, MP3 audio files, JPEG images, etc...

[snip]

 I see 5 solutions:

 1 - store both files and their associated datas in ZODB
 2 - store files in the filesystem and datas in ZODB
 3 - store files in the filesystem and datas in an RDBMS
 (use Zope only for the presentation of files and datas)
 4 - store files in ZODB and datas in an RDBMS.
 5 - don't use Zope at all because it's not appropriate.


In general, large file uploads thru HTTP are clumsy. The browsers don't
provide progress indicators. Broken connections occur due to timeout under
network congestion but the browsers don't handle broken connections well.
And (as far as I can tell) the entire request (including the entire file) is
buffered in the OS swapspace. Some site I saw recently (was it xdrive? I'm
not sure) uses client-side Java to manage the upload.

I chose #2 for a similar application and ran into these additional issues:

1. A file upload done thru Zope into the filesystem passes thru a temporary
file. This increases slightly the apparent upload time, while you copy the
file to its final destination. And, you must also ensure that the partition
where temporary files are placed has enough space for the maximum file size.

2. You must also decide how you are going to serve the file. Since it's in
the file system, you could serve it directly thru Apache (perhaps thru a
redirect initiated by Zope), thereby avoiding occupying a Zope thread for a
long time for every downlaod. But if you take this approach, you must
somehow make Apache apply the same access control to the file that you have
in Zope. This can be done, but is an added complication.

-- My .02
-- 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 )




[Zope] Re: Scheduling Xron event reports TypeError

2000-09-08 Thread Loren Stafford

From: "Dwayne Morrison" [EMAIL PROTECTED]

 Hi,

 Sorry to mail you directly instead of posting to the zope group, but my
 posts are bouncing from egroups.com.

egroups is just a mirror. You have to post to [EMAIL PROTECTED] You can join
[EMAIL PROTECTED] from http://www.zope.org/Resources/MailingLists .


 Anyway, I'm having trouble scheduling events with Xron 0.0.9. I try to
 create a scheduled event as described in the doc:

dtml-with "manage_addProduct['Xron']"
dtml-call expr="manage_addXronDTMLMethod(
this(),
'SchedMethodId1',
'Scheduled Method 1 Title',
 file = 'Content-Type: text/plain\n\nBANG!!!',
 executeAt = _.DateTime()+14
  )"
/dtml-with

 When executed within a DTML method, the code reports this error:

Error Type: TypeError
Error Value: keyword parameter redefined

 I found that the 0.0.9 version of Xron added a new parameter,
 periodDays, to the method. Adding that produced the same error
 message. I tried naming all parameters also to no avail. Any
 suggestions would be greatly appreciated.

 Environment:
 Zope version: Zope 2.2.0 (binary release, python 1.5.2, solaris-2.6-
 sparc)

 Thanks in advance,


The above method works on Zope 2.1.3 but not on Zope 2.2.0. I don't know why
there should be a difference. I will check into it and let you know what I
find.

Maybe someone else on the list has a ready answer?

-- 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] ZClass for PDFs

2000-09-07 Thread Loren Stafford

From: "Timothy Wilson" [EMAIL PROTECTED]


 On Thu, 7 Sep 2000, Tim Cook wrote:

  Timothy Wilson wrote:
  
   I'd like to make a large number of PDF files available for download
from my
   site. HTML versions of the files will also be available for online
viewing.
  
   I could certainly include the PDF files as regular file objects or I
could
   create a ZClass specifically for PDF files.
  
   I suspect that this question may be of general interest, so I'm asking
for
   comments about the pros and cons of either approach.
  
 
  Does this not do what you want?
 
  http://www.zope.org/Members/gaaros/ZpdfDocument

 Thanks for the pointer.

 It doesn't appear that the ZpdfDocuments is what I'm looking for.
 ZpdfDocument seems to render PDF on the fly from structured text or HTML.
I
 was interested in simply storing an existing PDF file in the ZODB and
making
 it available for download.

 Is there a reason to make a PDF ZClass? Would it make things easier?

 -Tim


There's an example of a PDF ZClass at
http://www.zope.org/Members/lstaffor/zProperties. If all you do in the class
is add simple properties as in this example, the arguments are in favor of
making a ZClass boil down to:

1. You can enforce the presence of certain properties.
2. In your navigation methods, you can use the metatype to distinguish PDF
files from other files and thereby treat them differently.
3. You can help content managers handle PDF files in a consistent manner.

...worthwhile, but not all that compelling arguments.

On the other hand, once you have a separate class, it's easier to add
functionality; for example,

1. Automatically catalog the content of the PDF by running it thru some
converter (like XPDF),
2. Extract the document properties from the PDF identification block.
3. Provide an alternative byte-serving access to large PDFs.

-- HTH
-- 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] Non-blocking MailHost

2000-09-04 Thread Loren Stafford

One way to start an asynchronous job in Zope is with the Xron product.
Instead of sending the email, you create a Xron scheduled method to perform
that task. If you specify a trigger time of "now" (or any time in the past),
the scheduled method will execute (almost) immediately in a separate Zope
thread. Or you could specify a later time for all emails, thereby
effectively batching them. You can store as much context as you need in the
acquisition path or properties of  the scheduled method. Anything written to
STDOUT by the scheduled method will be stored in the log file, so you can
easily log any problems with sendmail.

http://www.zope.org/Members/lstaffor/Xron

-- HTH
-- Loren



- Original Message -
From: "Richard Taylor" [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: September 04, 2000 08:11 AM
Subject: Re: [Zope] Non-blocking MailHost


 I think what people have in mind (correct me if I am wrong) is
 something that will accept messages (for posting to the mailhost at
 some time in the future) and then immediately return. I guess it would
spawn
 another process/thread to do the posting asynchronously.

 The problem, as I see it is how to handle an error with the
 posting. The user who submitted the mail is now long gone so it must
 be left to an administrator to pick up the pieces.

 Perhaps the posting routine could accept a user (developer) provided
 exception handler that gets called if a posting fails.

 It maybe better to just hand this off to a completely separate program
 rather than try to handle it within a zope thread.

 Richard

 [EMAIL PROTECTED] writes:

  Chris,
 
  Out of curiosity, what exactly is a non-blocking MailHost?
 
  On Mon, Sep 04, 2000 at 09:31:15AM +0100, Chris Withers wrote:
  
   What we really want is a non-blocking MailHost.
  
   Anyone know how or want to write one?

 ___
 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] 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] Newbie question: FORM processing in Zope.

2000-08-28 Thread Loren Stafford



A great resource for newbies is the collection of How-To's
http://www.zope.org/Documentation/How-To (or better yet:
http://www.zope.org/Members/AlexR/tips/howto_list where you can use browser
search to find what you need).

Search for "forms" and you will see, for example:

http://www.zope.org/Members/jules/smarterforms_html

In short, the methods of Zope objects are all "CGI scripts". For the
"action" of a form, you supply the url of a form-handling method of some
Zope object you have created. When that method runs, form fields are stored
in the dictionary (hash, to you) that implements the namespace for the
request. You access them as simple DTML variables: e.g.

dtml-var form_field_name

If you want to send the value of that form field on to another form, you do
it much the same as in Perl -- you code a hidden form field and assign it
the value dtml-var form_field_name.

-- Hope that helps
-- Loren

- Original Message -
From: "Amit Redij" [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: August 28, 2000 04:45 AM
Subject: [Zope] Newbie question: FORM processing in Zope.



 hi,

 I am a Perl/CGI programmer, trying out Zope.
 I am confused right now about
  HOW TO process FORM variables?
 and most important thing is
 how to validate form inputs.(like same thing is best done in PERL using
 regex)

 that is, if I have a html having some form variables and a submit
 button. I click on the submit button. it should call some script..right?
 My question is how to pass values from one script to another. how is
 this done in Zope?

 thanks a lot in advance.

 regards
 Amit

 
  .--.
 |o_o |
 |\_/ |
//   \ \Amit Redij
   (| | )   mailto:[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 )




___
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] Sub Class Question

2000-08-27 Thread Loren Stafford

From: "R. David Murray" [EMAIL PROTECTED]


 On Sat, 26 Aug 2000, Loren Stafford wrote:
def index_object(self):
  if self.nextEventTime() is not None:
  CatalogAware.index_object.im_func(self)
  # see Python Reference Manual "The standard type hierarchy"
  # for the built-in type im_func

 I realize this is a Python and a not a Zope question, but
 what is the difference between

   CatalogAware.index_object.im_func(self)

 and

   CatalogAware.index_object(self)

 ?

 --RDM


Here's what MJ told me about that case. I'm not sure it applies to your
case. Did you try it? Did it work?

-- Loren

- Original Message -
From: "Martijn Pieters" [EMAIL PROTECTED]
To: "Loren Stafford" [EMAIL PROTECTED]; "zope-dev"
[EMAIL PROTECTED]
Sent: March 01, 2000 11:57 AM
Subject: [Zope-dev] Re: What is im_func?

 From: "Loren Stafford" [EMAIL PROTECTED]
  Could you elaborate on what im_func is and what it's role is here.
 
  # Only index if nextEventTime returns something
  def index_object(self):
  if self.nextEventTime() is not None:
  CatalogAware.index_object.im_func(self)

 im_func is a part of Python introspection. It is the pure function
 definition of a class, not bound to that class, so I can pass in an
 alternate self.

 I am trying to call a superclass method here, and normally
 CatalogAware.index_object() would suffice. But because of Extension
Classes,
 Python gets confused as to what is a class method, and what is a regular
 function. It will accuse me of calling an unbound method, which of course
I
 am not. I circumvent this by calling the unbound function, and passing in
 self explicitly.

 Martijn Pieters



___
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] Sub Class Question

2000-08-26 Thread Loren Stafford

I'm not sure if this is the same situation I encountered in Xron's
XronDTMLMethod.py, where I'm overriding CatalogAware's index_object method.

  # Only index if nextEventTime returns something
  def index_object(self):
if self.nextEventTime() is not None:
CatalogAware.index_object.im_func(self)
# see Python Reference Manual "The standard type hierarchy"
# for the built-in type im_func

-- HTH
-- Loren

- Original Message -
From: "Daniel Rusch" [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: August 25, 2000 02:51 PM
Subject: [Zope] Sub Class Question


 I've created a BasicMethod which is derived from the DTMLMethod.
 everything works great until I try to have the sub class's
 (BasicMethod)  __call__ method call the super class's (DTMLMethod)
 __call__ method.

 class BasicMethod(DTMLMethod):
 """BasicMethod objects are DocumentTemplate.HTML objects that act
as methods whose 'self' is the BasicMethod itself."""

 meta_type='Basic Method'


 def __call__(self, client=None, REQUEST={}, RESPONSE=None, **kw):
 print 'Sub Class __call__'
 DTMLMethod.__call__(self, client, REQUEST, RESPONSE, kw)

 Globals.default__class_init__(BasicMethod)


 when I view the BasicMethod in Zope, I get:
 Error Type: TypeError
 Error Value: too many arguments; expected 4, got 5


 I believe that I need the self arg, if I remove it I get an unbound
 python method error.

 Any thoughts???

 DR

 ___
 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] From date to timestamp

2000-08-26 Thread Loren Stafford

From: "Peter Be" [EMAIL PROTECTED]

 I managed to go from timestamp to date with
 dtml-var "ZopeTime(967322055)" fmt="%H:%M"

 But how do convert a date to timestamp?
 I.e. from say: "27/08/00 23:59" to 967322xxx?
 All I know to begin with is the day, month and year.

 Would be nice if I can do this in DTML straight away.
 Is it time.mktime something?

It's DateTime(), defined and documented in
../lib/python/DateTime/DateTime.py.

-- 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] ZClass Date Fields

2000-08-24 Thread Loren Stafford

I don't know of any bug that would produce this kind of behavior. It's more
likely a problem in communication between the add form and the method
invoked by that form. Can you show us the DTML for both? Then we can
probably see what's going wrong.

-- Loren

- Original Message -
From: "Craig" [EMAIL PROTECTED]
To: "Loren Stafford" [EMAIL PROTECTED]
Sent: August 24, 2000 07:05 AM
Subject: Re: [Zope] ZClass Date Fields


 On Wed, Aug 23, 2000 at 08:01:54PM -0700, Loren Stafford wrote:
  I think what you need is here:
 
  http://www.zope.org/Members/lstaffor/zProperties
 

 This is what I followed. I used a different file type than PDF for my
 example, but I named the date property the same (pub_date) and when I
create
 a new one, it gets created with pub_date set to 1970/01/01. My co-worker
 also followed your tutorial and had the same problem. Could this be a bug
in
 Zope

  -- Loren
 
  - Original Message -
  From: "Craig" [EMAIL PROTECTED]
  To: [EMAIL PROTECTED]
  Sent: August 23, 2000 07:32 PM
  Subject: [Zope] ZClass Date Fields
 
 
   I'm sure you've heard this question before, so bare with me. I went
  through
   the ZClass tutorial and got everything working right except Date
  properties.
   Lets assume, for example, that my ZCLass is called CDClass. When I
create
  a
   new CDClass instance (using the addForm), it always uses the default
date
   for Date properties instead of the ones I've entered in the form. A
   co-worker of mine has had the same problem but we have not yet
discovered
   why. Thoughts? Solutions?
  

 Later,
 --
 \ Craig "Cowboy" McDaniel
 /_\ Software Engineer
 /_/_\ Internet Tool  Die
 /_/_/_\ [EMAIL PROTECTED]
 /_/_/_/_\ (502) 584-8665 ext 108



___
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 do I find out about cookies?

2000-08-24 Thread Loren Stafford

From: "Jean Jordaan" [EMAIL PROTECTED]
 It looks like I'm going to be using cookies now, and I don't find any
 How-To on cookies. What's the most instructive place to look? "UTSL" is
 fine as an answer, especially if it points me somewhere, and even more
 if it's DTML source ..

 The *ZQR* is a bit too cryptic for me.

First you must understand cookies independent of Zope:

http://home.netscape.com/newsref/std/cookie_spec.html

Then Zope's interface to them will be easier to understand:


The *DTML Ref* has a bit more::

 8. Dictionaries are objects that support looking of data by name
 (e.g. REQUEST.cookies['CUST_ID'] to look up a cookie named CUST_ID).
 Dictionaries have has_key methods for checking whether a dictionary
 contains a value (e.g. REQUEST.cookies.has_key('CUST_ID') ) and
 methods keys , values , and items , for updating lists of dictionary
 keys, values, and key-value pairs (e.g. REQUEST.cookies.keys() to
 obtain a list of cookie names).

 .. but I don't understand yet how 'keys', 'values' and 'items' are going
 to help me *update* the lists -- it seems to refer only to querying
 them, AFAICS ..

Search for "cookie" a little further in
http://www.zope.org/Members/ZQR/zqr/normal and you will find not only
REQUEST.cookies but also RESPONSE.setCookie().

-- 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] ZClass Date Fields

2000-08-23 Thread Loren Stafford

I think what you need is here:

http://www.zope.org/Members/lstaffor/zProperties

-- Loren

- Original Message -
From: "Craig" [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: August 23, 2000 07:32 PM
Subject: [Zope] ZClass Date Fields


 I'm sure you've heard this question before, so bare with me. I went
through
 the ZClass tutorial and got everything working right except Date
properties.
 Lets assume, for example, that my ZCLass is called CDClass. When I create
a
 new CDClass instance (using the addForm), it always uses the default date
 for Date properties instead of the ones I've entered in the form. A
 co-worker of mine has had the same problem but we have not yet discovered
 why. Thoughts? Solutions?

 Later,
 --
 \ Craig "Cowboy" McDaniel
 /_\ Software Engineer
 /_/_\ Internet Tool  Die
 /_/_/_\ [EMAIL PROTECTED]
 /_/_/_/_\ (502) 584-8665 ext 108

 ___
 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-dev] Xron and security

2000-08-22 Thread Loren Stafford

Thanks, Steve.

I have few questions below  8-) (I'm always better with questions than
answers.)

-- Loren

From: "Steve Alexander" [EMAIL PROTECTED]
 Hi Loren,

  I'd be glad to listen to well considered proposals for how Xron should
  handle security.

 Consider this a "straw man".


 On installation, Xron creates a user in the root user folder called
 "XronUser".

 Xron is resonsible for setting this user's password. Therefore, it is
 known to both the Xron product, and also to the root user folder.

 When a Xron method is run, there is a property that indicates whether it
 is called anonymously, or authenticated as XronUser.

Is there a good reason not to always pass authentication in the request? The
authentication property would have to be stored in the Schedule catalog, and
I'd like to keep the Schedule as small as possible.

 The Xron product could change the password of XronUser every day to a
 new random value.

That's more than folks do to maintain secrecy of the "superuser" password.
Is the extra trouble worthwhile?

 The domains associated with XronUser could be just localhost.localdomain
 (not sure about this). Or based on whatever the machine's host-name is
 (probably better).

At a virtual-hosted site, how could Xron know what the host-name is?

 Site administrators can assign local roles to XronUser as necessary.

 If Phillip Eby's proposed changes to the access file get included in
 some future version of Zope, XronUser could be included as one of these
 bootstrap users by simply writing to a file.

 --
 Steve Alexander
 Software Engineer
 Cat-Box ltd
 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] Xron and Security [was ZScheduler and Pack]

2000-08-22 Thread Loren Stafford

From: "Marcus Mendes" [EMAIL PROTECTED]


 Is it a security risk to leave the Zscheduler pack my Data.fs?

I don't have an answer, but I can clarify the risk. We can use packing
Data.fs as an example application, but the question about security is more
general.

Xron (formerly ZScheduler) does not currently provide any features that deal
with security. Scheduled methods are called thru the Client.py interface
(i.e. by handing a URL to Zope as if it had come from a browser client).

For example, suppose you have a scheduled method "Packer" in the root folder
that calls the management method that packs your database. The URL that the
Dispatcher of Xron uses to execute that method is simply:

   http://www.mysite.com/Packer/trigger

Client.py is capable of passing authentication information in the request;
but because Xron does not (yet) supply authentication information, a
scheduled method must be executable by an unauthenticated user.

If the scheduled method performs any privileged functions, then the method
must have proxy roles that give it sufficient privilege. (I'm not sure what
role is required for manage_pack, but there must be one.)

Therefore, any user (who happens to know about your method and about Xron's
calling convention) can pack your Data.fs simply by keying
http://www.mysite.com/Packer/trigger into a browser.

Suppose an unscrupulous person (who happens to know about your method and
about Xron's calling convention) created a program that would make a request
to http://www.mysite.com/Packer/trigger once every N seconds (easy to do
with Xron!). Could that bring your system to its knees? ...any worse so than
any other repeated request? I don't know the answer. If I were you I'd try
it out.

Can anyone see any other security vulnerabilities here?

I'd be glad to listen to well considered proposals for how Xron should
handle security.

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




[Zope] Re: Xron test

2000-08-18 Thread Loren Stafford

Nick,

Two other Zopistas reported similar problems. Both succeeded eventually in
getting Xron started, but we didn't succeed in diagnosing the problem, nor
in determining precisely how to work around it. I myself haven't been able
to reproduce the problem.

The problem seems to occur only on Linux, but it does not always occur. Some
users have successfully started Xron on Linux with no problem. The problem
seems to have to do with contention for a lock on ZODB. Did you see any log
or console message that would confirm this?

One user went to the console and killed all the Zope processes that were
running at the time, then restarted Zope from the command line. The second
time, Zope started up correctly with Xron.

Another user thought that he had mistakenly tried to start Zope while logged
in as root. When he restarted as a different user, Zope started up with Xron
correctly. I suspect that the user was not relevant to the Xron problem (it
is normal in some installations to start as root), but that the restarting
was the key.

One user thought that the monitor process contributed to the lock
contention. I don't know, but it might be worthwhile to try to restart Zope
without the monitor (changing the start-up options to disable the monitor).

The problem seems to relate to Xron's creating the Schedule catalog the
first time the Xron product is loaded during Zope start-up. If you succeed
in creating the Schedule one time, the problem will not recurr, as Xron will
just use the existing Schedule.

I hope that helps you get started. Let me know how it goes. I'll copy this
email to the zope list in hopes that someone else can shed some light on the
problem.

-- Loren

- Original Message -
From: "Nicholas Lo" [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: August 18, 2000 12:41 AM
Subject: xcron test


 Hi Loren,

 I have a problem with installing Xron 0.9 onto my machine. Currently,
 I'm running SuSE Linux 6.4 on a 600MHz/128Mb/20Gb PC. I have followed
 the release note and set the STUPID_LOG_FILE environment variable to
 point the log file, and Xron itself is, of course, resides in the
 /Products directory. When I start Zope, the console looks okay. However,
 the browser keeps on loading and loading and could not show the Zope
 management screen. I have also tried Xron on my notebook, which is
 running Win98. Everything works just fine. I just wonder what's gone
 wrong.

 Thanks.

 Nick



___
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] sending mail slow?

2000-08-18 Thread Loren Stafford

From: "Chris Withers" [EMAIL PROTECTED]

 I've noticed that sending mail from within Zope the sendmail tab or
 mailhost.send() is very slow (like it adds a few seconds to the time it
 takes to get a page back from a post).

 Why is that? how can I make it faster?

 I'd thought about having the actual mail sending done in a different
 thread/process but I don't know how I'd do that or whether it'd be worth
 doing.

You could use Xron to schedule sending the email. You could schedule it for
later or for "now". Either way the email would be sent asyncronously from
the original request. (But check out another email dated today titled "Xron
test").

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




[Zope] Re: concerning Xron with DA

2000-08-17 Thread Loren Stafford

From: "Nicholas Lo" [EMAIL PROTECTED]

 I just wonder if Xron works with ZSQL Methods.
 I know that ZSQL Methods only works with the request thread.
 Thanks.

I can think of no reason Xron would not work with ZSQL Methods; but I
haven't tried it, because I have no SQL in my applications. Xron's
dispatcher thread does not directly run scheduled methods; it uses Client.py
to fabricate a request. So the scheduled method runs in a request thread,
just as an ordinary client request. Scheduled methods are a subclass of DTML
Method, so the scheduled method would have to call your ZSQL Method.

There is currently no way to pass parameters to the request. If the ZSQL
Method requires parameters, the scheduled method must supply them from its
context.

Would you like to be the first to try it out and report back to the mail
list?

Or has someone else already tried this?

-- 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] looking for DTML Property examples

2000-08-17 Thread Loren Stafford

http://www.zope.org/Members/lstaffor/zProperties falls just a little short
of what you're asking for. There's been a lot of discussion on the subject
recently on this list. Perhaps you could search back, piece together the
collected wisdom, and write the next chapter on Properties.

BTW, properties for ZClasses and properties of builtin objects are a little
different. ...Another issue that needs clarification.

-- Loren


- Original Message -
From: "Jason Cunliffe" [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: August 17, 2000 02:36 PM
Subject: [Zope] looking for DTML Property examples


 Hello

 I am looking for some basic examples on using Properties in Zope.
 For example: How-To write methods which put and get properties, and with
 these examples of accessing properties via URLs directly as wellas via
 custom methods.

 There must be a ton of examples _somewhere_, but somehow, I can't seem to
 find them and th ORA book is not out yet [praying hard for great index and
 LOTS of small examples thourhgt the text].

 Thanks in advance for any links

 - Jason
 
 Jason CUNLIFFE = NOMADICS.(Interactive Art and Technology).Design Director



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

2000-08-15 Thread Loren Stafford


From: "Daniel Rusch" [EMAIL PROTECTED]

 I've created a product, installed it and it appears on the Product
 Management at /Control_Panel / Products list.

 The question is how do I get it to appear in the drop down of Available
 Objects?


You have to register the class it defines. If you want the class to be
subclassable by ZClasses, you also have to registerBaseClass. Here's an
example copied from the __init__.py of my Xron product:

  context.registerClass(
XronDTMLMethod.XronDTMLMethod,
permission = 'Add Scheduled Method',
constructors = (
  XronDTMLMethod.manage_addXronDTMLMethodForm,
  XronDTMLMethod.manage_addXronDTMLMethod),
icon = 'www/Event.gif')
  context.registerBaseClass(XronDTMLMethod.XronDTMLMethod)
  context.registerHelp()

-- HTH
-- 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] Another Product question

2000-08-15 Thread Loren Stafford

All modules published by Zope must have a "doc string" i.e. a Python comment
defining the content before any other Python code. For example:

""" Doc string for Frame Work Doc product """

import string

# etc

-- Loren

- Original Message -
From: "Daniel Rusch" [EMAIL PROTECTED]
To: "Loren Stafford" [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Sent: August 15, 2000 12:20 PM
Subject: [Zope] Another Product question


 Thanks,

 I had made a small misspelling which did not generate any errors but which
 hosed the Product.

 New problem,

 My product appears on the Product Management at /Control_Panel / Products
 page and in the drop down of Available Objects. I select my Product from
the
 drop down
 and I get my add product page. But when i fill out the page and click add,
I
 get the following error message:


Zope Error

Zope has encountered an error while publishing this resource.

Debugging Notice

Zope has encountered a problem publishing your object.

Missing doc string at:
 http://hal9000:8080/manage_addProduct/FrameWorkDoc/manage_addFrameWorkDoc


Troubleshooting Suggestions

 The URL may be incorrect.
 The parameters passed to this resource may be incorrect.
 A resource that this resource relies on may be
encountering
 an error.

For more detailed information about the error, please refer to
 the HTML source for this page.

If the error persists please contact the site maintainer. Thank
 you for your patience.


 Traceback (innermost last):
   File /home/Zope-2.1.6-linux2-x86/lib/python/ZPublisher/Publish.py, line
 214, in publish_module
   File /home/Zope-2.1.6-linux2-x86/lib/python/ZPublisher/Publish.py, line
 179, in publish
   File /home/Zope-2.1.6-linux2-x86/lib/python/Zope/__init__.py, line 202,
in
 zpublisher_exception_hook
   File /home/Zope-2.1.6-linux2-x86/lib/python/ZPublisher/Publish.py, line
 151, in publish
   File /home/Zope-2.1.6-linux2-x86/lib/python/ZPublisher/BaseRequest.py,
 line 348, in traverse
   File /home/Zope-2.1.6-linux2-x86/lib/python/ZPublisher/HTTPResponse.py,
 line 521, in debugError
 NotFound: (see above)

 Any thoughts ???

 Dan

 Loren Stafford wrote:

  From: "Daniel Rusch" [EMAIL PROTECTED]
 
   I've created a product, installed it and it appears on the Product
   Management at /Control_Panel / Products list.
  
   The question is how do I get it to appear in the drop down of
Available
   Objects?
  
 
  You have to register the class it defines. If you want the class to be
  subclassable by ZClasses, you also have to registerBaseClass. Here's an
  example copied from the __init__.py of my Xron product:
 
context.registerClass(
  XronDTMLMethod.XronDTMLMethod,
  permission = 'Add Scheduled Method',
  constructors = (
XronDTMLMethod.manage_addXronDTMLMethodForm,
XronDTMLMethod.manage_addXronDTMLMethod),
  icon = 'www/Event.gif')
context.registerBaseClass(XronDTMLMethod.XronDTMLMethod)
context.registerHelp()
 
  -- HTH
  -- 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 )


 ___
 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] ANNOUNCE: Xron alpha version 0.0.9

2000-08-14 Thread Loren Stafford

Shortly after posting this, I found a buglet that causes an error when you
edit a Xron DTML Method that was created before version 0.0.9.

I upload the fixed product without changing the version number.

-- Loren

- Original Message -
From: "Loren Stafford" [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: August 10, 2000 09:31 PM
Subject: ANNOUNCE: Xron alpha version 0.0.9


 Xron Version 0.0.9 Date: 2000/08/10

 1. Added simple rescheduling capability to the "reschedule" method. Now
you
 can make repetitive
  events without creating a subclass.

 http://www.zope.org/Members/lstaffor/Xron

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




[Zope] Re: Xron seems to not work

2000-08-14 Thread Loren Stafford


From: "Bill Anderson" [EMAIL PROTECTED]
  Bill,
 
  After the scheduled time, is there anything in the STUPID_LOG_FILE?
What?

 --
 2000-08-14T21:15:04 PROBLEM(100) Products.Xron.Loggerr
 Trigger event: http://telescop:8100/MakeDailyOrder
 Trigger time: 2000/08/14 13:15:00 US/Mountain
 Failed to trigger event.
 Type=bci.NotAvailable
 Val=argument 1: expected read-only character buffer, tuple found (File:
 http://telescop:8100/MakeDailyOrder/trigger Line: [])
 None None for None
 --
 2000-08-14T21:15:04 PROBLEM(100) Products.Xron.Loggerr Failed to disarm
 event


That's the Client.py bug (there's a proper patch here:
http://classic.zope.org:8080/Collector/1480/view).

-- 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] Re: Xron seems to not work

2000-08-14 Thread Loren Stafford

From: "Bill Anderson" [EMAIL PROTECTED]


 Loren Stafford wrote:
 
  From: "Bill Anderson" [EMAIL PROTECTED]
Bill,
   
After the scheduled time, is there anything in the STUPID_LOG_FILE?
  What?
  
   --
   2000-08-14T21:15:04 PROBLEM(100) Products.Xron.Loggerr
   Trigger event: http://telescop:8100/MakeDailyOrder
   Trigger time: 2000/08/14 13:15:00 US/Mountain
   Failed to trigger event.
   Type=bci.NotAvailable
   Val=argument 1: expected read-only character buffer, tuple found
(File:
   http://telescop:8100/MakeDailyOrder/trigger Line: [])
   None None for None
   --
   2000-08-14T21:15:04 PROBLEM(100) Products.Xron.Loggerr Failed to
disarm
   event
  
 
  That's the Client.py bug (there's a proper patch here:
  http://classic.zope.org:8080/Collector/1480/view).

 Applied. No Change. :(


Something fishy here. Probably you're not executing the module you patched,
or you patched the wrong line (there's two similar lines; only one gets
patched). I suggest you uncomment line 80 of Dispatcher.py ...

  #import pdb; pdb.set_trace()

... run in debug mode, and watch what happens in Client.py. I'm sure you'll
find the bug scurrying arond there, alive and well. You'll see an error
message similar to the one above from STUPID_LOG, but it'll show precisely
where it occurs.

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




[Zope] Xron Product Screenshots [was: Importable Xron]

2000-08-11 Thread Loren Stafford


 I have in a recent email to the mailing list urged all Product creators to
 include screenshots and/or demos of their products.


I'd like to put some screenshots the management pages in the README.txt of
Xron where they would illustrate that text that explains those pages.

Can you point to any examples of other products that do this effectively.

Authors often (well I do anyway) use the same README.txt for the README tab
of  Control Panel / Products and for the "Release Information" link on the
www.zope.org/Members  product page. Being able to use the same file makes
documentation easier for developers, and that's important; if documentation
is needlessly hard, it won't get done.

However, if I create image hyperlinks that work on
http://www.zope.org/Members/lstaffor/Xron/README.txt , they won't work in
the context of Control Panel / Products. I don't see to make links work
correctly in both places. Does anyone know how?

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




[Zope] Fw: [Zope] Can't get ZClient to work, zope 2.2.0

2000-08-11 Thread Loren Stafford



 From: "Bill Welch" [EMAIL PROTECTED]
 
 
  hit http://zope.carbonecho.com/forum/sepServe to see the error
  ('expecting read-only buffer...')
  
 
 This is a known bug. You need to install this patch to Client.py:
 
  #h.connect((self.host, self.port))
   h.connect(self.host, self.port)
 
  Restart Zope after installing.
 
 See http://classic.zope.org:8080/Collector/1480/view
 
 -- 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] Importable Xron

2000-08-10 Thread Loren Stafford

From: "Graham Chiu" [EMAIL PROTECTED]
 On Wed, 9 Aug 2000 14:45:58 -0700
  "Loren Stafford" [EMAIL PROTECTED] wrote:
  *This message was transferred with a trial version of
  CommuniGate(tm) Pro*
  Xron is alpha-level software, which means (among other
  things) that it is
  new, hasn't received a lot of use, doesn't have a lot
  ready examples, may be
  lacking documentation quantity or quality. If you want to
  use Xron in its
  current alpha state you must be willing to invest a
  little effort in
  learning to use the product. For my part, as developer of

 I think part of the problem is that there are increasing
 numbers of people with limited Zope knowledge, and an
 overwhelming number of Zope products without any indication
 of how difficult it is to use a particular product.

 Perhaps Zope product writers should rate their products with
 a difficulty scale.

I think only the users of the products could do that usefully. Developers
are biased. How about if DC puts a rating form on every product page on
www.zope.org, so that users can vote  ;^)  (Just kidding, really.)

 And regarding the original question, how difficult would it
 be to modify your Xron product so that the periodicity is an
 attribute of the product rather than having to sub class it?

Depends on what sort of periodicity your application needs -- and therein
lies the problem.

There are so many different needs that a built-in general purpose interface
for specifying periodicity is likely to be at least as complex and hard to
explain as a programmable interface.

Take the Unix command 'cron' for example. I've included its man page below.
Is that easy to understand? No way! Now imagine writing the Python/DTML code
to build a nifty point and click interface to it. Not this boy! Now, if you
or someone else wants to take on the challenge of building a cron-compatible
rescheduler interface, be my guest. I've done my part. You can subclass Xron
DTML Method.

Sure, it would be possible to create a simple property that selects Weekly,
Hourly, or OneTime. ...with maybe a corresponding check-box in the
management interface. As soon as I published a simple system like this, the
requests would start coming for more and more capabilites, and the interface
would grow without control. For example, suppose you want to add Monthly to
that list. Now you have to answer the questions "What kind of month --
calendar or accounting? ... which accounting system?" So, if I were going to
create this kind of interface, I'd do it in a subclass, anyway, so as not to
clutter up the base Xron product with something that is likely to change
frequently.

So how about this: I invite other developers to create rescheduler
sub-products for Xron.  If you create a rescheduler product, let me know
about it, and I'll link to it from the Xron product page. Your product could
be a Python product or a ZClass product. There's probably room for something
like "Simple Rescheduler for Xron", which would do Weekly, Hourly, and
OneTime; and "Cron for Xron" which would be a full cron-like interface; and
maybe a product of intermediate complexity. The "Simple Rescheduler" would
make a good first-time ZClass project. The developer would need to know how
to write a ZClass, how to handle PropertySheets in a ZClass, and how to use
DateTime.

Does this sound like a good plan or a bad one? Any takers?

-- Loren

=
man cron
=

 The format of a cron command is very much the V7 standard, with a
number
 of upward-compatible extensions.  Each line has five time and date
 fields, followed by a user name (with optional ``:group'' and ``/lo-
 gin-class'' suffixes) if this is the system crontab file, followed by
a
 command.  Commands are executed by cron(8) when the minute, hour, and
 month of year fields match the current time, and when at least one of
the
 two day fields (day of month, or day of week) match the current time
(see
 ``Note'' below).  cron(8) examines cron entries once every minute.  The
 time and date fields are:

   field allowed values
   - --
   minute0-59
   hour  0-23
   day of month  1-31
   month 1-12 (or names, see below)
   day of week   0-7 (0 or 7 is Sun, or use names)


 A field may be an asterisk (*), which always stands for ``first-last''.

 Ranges of numbers are allowed.  Ranges are two numbers separated with a
 hyphen.  The specified range is inclusive.  For example, 8-11 for an
 ``hours'' entry specifies execution at hours 8, 9, 10 and 11.

 Lists are allowed.  A list is a set of numbers (or ranges) separated by
 commas.  Examples: ``1,2,5,9'', ``0-4,8-12''.

 Step values can be used in conjunction with ranges.  Following a range
 with ``/number'' specifies skips of the number's value through the
 ra

Re: [Zope] Importable Xron

2000-08-10 Thread Loren Stafford

From: "Bill Anderson" [EMAIL PROTECTED]


 Loren Stafford wrote:
 ...
  So how about this: I invite other developers to create rescheduler
  sub-products for Xron.  If you create a rescheduler product, let me know
  about it, and I'll link to it from the Xron product page. Your product
could
  be a Python product or a ZClass product. There's probably room for
something
  like "Simple Rescheduler for Xron", which would do Weekly, Hourly, and
  OneTime; and "Cron for Xron" which would be a full cron-like interface;
and
  maybe a product of intermediate complexity. The "Simple Rescheduler"
would
  make a good first-time ZClass project. The developer would need to know
how
  to write a ZClass, how to handle PropertySheets in a ZClass, and how to
use
  DateTime.
 
  Does this sound like a good plan or a bad one? Any takers?


 I am actually working on a simple scheduling product based on Xron. Though
it wasn't originally intended for public
 consumption, I may be convinced to at least put it up for download.

Bill,

Can you tell us a little about your product? Where does it fall on the scale
from "Simple" to "Cron"?

I'm actually adding what you might call "Stupid Rescheduler" to the base
Xron product. A "periodDays" (type float) attribute that specifies the
reschedule interval in days and fractions thereof. Zero means "OneTime".
It's not much, but at least you'll be able to do some useful rescheduling
"out of the box", i.e. without subclassing.

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




[Zope] ANNOUNCE: Xron alpha version 0.0.8

2000-08-10 Thread Loren Stafford

Xron Version 0.0.9 Date: 2000/08/10

1. Added simple rescheduling capability to the "reschedule" method. Now you
can make repetitive
 events without creating a subclass.

http://www.zope.org/Members/lstaffor/Xron

-- 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] Client.py

2000-08-09 Thread Loren Stafford

See collector item #1480 http://classic.zope.org:8080/Collector/1480/view


- Original Message -
From: "Bak @ kedai" [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: August 08, 2000 11:08 PM
Subject: [Zope] Client.py


 hi all
 has anybody successfully used Client.py that ships with Zope-2.2.0?  i
can't
 seem to run it.  even on the command line.  i've searched the mailing
list,
 but to no avail

 this is what i did:
 python Client.py http://www.zope.org

 and here's the traceback.
 Traceback (innermost last):
   File "Client.py", line 639, in ?
 main()
   File "Client.py", line 632, in main
 headers, body = apply(f,(),kw)
   File "Client.py", line 221, in __call__
 raise NotAvailable, RemoteException(
 bci.NotAvailable: argument 1: expected read-only character buffer, tuple
 found (File: http://www.zope.org Line:
 [])
 None None for None

 what did i do wrong?  can i use Client.py from Zope-2.1.x?

 tia


 ___
 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] threading cont ...boundary=------------98A416F9F4157B1993D63C72

2000-08-09 Thread Loren Stafford

ZScheduler has been superceded by Xron

http://www.zope.org/Members/lstaffor/Xron

-- Loren

From: "Martijn Pieters" [EMAIL PROTECTED]


 On Wed, Aug 09, 2000 at 10:12:50AM +0800, Nicholas Lo wrote:
  In fact, I'm trying to use ZOPE to do some automation, eg. reminder
  emails, news clipping, or maybe some WAP applications as well. I want to
  make it able to schedule itselfs so as to better utilise resources, make
  ZOPE more or less real-time, and to prevent overloading or spam from the
  content source. Well, since ZOPE runs from source, I think we may extend
  it to do some remote control works as well. eg. redirect your fax at
  home to your email account, allow you to listen to your home voice
  mails, etc.

 Have a look at ZScheduler, which just just that. If not exactly what you
need,
 it will certainly show you how to access the Zope database from a seperate
 thread:

   http://www.zope.org//Members/lstaffor/ZScheduler




___
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] Importable Xron

2000-08-09 Thread Loren Stafford

Xron is alpha-level software, which means (among other things) that it is
new, hasn't received a lot of use, doesn't have a lot ready examples, may be
lacking documentation quantity or quality. If you want to use Xron in its
current alpha state you must be willing to invest a little effort in
learning to use the product. For my part, as developer of the product, I am
willing to guide you through the process on mailto:[EMAIL PROTECTED] and thereby
create a documentation trail here on the mailing list that others can use
and that can be distilled into more documentation and examples.

So if you are ready, so am I. But, for me to guide you, I will need to ask
you to be more specific about your experience level, what relevant documents
you have read, what specifically in the document you didn't understand, what
tutorials you have followed, what attempts you have made to use the product,
what errors resulted, etc.

First, to make repetitive events, you must create a ZClass. Have you read
the ZClass documentation and How-To's? Have you created a ZClass before? If
not, I recommend that you do so before we continue.

From: "Peter Bengtsson" [EMAIL PROTECTED]


 I want to use the Xron product but I don't understand how to use it.
 (http://www.zope.org/Members/lstaffor/Xron/)

 All this Zope Zen jargon makes me dissy. What I don't understand is where
 and why to put reschedules at certain places.

You have to create a ZClass that is just like Xron DTML Method class, except
that it calculates the time that the event will next occur based upon the
needs of your application. You create your ZClass in Control Panel /
Products. When you create your ZClass, you will be asked what classes to
base it on (subclass from); you must select Xron DTML Method.

If you do nothing else, your ZClass will behave exactly like Xron DTML
Method class. But you want it to do something different. You what it to
calculate the next time for the event. Xron DTML Method makes its default
calculation in the method 'reschedule'. You want to replace 'reschedule'
with your own calculation. You do that by adding a DTML method, named
'reschedule' to you new ZClass. There's a simple example in the README.txt
for Xron.

 Subclasses and DTML
 Methods...etc.

 Can you please include a importable zexp on the download page of Xron.

 I want to do one single simple thing for now.
 Send the dtml-var webmaster constant information about various site
stats.

Do you already have methods that gather the site stats?

 These should be sent weekly or hourly or monthly.

You could make a separate ZClass subclass of Xron DTML Method for  weekly
events, another for hourly events, and another for monthly events. Or you
could create a single subclass that determines whether to reschedule for
next hour, next week, or next month. It's your design decision. I'd
recommend starting with just "next hour", as a learning exercize. That way
it won't take more than an hour find out whether your application works.

 I also want to have more than one instance of Xron.

You probably don't want more than one instance of Xron. Xron contains three
major parts: the Schedule, the Dispatcher thread, the Xron DTML Method
class. Any single system needs only one Schedule and one Dispatcher thread.
What  you probably need are multiple instances of the Xron DTML Method class
or of the subclass you create. Each one of these instances would be a
procedure that you want to execute at specific times. Suppose, for example,
your subclass of Xron DTML Method is called "Weekly Event" and its
reschedule method calculates the next event time thus:

dtml-call "REQUEST.set('XronEventTime', REQUEST.XronEventOldTime +
7.0)"

Then, you would create Weekly Event objects (also called "instances") for
each action that you want to execute weekly. Each Weekly Event instance will
be executed by the Dispatcher once a week. What a Weekly Event object
actually does when executed is determined by the DTML content of that
instance. You could have one Weekly Event that gathers, site statistics. You
could have another Weekly Event that sends you an email reminding you to
take out the garbage.


 Can somebody give me examples. Especially how you set the date and time.
 (I have no experience of cron and I live in GMT+0)

Experience with cron will not help you with Xron -- they are only similar in
general purpose, not in details of implementation nor interface.

You (because you are in GMT+0) can enter dates like this

August 9, 2000 14:27:00 GMT

Most common unambiguous date formats are accepted; for example

Aug 9, 2000 14:27:00 GMT
2000/08/09 14:27:00 GMT
9 Aug 2000 14:27:00 GMT

Detailed documentation is in ../lib/python/DateTime/DateTime.py


 Grateful, Peter
 Peter Bengtsson - OD Consultancy


Glad to help.

-- Loren



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

Re: [Zope] How to prime a selection?

2000-08-04 Thread Loren Stafford



 Hi all
 
 I'm making a document class for a warehouse of papers.
 It's based on ZCatalogAware and ObjectManager (to wrap
 mainly PDFs and DOCs), and has fields:
 
   title   (string type)
   origin  (string type)
   format  No value for format_value.  
   typeNo value for type_value.  
 
 "format" and "type" are selections -- 
 
 1. where do I supply their initial values (filling in 
'format_value' and 'type_value')?
 2. is it possible to let a field offer presets and 
previously entered values, but to allow users to 
add new ones, which are remembered and offered to 
subsequent users?
 
 A RTFM-type answer to question 1. is perfectly OK, though a 
 page reference would be sorely appreciated.

http://www.zope.org/Members/lstaffor/zProperties




___
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] Python Product Tutorial

2000-08-04 Thread Loren Stafford

I don't know of any tutorial. ZScheduler creates a container (a subclass of
Catalog in fact), so you might use that code as a starting point. It doesn't
put other objects in the container, tho.

-- Loren

http://www.zope.org/Members/lstaffor/ZScheduler

- Original Message -
From: "Erik Enge" [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: August 04, 2000 08:47 AM
Subject: [Zope] Python Product Tutorial


 Hi.

 Are there any good Python Product tutorials that deals with creating a
 container (OFS.Folder.Folder will do) object and putting other objects
 within it?

 Thanks.

 ___
 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] How-To: Dropbox date entry for html forms

2000-08-03 Thread Loren Stafford


Your example in a How-To may well be useful. However, I think you have
maligned the DateTime method. It is quite flexible about the input formats
it accepts. Have you read the extensive documentation in
../lib/python/DateTime/DateTime.py?

-- Loren

- Original Message -
From: "Darran Edmundson" [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: August 03, 2000 12:49 AM
Subject: [Zope] How-To: Dropbox date entry for html forms


 In building my first Zope site and training content providers to use
 the management interface, I quickly encountered requests for an easier
 means of entering dates (as opposed to the default "1966/09/30" format).

 I've written up a quick How-to that contains a DTML utility method
 for incorporating droplist selectable dates in html forms.  Before
 I make it (more) public, I'd appreciate some feedback.  Any objections
 to the implementation?  What do you think about placing short
 utility methods in How-To's rather than Products?

  http://www.zope.org/Members/darran/select_date

 Cheers,
 Darran.

 ___
 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-dev] New Client.py bug(?) in 2.2.0 affects ZScheduler

2000-07-28 Thread Loren Stafford

In Zope version 2.2.0b3 Client.py calls connect in httplib (in two different
places) like this:

sock.connect(self.host,self.port)

In Zope version 2.2.0 (final) it's like this:

sock.connect((self.host,self.port))

In the latter case, Python complains:

   TypeError: 'argument 1: ..., tuple found'

Does anyone know what was the motivation for the change in the syntax for
the call to connect?

Should I drop this in the Collector?

-- Loren


___
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] Client.py prevents ZScheduler with SSL? (was: Zope.org feedback)

2000-07-28 Thread Loren Stafford

Moving this to zope-dev and changing title...

From: "Jim Sanford" [EMAIL PROTECTED]


 We have no http access to our site.

 It is a corporate Client Relationship Management, Job Tracking and Order
Processing, Production and Tracking system that is accessed
 from all over the world.

 I will send this to the list to see if any one else can provide help.


 From: Loren Stafford [EMAIL PROTECTED]

   From: "Jim Sanford" [EMAIL PROTECTED]
  URL: http://www.zope.org/Members/lstaffor
  ZScheduler uses Client.py.
 
  Would it be correct to say that if my entire site is only accessible via
 SSL (https) that ZScheduler will not work?

 I hadn't thought about this before, so you probably know more about it
than
 I do. But given that the python lib that Client.py uses for http
 (httplib.py) doesn't support https, then you're right.

 Solutions?

 1. Permit http traffic to your site if it comes fromt the same IP and is
for
 URLs that end in "/trigger". I suppose that IP spoofing makes this
something
 of a security hole. How bad?

 2. Enhance either Client.py or httplib.py to support at least enough https
 to get the job done. I know nothing about this. Is it reasonably doable?
Is
 there a Zopista willing and able to do it?

 3. ?

 -- Loren



___
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] Moving site from dev to prod.

2000-07-28 Thread Loren Stafford

In the "utilities" directory there is a program that converts from bbb to
fs. Sorry, I don't remember which one or how it works, but this should point
you in the right direction.

-- Loren

- Original Message -
From: "Jeff Nielsen" [EMAIL PROTECTED]
To: "Zope" [EMAIL PROTECTED]
Sent: July 27, 2000 11:07 PM
Subject: [Zope] Moving site from dev to prod.


 I can't quite seem to figure out how to move my web site from my
development
 machine to my production machine with Zope v2.1.x. Under Zope v1.0.9, I
 simply copy the data.bbb file. Under Zope v2.1.x, this file seems to be
 data.fs, but copying it doesn't seem to work as I get a NameError on
 REQUEST. I've also tried to use the import/export capability, but I can't
 figure out how to get the entire site to export. I been through the
zope.org
 sites, docs and recent emails, but can't seem to find guidance on this
 topic.

 My development machine is Zope v2.1.4 on NT and the production machine is
 Zopev2.1.6 on NT. Both installs use FSSession v0.3.1 and LocalFS v0.1.5

 If someone could guide me to documentation, or give me the basics of what
 needs to happen, I would appreciate it.

 Thanks.

 ---
 Jeff Nielsen
 http://www.UgoFast.com/
 "Where U Go Fast"


 ___
 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] search on www.zope.org

2000-07-28 Thread Loren Stafford

Don't overlook the Google Search on
http://www.zope.org/SiteIndex/searchForm. It works nicely.



 Can anybody please tell me the search on www.zope.org does not find any
 pages containing?

   - mod_pcgi2

 In fact there are numerous pages including this term.





___
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-dev] Announce: ZScheduler alpha Version 0.0.7

2000-07-27 Thread Loren Stafford

The problem noted below with the Trigger tab occurs only when Zope is
limited to a single thread. The problem is due to contention for the single
thread. The workaround is to avoid using the Trigger tab on single threaded
Zope's. Or change ZEvent.py like this:

  def manage_triggerZEvent(self, client=None, REQUEST=None, RESPONSE=None,
**kw):
"""For use by the Trigger tab on ZEvent management page.
Use for testing the ZEvent in a context that mimics that of Dispatcher.
"""
aurl=REQUEST['URL1']
furl=string.join((aurl, 'trigger'), '/')
RESPONSE.redirect(furl)

With this fix, the product is fully functional, as far as I know, tho it
remains an alpha product simply because it hasn't received a thorough
shakedown.

I'll have a new release out soon with this fix and other changes.

-- Loren



 ZScheduler Version 0.0.7 Date: 2000/07/02

  1. Fixed a bug that caused ZEvents to execute in the wrong context.

  2. If the action method of a ZEvent raises an error, a traceback is
written
 in the log.

  3. Added a Trigger tab to the management screen for ZEvents which fires
the
 event in the same context that the Dispatcher does, but without regard to
 the schedule. This helps immensely in debugging the DTML in the ZEvent.

 I've tested on:
Win98 Zope 2.2.0b3
Solaris 2.6 Zope 2.1.4
Linux ?.? Zope 2.1.3

 On the Linux configuration (my account at CodeIt Computing), most features
 work; however, the new Trigger tab does not behave correctly. Though the
 ZEvent method eventually executes correctly, it doesn't return anything to
 the client and Zope seems to lock up temporarily -- that is, it doesn't
 respond to other client requests. I don't have a Linux development system
 with which to track this down. Any help would be appreciated.

[...snip...]

 Otherwise, ZScheduler is looking good. Let me know how it works for you.

 http://www.zope.org/Members/lstaffor/ZScheduler

 -- Thanks
 -- Loren




___
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] packing on ZSPs (was Re: [Zope] zope.org down)

2000-07-21 Thread Loren Stafford


- Original Message -
From: "Simon Michael" [EMAIL PROTECTED]

 Related, though specific to Codeit users: I need to pack to avoid the
 above, but fear the data-corrupting packing bugs which were fixed in
 more recent versions of zope. Codeit, perhaps time for an upgrade ? At
 least to 2.1.6 ?


My experience is that CodeIt, in order not to surprise you with unexpected
upgrades, will upgrade your Zope server when you ask.

-- 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] ZStylesheet

2000-07-16 Thread Loren Stafford

I found the series of articles on CSS compatibility at www.webreview.com
helpful in sorting out the incompatibilities and finding a middle ground
that would work.

-- Loren

- Original Message -
From: "Neil Burnett" [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: July 15, 2000 12:40 PM
Subject: [Zope] ZStylesheet


 Warning: This is a 'get it off my chest' e-mail.

 Well, I am going to give up with CSS. I am sure ZStylesheet is a fine
 product, its just that CSS implementations lets it down.

 I have struggled for ages to get anything more sophisticated than
 font-family* to work on both IE5 and Netscape 4.6 - no chance. It seems
 they have both implemented CSS from a different hymn sheet :-( Basically,
 nothing to do with sizes works the same, and it boils down to Netscape
 ignoring the inheritance model of CSS. table rows and cells are a
 particular mystery.

 If anyone has cracked it and has developed a ZStylesheet which can second
 guess both browsers, please let me know. Until then, I will go back to
 using font size="12pt" or whatever. Shame, but I have more interesting
 things to worry about.

 Regards

 Neil

 *even font-family doesn't work for the BODY selector. Tables in Netscape
 ignore it so you have to use BODY TR TD as the selector.

 ___
 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] Newbie: Zope a webserver? Serving PHP and Perl

2000-07-13 Thread Loren Stafford
Title: Newbie: Zope a webserver? Serving PHP and Perl



Your second question almost answers the first. You can use 
Zope either with or without Apache. One way to handle existing PHP sites is to 
put Apache in front of Zope. Then add configuration parameters to Apache to make 
it examine the URLs of requests. If the URL is for PHP pages, then 
handlethe request in Apache/PHP. If the URL is for Zope pages, pass it 
over to Zope. That way you don't even have to think about making Zope do PHP. 


As for setting "Zope up so it handles PHP tags", I'll let 
someone else answer that, 'cause I don't know for sure whether it can even be 
done.

-- Loren

  - Original Message - 
  From: 
  Lucas Young 
  (c) 
  To: '[EMAIL PROTECTED]' 
  Sent: July 13, 2000 03:44 PM
  Subject: [Zope] Newbie: Zope a webserver? 
  Serving PHP and Perl
  
  Hi 
  Have just installed Zope under Win2K and it works 
  fine - I see a lot of people mention using Apache to server Zope, but isnt 
  Zope a webserver itself? I can browse to http://server:8080/ and view Zope pages, so why would I need 
  Apache?
  Also, How do I set Zope up so it handles PHP 
  tags? 
  thanks in advance 
  Lucas Young 


Re: [Zope] Aligning Images With Text

2000-07-12 Thread Loren Stafford

Image objects have a tag method for setting all the HTML tags:

Try something like (untested):

dtml-var "yourimageID.tag(align='right')"

... or tested (from one of my sites):

dtml-var "ClearDot.tag(width='25')"

-- HTH
-- Loren

- Original Message - 
From: "Terry Babbey" [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: July 12, 2000 12:24 PM
Subject: [Zope] Aligning Images With Text


 Here is my code:
 dtml-if "_[ProgCode + 'PIC']"
 dtml-var "_[ProgCode + 'PIC']"
 /dtml-if
 
 What I would like to do is align the picture to the right of my web
 page. If I was programming html I would do it like this: img
 src=T043PIC align=right
 
 Any help?
 Terry
 
 --
 __
 Terry Babbey
 Technical Support Specialist
 Lambton College, Sarnia, Ontario, Canada
 __
 
 
 
 ___
 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] Problem with ZClient

2000-07-11 Thread Loren Stafford
Title: Problem with ZClient



I can't see for sure what the problem is. But I was bitten 
by a problem ZClient had with the port specification. You can read about it at 
http://www.zope.org/Members/lstaffor/ZScheduler/CHANGES.txt. 
Could that be relevant here?

-- Loren


  - Original Message - 
  From: 
  Juan Carlos Coruña 
  
  To: [EMAIL PROTECTED] 
  Sent: July 11, 2000 02:06 AM
  Subject: [Zope] Problem with 
ZClient
  
  I'm testing ZClient to access a ZSQL method on a NT box from a Linux box 
  since Linux can't access any odbc (propietary) database. As ressult i become a 
  bci.ServerError.
  This is the output:
  [root@ecom ZPublisher]# ./Client.py -u username:password http://ntserver.bio.umd.es:8080/xmlrpc/replicar/Cliente/get_Navision 
  N_=26451
  Traceback (innermost last):
  File "./Client.py", line 639, in ?
  main()
  File "./Client.py", line 632, in main
  headers, body = apply(f,(),kw)
  File "./Client.py", line 225, in __call__
  self.handleError(query, ec, em, headers, response)
  File "./Client.py", line 240, in handleError
  raise t, RemoteException(t,v,f,l,self.url,query,ec,em,response)
  bci.ServerError: 
  http://ntserver.bio.umd.es/xmlrpc/replicar/Cliente/get_Navision/manage_testForm 
  (File: C:\ARCHIV~1\XMLSER~1\lib\python\Shared\DC\ZRDB\DA.py Line: 367)
  302 Moved Temporarily for 
  http://ntserver.bio.umd.es:8080/xmlrpc/replicar/Cliente/get_Navision
  Anyone is using a similar method or knows about it?
  Is there an alternative method to access a ZSQL on another 
server?


[Zope] Fw: [Zope] Re:Web Site newbie

2000-07-06 Thread Loren Stafford


- Original Message -
From: "Loren Stafford" [EMAIL PROTECTED]
To: "michael montagne" [EMAIL PROTECTED]
Sent: July 06, 2000 01:11 PM
Subject: Re: [Zope] Re:Web Site newbie


 As Andy also said, "It depends".  It depends on what you want to do with
 your website. Write and let us know so we can give more specific answers.
 Chances are you can put all your content in Zope's database.

 Some folks decide to store some files outside of Zope and serve them thru
 Apache, for any of the following reasons:

 1. You've got thousands of them
 2. They're huge (full-length mpeg2 movies, for example -- hundreds of
 megabytes)
 3. They need to be accessible to other applications

 But if you don't have such requirements, count on Zope for everything.

 -- Loren

 - Original Message -
 From: "michael montagne" [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Sent: July 06, 2000 06:49 AM
 Subject: [Zope] Re:Web Site newbie


  Tremendous reply!!  Just what I needed.  I'm curious about one thing
tho.
  If you don't need a regular web server (for serving files outside of
 Zope),
  stick with the built-in ZServer. 
  Does this mean that I have to have all my files in the zope folder?
  Wouldn't I want to do that anyway?  Can you elaborate?
  I'd like to stick with the Zserver if I can but I don't want to run into
 any
  road blocks too soon down the road.
  -mjm
 



___
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-dev] Looking for Zope webmaster or web developer job

2000-07-05 Thread Loren Stafford

I'm looking for a new job where I can continue to use Zope for website
management and applications development.

Contract or full-time.

Silicon Valley California or telecommute.

If you know of any openings, please let me know.

-- Thanks
-- Loren Stafford

[EMAIL PROTECTED]

http://www.dynalogic.com/resume.html


___
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] Looking for Zope webmaster or web developer job

2000-07-05 Thread Loren Stafford

I'm looking for a new job where I can continue to use Zope for website
management and applications development.

Contract or full-time.

Silicon Valley California or telecommute.

If you know of any openings, please let me know.

-- Thanks
-- Loren Stafford

[EMAIL PROTECTED]

http://www.dynalogic.com/resume.html


___
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] Web site newbie

2000-07-05 Thread Loren Stafford

From: "Montagne, Michael" [EMAIL PROTECTED]


 I'm very excited about learning Python and Zope.  I'm a win98 user and
just
 today upgraded my service with my ISP to host my web page from home.

Congratulations on becoming an internet host provider.

I hope you have a firewall in front of your PC to help protect it from
attacks over the internet. Does your ISP help out there?

 So I  need a web server.

I hope you realize that win98, while an OK platform for prototyping a Zope
application, is not a sufficiently reliable platform for a professional
website. But, because Zope is largely platform independent, most things you
learn about it will be transferable when you decide to upgrade the
webserver's operating system.

 According to the docs, Zope comes with one.  If I use
 that one, am I going to be over my head initially?

The ZServer that comes with Zope is about as easy to install as Personal Web
Server. Go for it.

 Should I be using a
 different product if my site is not going to be super dynamic from the
 beginning?

A reasonably fast PC  has processor cycles to spare if all it is doing is
serving a small web site. Users won't even notice that pages are being
generated on the fly. If processor speed should ever become a limitation,
you will have several courses of action that do not involve changing your
Zope-based application (e.g. processor upgrade, front-end cache).

 If I use Personal Web Server, can Zope be integrated later?

I don't think so (but I'm not positive). Still, if you need a regular web
server, use the Windows version of Apache. It will be a little more
complicated to install and maintain, but you'll be learning an
industry-standard program. Subscribe to an Apache mailing list, if you need
help managing it on your PC. If you don't need a regular web server (for
serving files outside of Zope), stick with the built-in ZServer.

 Can
 I use Web authoring software such as Front Page 2000 and publish to
Zserver?

Yes (with limitations that you can read about by searching the archives of
this mailing list), but you may find that you no longer want or need to.
Usually 90% of the complex HTML in a web site is in the framing of the
content -- i.e. the headers, footers, and navigation. This kind of repetive
and/or computed HTML is the kind the you will program Zope to gather in one
place, and reuse for all requests. The individual content of each page very
often uses the simple sort of HTML that you can either code by hand or
create in simple HTML-aware editors.


 thanks so much,
 -mjm


-- Hope that helps
-- 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 )




[Zope-dev] Announce: ZScheduler alpha Version 0.0.7

2000-07-03 Thread Loren Stafford

ZScheduler Version 0.0.7 Date: 2000/07/02

 1. Fixed a bug that caused ZEvents to execute in the wrong context.

 2. If the action method of a ZEvent raises an error, a traceback is written
in the log.

 3. Added a Trigger tab to the management screen for ZEvents which fires the
event in the same context that the Dispatcher does, but without regard to
the schedule. This helps immensely in debugging the DTML in the ZEvent.

I've tested on:
   Win98 Zope 2.2.0b3
   Solaris 2.6 Zope 2.1.4
   Linux ?.? Zope 2.1.3

On the Linux configuration (my account at CodeIt Computing), most features
work; however, the new Trigger tab does not behave correctly. Though the
ZEvent method eventually executes correctly, it doesn't return anything to
the client and Zope seems to lock up temporarily -- that is, it doesn't
respond to other client requests. I don't have a Linux development system
with which to track this down. Any help would be appreciated.

Here's the code for the Trigger tab. Can you see anything wrong? ...or
anything Linux and Zope 2.1.3 would find wrong?

 def manage_triggerZEvent(self, client=None, REQUEST=None, RESPONSE=None,
**kw):
"""For use by the Trigger tab on ZEvent management page.
Use for testing the ZEvent in a context that mimics that of Dispatcher.
"""
RESPONSE.setHeader('Content-type','text/plain')
aurl=REQUEST['URL1']
furl=string.join((aurl, 'trigger'), '/')
(headers,response)=Client.call(furl) # Fire event
RESPONSE.setBody(headers)
RESPONSE.appendBody('\n')
RESPONSE.appendBody(response)

Otherwise, ZScheduler is looking good. Let me know how it works for you.

http://www.zope.org/Members/lstaffor/ZScheduler

-- Thanks
-- Loren



___
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] Product Data Storage

2000-06-30 Thread Loren Stafford

I haven't thought much about this; I just followed mj's original design.
Maybe there was some reason for this decision. Any comment Martijn?

-- Loren


 Loren Stafford wrote:
  In that case we decided to put the Schedule in the root folder.
 There is no
  more global data than the catalog itself, but if there were it could be
  stored in the catalog folder, since catalogs are folderish.

 Hmm, this is messy. Could the Catalog not be stored in your case in:
 /Control Panel/Products/ZScheduler
 and in Andy's case in:
 /Control Panel/Products/ZMailIn
 ?


___
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] python product - newbie

2000-06-22 Thread Loren Stafford

I don't know about registering nested classes. I think Dieter Maurer
answered that in his response to your original email.

http://www.zope.org/Members/Zen/howto/ProductAPITutorial is the old way of
doing it.

http://www.zope.org/Members/gtk/Boring/HowTo-Boring documents the new way by
example.

http://www.zope.org/Members/michel/Projects/Interfaces/ProductRegistration
is the new official documentation. There's an example of two classes there
that might be relevant.

-- Loren


- Original Message -
From: "Bak @ kedai" [EMAIL PROTECTED]
To: "Loren Stafford" [EMAIL PROTECTED]; [EMAIL PROTECTED]
Sent: June 21, 2000 08:51 PM
Subject: Re: [Zope] python product - newbie

[snip __init__.py]


 i looked at the old product API, but got more confused because i think
Boring
 is based on another way of making product.  is that so?

 thabks



___
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-dev] Re: [Zope] ZScheduler-0.0.6 problem

2000-06-21 Thread Loren Stafford

Could we continue this discussion on zope-dev, because this is an
alpha-level product at this point?

I have ZScheduler 0.0.6 running on a Linux machine (www.fippless.org at
CodeIt Computing), so we can't say it's an NT vs. Linux problem. It's more
likely a Linux/Python/Zope configuration issue. The most system-dependent
part of ZScheduler is its use of Python's threading module.

According to Netcraft,  www.fippless.org is running Red Hat Secure/2.0
(Unix) mod_ssl/2.0.7 SSLeay/0.9.0b on Linux. According to the Zope Control
Panel,

 Zope version: Zope 2.1.3 (source release, python 1.5.2, linux2)
 Python version: 1.5.2 (#1, Feb 1 2000, 16:32:16) [GCC egcs-2.91.66
19990314/Linux (egcs-
 System Platform: linux-i386

Nick, can you supply more detail about the Linux configuration?

CodeIt Computing is a good Zope ISP, but, as you would expect of an ISP,
they don't offer facilities for this level of SW development, and I don't
have any other machines at my disposal to duplicate your Linux
configuration.

So, I'll need your assistance to help isolate the problem. Can you help with
a little debugging, tracing, instrumentation to find the code that throws
Zope off track?

I doubt whether the problem is with the archive itself, but just to be sure,
I created a new archive for version 0.0.6 with a different archiving tool.
The new one shows 12330 bytes while the old one shows 20480 bytes (quite a
difference for the same content, eh?).

-- Loren

- Original Message -
From: "Francois-Regis CHALAOUX"
[EMAIL PROTECTED]
To: "Receipt Notification Requested" [EMAIL PROTECTED]
Sent: June 21, 2000 12:48 AM
Subject: [Zope] ZScheduler-0.0.6 problem


 Hi,

 I have just tested ZScheduler-0.0.6 on NT machine : it works : On my
Linux
 machine it does not work :
 Thus, the code is NT dependant or the archive works on NT only !!!???

 FR





___
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: Objet : Re: ZScheduler-0.0.5 problem

2000-06-20 Thread Loren Stafford

This is going to be hard to debug remotely. Can you help me out?

First try getting ZScheduler 0.0.6 which fixes a problem of non-responsive
Zope, though there the problem was on shut-down not on start-up. Be sure you
have STUPID_LOG_FILE working. Then uncomment some of my debugging statements
(calls to loggerr) in the source of __init__.py and  Dispatcher.py -- maybe
add some instrumentation yourself -- all with the goal of observing how far
it runs before Zope hangs. Maybe you'll have to activate one of the #import
pdb; pdb.set_trace() statements (in an appropriate place, of course).

Also, are there any entries in the Zope log or system log that are seem
relevant?

The only other thing that comes to mind is that ZScheduler depends on
Python's threading module, so you must have a version of threading that
works on your OS. I don't know whether there are any "gotchas" with respect
to Python threading on Linux (Linux 6.1, I386, Zope-2.1.7.). Maybe someone
else can step in and let us know if there are.

Please continue to copy [EMAIL PROTECTED]

-- Thanks
-- Loren

- Original Message -
From: "Francois-Regis CHALAOUX"
[EMAIL PROTECTED]
To: "Receipt Notification Requested" [EMAIL PROTECTED]
Sent: June 20, 2000 06:48 AM
Subject: Objet : Re: ZScheduler-0.0.5 problem


 Hi Loren,

 loren1. Zope 2.1.7 has been withdrawn due to CVS confusion. Can you
 reproduce the
 problem on another version, such as 2.1.6?. Is there any indication of why
 it won't start (error message)? Did you start it with -D set, so it would
 display errors on the console?/loren

 Yes, the script start script contains '-D "$@"' but nothing is displayed
on
 the console when I try to fetch an object from zope.
 Zope is is blocked and that's all :(


  Hi,
 
  1/ I'm Trying to use ZScheduler-0.0.5 on Linux 6.1, I386, Zope-2.1.7.
  Just after to install the product I cannot start Zope !!!
 
  2/ There is also an archive problem when I extract the file from
  ZScheduler-0.0.5.tgz :
 
  srchocolat 138% tar xvzf ZScheduler-0-0-5.tgz
  lib/python/Products/ZScheduler/
  lib/python/Products/ZScheduler/__init__.py
  lib/python/Products/ZScheduler/addOneTimeZEvent.dtml
  lib/python/Products/ZScheduler/README.txt
  lib/python/Products/ZScheduler/CHANGES.txt
  lib/python/Products/ZScheduler/ZSchedule.py
  lib/python/Products/ZScheduler/version.txt
  lib/python/Products/ZScheduler/ZEvent.py
  lib/python/Products/ZScheduler/Loggerr.py
  lib/python/Products/ZScheduler/Dispatcher.py
  lib/python/Products/ZScheduler/documentEdit.dtml
  lib/python/Products/ZScheduler/scheduleView.dtml
  lib/python/Products/ZScheduler/www/
  lib/python/Products/ZScheduler/www/OneTimeZEvent.gif
  lib/python/Products/ZScheduler/www/RecurringZEvent.gif
  lib/python/Products/ZScheduler/www/ZSchedule.gif
 
  gzip: stdin: decompression OK, trailing garbage ignored
  tar: Le processus enfant a retourné le statut 2
  tar: Statut d'erreur reporté d'erreurs précédentes.
  srchocolat 139%
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 









































___
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] Logging for ZScheduler?

2000-06-19 Thread Loren Stafford

I've created a STUPID_LOG helper product, called FrozenLogger, that does the
minimum necessary for me to create a STUPID_LOG_FILE at my account at CodeIt
Computing (where lack of telnet keeps me from setting environment
variables).

http://www.zope.org/Members/lstaffor/FrozenLogger

The core of this is:

 from Globals import data_dir
 if os.environ.has_key('STUPID_LOG_FILE'):
pass
 else:

os.environ['STUPID_LOG_FILE']=string.join((data_dir,'FrozenLogger.txt'),'/')

It works for me at CodeIt, but I doubt if it's general enough for some of
the Zope virtual hosting schemes I've read about here. Let me know how your
mileage varies.

-- Loren

- Original Message -
From: "Stuart 'Zen' Bishop" [EMAIL PROTECTED]
To: "Loren Stafford" [EMAIL PROTECTED]
Cc: "Loren Stafford" [EMAIL PROTECTED]; "zope-dev"
[EMAIL PROTECTED]
Sent: June 15, 2000 01:57 PM
Subject: RE: [Zope-dev] Logging for ZScheduler?


 On Thu, 15 Jun 2000, Loren Stafford wrote:

  Aha! Even tho a cohosted account might not be able to modify the source
of
  the Zope implementation directly, installing a CustomLog product could
do so
  indirectly, by importing ZLogger and modifying the loggers tuple. To
know
  where to write the log file, CustomLog would have to either know or be
  configurable enough to adapt to the ISP's Zope configuration. I suppose
an
  absolute path property would be suffient. An ISP could preconfigure and
  preinstall the CustomLog product for all users, or each user could do
it.

 Dump it Globals.data_dir unless a given environment variable is set.

 (Sorry bout the double reply)

 --
 Stuart Bishop  Work: [EMAIL PROTECTED]
 Senior Systems Alchemist   Play: [EMAIL PROTECTED]
 Computer Science, RMIT University


 ___
 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 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] Fw: ZScheduler-0.0.5 problem

2000-06-19 Thread Loren Stafford



 1. Zope 2.1.7 has been withdrawn due to CVS confusion. Can you reproduce
the
 problem on another version, such as 2.1.6?. Is there any indication of why
 it won't start (error message)? Did you start it with -D set, so it would
 display errors on the console?

 2. This is a spurious error. It should not cause any problems in
 installation. It seems to be caused by the MKS tools that I use to create
 the tarball on Win98.

 -- Thank you for trying it out
 -- Loren

 - Original Message -
 From: "Francois-Regis CHALAOUX"
 [EMAIL PROTECTED]
 To: "Receipt Notification Requested" [EMAIL PROTECTED];
"Receipt
 Notification Requested" [EMAIL PROTECTED]
 Sent: June 19, 2000 06:58 AM
 Subject: ZScheduler-0.0.5 problem


  Hi,
 
  1/ I'm Trying to use ZScheduler-0.0.5 on Linux 6.1, I386, Zope-2.1.7.
  Just after to install the product I cannot start Zope !!!
 
  2/ There is also an archive problem when I extract the file from
  ZScheduler-0.0.5.tgz :
 



___
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-dev] Logging for ZScheduler?

2000-06-15 Thread Loren Stafford


 -Original Message-
 From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf
 Of Stuart 'Zen' Bishop
 Sent: Wednesday, June 14, 2000 20:58
 To: Loren Stafford

 On Wed, 14 Jun 2000, Loren Stafford wrote:

  I need some advise for designing a flexible system for logging the
  activities of scheduled events.

 You could just call Zope's logging system and move it out of the
 scope of your product. Have a look at zLOG.py or LOGGING.txt
 if you havn't already. Means people can extend their logging system
 to their hearts content with no effect on your product.

ZScheduler already uses zLOG.LOG. I guess I forgot that it permits
implementations other than stupid_log. So I guess ZScheduler is as flexible
as can be, given the current API.


  But ZScheduler also needs to be ISP independent. That is, you
 should have
  complete scheduling capabilities for your cohosted Zope
 applications without
  having to call up the ISP and ask for system configuration changes.

 This could be achieved with a seperate product. A product that
 ties into Zope's logging infrastructure and allows viewing the
 log files through the web. All it would have to do is append itself to the
 ZLogger.loggers tuple, and the interface is pretty trivial. And of course,
 it means that other products can use it without modification
 (Logger product,
 Zope itself etc.) and can be extended as required without having to
 submit patches to you for inclusion in ZScheduler.

Aha! Even tho a cohosted account might not be able to modify the source of
the Zope implementation directly, installing a CustomLog product could do so
indirectly, by importing ZLogger and modifying the loggers tuple. To know
where to write the log file, CustomLog would have to either know or be
configurable enough to adapt to the ISP's Zope configuration. I suppose an
absolute path property would be suffient. An ISP could preconfigure and
preinstall the CustomLog product for all users, or each user could do it.


 It would be a good idea if there was a field in the ZEvent that defined
 the subsystem used in the zLOG call.


I didn't follow your point here. By "subsytem" do you mean which logger in
the loggers tuple? Then do you mean that different ZEvents could log to
different loggers? Why would this be a "good idea", I mean, do you have a
use case in mind?

-- Thanks
-- Loren


___
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] Logging for ZScheduler?

2000-06-15 Thread Loren Stafford

 -Original Message-
 From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf
 Of Phillip J. Eby
 Sent: Wednesday, June 14, 2000 21:21
 To: [EMAIL PROTECTED]; Loren Stafford

 At 01:58 PM 6/15/00 +1000, Stuart 'Zen' Bishop wrote:
 
 Its not a problem with ZScheduler, it a problem that no one has written
 a plug-in logging system that is good enough for what you are trying to
 do. The existing zLOG API is fine (well - it could be better), but just
 needs someone to write the relevant modules. Hmm... I think I'll
 add a section to the Interfaces Wiki...

 Hm...  this could work well with Observer-Observable, too.
 Imagine firing
 ObservableEvents, and subscribing a "Log" object to them...

Cool! Then the logging operation would become a part of the scheduled event
thread and transaction instead of part of the Dispatcher's thread (a
possibly transaction). I'll have to think about the implications of that.

Where is Observer-Observable in the development plan? ZPatterns 0.4?

-- Loren



___
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] ZScheduler runs on Unix!

2000-06-14 Thread Loren Stafford

I just got a chance to try out ZScheduler 0.0.5 on Solaris 2.6 and some
version of Linux -- and it works. I've changed the CHANGES.txt file to
reflect that fact without incrementing the product version number.

It should now be safe to try the product out on Unix development systems. It
remains, however, alpha software.

http://www.zope.org/Members/lstaffor/ZScheduler

Let me know how it works for you.

-- Thanks
-- Loren


___
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] Logging for ZScheduler?

2000-06-14 Thread Loren Stafford

I need some advise for designing a flexible system for logging the
activities of scheduled events.

One of the motivations for developing ZScheduler was to have a platform
independent means for scheduling Zope tasks. The lask of a cron on Windows
platforms was a part of the problem. ZScheduler achieves this independence
by using Python's threading.Wait method for all time measurement.

But ZScheduler also needs to be ISP independent. That is, you should have
complete scheduling capabilities for your cohosted Zope applications without
having to call up the ISP and ask for system configuration changes.
ZScheduler partially achieves this level of independence, by eliminating the
need for cron.

But, as I installed ZScheduler under my personal account at CodeIt
Computing, I realized that an ISP-dependence still exists, and it has
nothing to do with cron -- it has to do with the configuration of the
Scheduler's logging activity. When you have a Scheduler executing
applications tasks on your website behind your back, you definitely want it
to keep a log of what it is doing. For ZScheduler, I chose to use the
STUPID_LOG_FILE feature of Zope. However, STUPID_LOG_FILE is an environment
variable. Zope accounts at CodeIt (and probably at any other Zope ISP)
cannot set environmet variables. And if they could, is anyone certain how
STUPID_LOG_FILE would behave in their custom cohosting adaptation of Zope?

So, I need a more flexible structure for the logging aspect of ZScheduler.
While the ZEvent class is subclassable by users, I haven't made the
Scheduler class instantiable -- there should be only one instance -- so it's
not subclassable either, and therefore you can't override its logging
method. Do you see the problem?

Having little experience with Python and OO applications, I don't know how
others solve this problem. Can you give me any pointers?

Perhaps I've identified a typical application of RIPP?

-- Thanks
-- Loren



___
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] Announce: ZScheduler alpha 0.0.5

2000-06-13 Thread Loren Stafford

I found some time to do a little work on ZScheduler. The result is alpha
version 0.0.5. You can get it at
http://www.zope.org/Members/lstaffor/ZScheduler.

It appears fully functional on Win98 with Zope versions 2.1.4 and 2.1.6
(with patch to Client.py). But this is still alpha software, so be careful
where you install it.

I've made no changes to make it work on Unix. (I don't have a Unix
development environment at my disposal.) Prior versions caused Zope to
become inoperative while installed. I would appreciate someone's confirming
whether 0.0.5 doesn't work on Unix either.

-- Thanks
-- Loren



___
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] ZClass and class variable

2000-06-05 Thread Loren Stafford

Yes, if what you need is a variable shared by all instances of the class.
You need to use a property sheet.

The "How-To" http://www.zope.org/Members/lstaffor/zProperties might help
answer this question, though it speaks more about instance variables.

-- Loren

 -Original Message-
 From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of
 Francois-Regis CHALAOUX
 Sent: Monday, June 05, 2000 09:12
 To: Receipt Notification Requested
 Subject: [Zope] ZClass and class variable
 Sensitivity: Personal


 Hi all,

 Is it possible to declare a class variable in a Zclass?
 And if yes, how to call this variable in class ZClass methodes?

 Bye, FR.




















 ___
 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] How to ZCatalog DTML documents and/or HTML files automatically?

2000-06-04 Thread Loren Stafford

ZScheduler is sort of functional on Win98, but not at all on Unix. It seems
to cause Zope to restart when the product is loaded and it doesn't trigger
events. I haven't had the time to track down the symptoms, let alone the
real causes. I'd gladly accept help from others.

-- Loren


- Original Message -
From: [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: June 03, 2000 03:12 AM
Subject: [Zope] How to ZCatalog DTML documents and/or HTML files
automatically?


 Hello,

 this is probably a stupid question, But I'm damned if I can find
 a solution :-(

 We have an internal site to store technical documents (in HTML
 or as DTML documents).
 We are using ZCatalog to provide an index for it.

 Now, we want to have some mechanism that updates the index every
 night (including pages added during the day).

 On this list, I have read that the obvious solution, ZScheduler,
 "does not work". I take it "does not work reliably for all
 conceivable uses".
 Does this mean it is likely to work for what I have in mind? Are
 there any other ways to achieve it? I am running this on Unix
 (Solaris 7, in fact).

 Confused,
 Jan

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

2000-05-26 Thread Loren Stafford

Yes. The Client.py patch must be applied for any use of ZScheduler, if the
server is not listening on the default port.

"reschedule" is always called when an event is triggered, so that there is
an opportunity to reschedule or disarm the event. If "reschedule" fails (as
it will if the server is not on the default port and the patch is not
applied), the whole transaction fails.

By the way, what version of Zope are you using? I reported the bug in
version 2.1.4. I wonder (because I haven't checked yet) if it was fixed in
later versions.

-- Loren

- Original Message -
From: "Graham Chiu" [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: May 25, 2000 11:11 PM
Subject: Re: [Zope] ZScheduler


 In article 019501bfc6c2$91e19b60$2101a8c0@pavilion, Loren Stafford
 [EMAIL PROTECTED] writes
 Graham,
 
 Thanks for sending all the info. I haven't had a chance to check it all
out.
 But I want to ask one more thing: did you install the patch to client.py
as
 mentioned in CHANGES.txt and
 http://www.zope.org/Members/lstaffor/ZScheduler/ZSchedulerWiki/BugReports
 


 Loren,

 Since this bug referenced a reschedule operation, I didn't bother to
 apply the patch - should I?

 --
 Regards,  Graham Chiu
 gchiuatcompkarori.co.nz
 http://www.compkarori.co.nz/index.php
 Powered by Interbase and Zope



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

2000-05-25 Thread Loren Stafford

Graham,

Thanks for sending all the info. I haven't had a chance to check it all out.
But I want to ask one more thing: did you install the patch to client.py as
mentioned in CHANGES.txt and
http://www.zope.org/Members/lstaffor/ZScheduler/ZSchedulerWiki/BugReports

?

-- Loren

- Original Message -
From: "Graham Chiu" [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: May 21, 2000 02:56 PM
Subject: Re: [Zope] ZScheduler


 -BEGIN PGP SIGNED MESSAGE-
 Hash: SHA1

 In article 001901bfc360$6e3f9280$2101a8c0@pavilion, Loren Stafford
 [EMAIL PROTECTED] writes
 What happens when you execute the event's "trigger" method from the
 browser's location line?

 Perhaps this will help.

 Here's my Zevent

 dtml-var zMailTest


 And here's zMailTest which works fine when called from the browser:

 dtml-sendmail smtphost="mail.netlink.net.nz"
 To: GC [EMAIL PROTECTED]
 From: TV time [EMAIL PROTECTED]
 Subject: This is cron test

 Charmed is on tonight at 7 pm.

 /dtml-sendmail

 And here is the log report.  Isn't 503 an SMTP error of some sort?


 2000-05-21T22:48:10 PROBLEM(100) Products.ZScheduler.Loggerr
 Trigger event: http://a7800nt:8080/zTV
 Trigger time: 2000/05/22  10:48:00 GMT+12
 Failed to trigger event.
 Type=exceptions.KeyError
 Val=META HTTP-EQUIV="Pragma" CONTENT="no-cache" META HTTP-
 EQUIV="Expires" CONTENT="0" HTMLHEADTITLEzTV/TITLE/HEADBODY
 BGCOLOR="#FF"  table width="100%" border=0 cellspacing="0"
 cellpadding="0" bgcolor="#00"   tr td h (File:
 d:\zope2\lib\python\DocumentTemplate\DT_String.py Line: 502)
 503 Service Unavailable for http://a7800nt:8080/zTV/trigger
 - --
 2000-05-21T22:48:10 PROBLEM(100) Products.ZScheduler.Loggerr Failed to
 disarm event


 - --
 Regards,  Graham Chiu
 gchiuatcompkarori.co.nz
 http://www.compkarori.co.nz/index.php
 Powered by Interbase and Zope

 -BEGIN PGP SIGNATURE-
 Version: PGPsdk version 1.7.1

 iQA/AwUBOSfA6LTRdIWzaLpMEQJCGACg39opsy130qgjwfFNS5kFUAHGAyMAoPTO
 Fe2zVB6LB3QOX773fJ2NbbsO
 =Kq9S
 -END PGP SIGNATURE-

 ___
 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] Win98 and WEBDAV - you ought to see it if you can

2000-05-23 Thread Loren Stafford

Aha! I got Web Folders to work when pointed to a Zope/Zserver on the same
machine, so the problem is probably with the servers I tried to point to
first. I found an explanation in an earlier email on this list: the attempt
to access _vti_bin is an attempt by Web Folders to see if the server
supports FrontPage extensions. It tries this if it thinks the server does
not support WebDAV. It might think a Zope/Apache server doesn't support
WebDAV if Apache doesn't have the patches necessary to let the WebDAV
inquiry pass thru to Zope. The patches are described at
http://www.zope.org/Members/Brian/Misc/mod_cgi_webdav_patch.html.

Hope that helps the next person that tries this. BTW, everything you ever
wanted to know about WebDAV is at http://www.webdav.org/.

-- Loren

 -Original Message-
 From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of Rik
 Hoekstra
 Sent: Monday, May 22, 2000 08:48
 To: Loren Stafford; Paul Browning; [EMAIL PROTECTED]
 Subject: Re: [Zope] Win98 and WEBDAV - you ought to see it if you can




 When I try to "Add a Web Folder" on Win98 I get a 404 error on
 the resource
 _vti_bin both on my own web sites and on www.zope.org. Any idea
 why or what
 is _vti_bin?
 


 Yes, it is (one of the) the dreaded Frontpage extension(s). Why you would
 get it and someone else wouldn't ... I don't know. Perhaps you have MS
 products that use FP extensions (Frontpage, Interdev, whatever) installed?

 Rik


 ___
 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] Q; Date / ZCatalog / Search

2000-05-22 Thread Loren Stafford

For an events database, I catalog properties "startdate" and "enddate" of
type "date" as field indexes; then I search it in two steps:

First create a temporary list of events that meet the date criteria

dtml-call "REQUEST.set('NewsEventsList',[])"
dtml-in "NewsEventCat(meta_type='News Event',
  enddate=_.DateTime()-1,
  enddate_usage='range:min',
  sort_on='startdate')"
dtml-call "NewsEventsList.append(NewsEventCat.getobject(data_record_id_))"
/dtml-in
dtml-if NewsEventsListdtml-return "1"dtml-elsedtml-return
"0"/dtml-if

Then, if that list is non-empty, I format as many entries from it as I
need -- in this case 2.

!-- Start Events Summary --
table width="100%" cellspacing=0 cellpadding=0 border=0
dtml-in NewsEventsList orphan=1 size=2
 trtd colspan=2p class="sidebody"
  a href="/news/events"dtml-var startdate/a
  dtml-if "_['startdate'] != _['enddate']"
  - a href="/news/events"dtml-var enddate/a
  /dtml-if
  /p/td/tr
 trtdnbsp;/tdtdp class="sidebody"
  dtml-var title_or_id
  /p/td/tr
dtml-else
 trtd colspan=2p class="sidebody"
No events to announce.
  /p/td/tr
/dtml-in
 trtd colspan=2 align="right"p class="sidebody"
   a href="/news/events"more gt;gt;/a
  /p/td/tr
/table
!-- End Events Summary --

Hope that helps.

-- Loren

- Original Message -
From: "J. Atwood" [EMAIL PROTECTED]
To: "Jørgen Skogstad" [EMAIL PROTECTED]; [EMAIL PROTECTED]
Sent: May 22, 2000 03:36 PM
Subject: Re: [Zope] Q; Date / ZCatalog / Search


 I too have not been able to get this to work... anyone to help... please?

 J

  From: Jørgen Skogstad [EMAIL PROTECTED]
  Date: Tue, 23 May 2000 00:25:22 +0200
  To: [EMAIL PROTECTED]
  Subject: [Zope] Q; Date / ZCatalog / Search
 
  Kindest sir,
 
  I have a small question I hope someone could share some wisdom
  with. I am not that familiar with the various objects available
  within the Zope framework yet.
 
  .. I have made a ZCatalog which works seamlessly for text only
  searches etc. However; I need to search on a date basis on the
  generated object in the ZCatalog.
 
  For now my "date" entry/column is [string] coded.. not "date"
  as would be apropriate? How can I use date .. and then make
  a search to get the last 5 entries in a table?
 
  http://www.zope.org/Members/Zen/howto/AdvZCatalogSearching
 
  .. shows some possible ways to do this; but I can't seem to get
  them to work properly;
 
  dtml-comment Items modified in the last 14 days
  /dtml-comment
  dtml-in "Catalog(bobobase_modification_time=_.DateTime(date)-14,
  bobobase_modification_time_usage='range:min')"
  New item:
  dtml-var "Catalog.getpath(data_record_id_)"br
  /dtml-in
 
  .. does anyone have any information on how they have used this
  and gotten it to work? .. and might have an example or two? ;)
 
  What exactly does the various elements in the above example do?
  .. like "Catalog(bobobase_modification_time=_.DateTime(date)-14,
  bobobase_modification_time_usage='range:min')" ??
 
  .. mm .. any input? ;)
 
  Thanks in advance..
 
  Kindest,
  Jørgen Skogstad
 
 


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

2000-05-21 Thread Loren Stafford

What happens when you execute the event's "trigger" method from the
browser's location line?

e.g.
http://my.site.dom/my_scheduled_method/trigger

-- Loren


 In article 000101bfc01a$1ec3e2e0$[EMAIL PROTECTED], Loren
 Stafford [EMAIL PROTECTED] writes
 You can try out ZScheduler on Windows (I tested on Win98). It actually
runs
 the scheduled tasks. However, because the inter-thread communication
isn't
 working, it degrades to polling the schedule table.

 I tried this out on my notebook running NTWK4.0 and got this from the
 log

 Failed to trigger event.
 Type=exceptions.AttributeError
 Val=this (File: D:\zope2\lib\python\Products\MailHost\SendMailTag.py
 Line: 188)
 500 Internal Server Error for http://a7800nt:8080/myfolder/cron/trigger
 - --
 2000-05-20T05:40:24 PROBLEM(100) Products.ZScheduler.Loggerr Failed to
 disarm event

 The DTML code just sends an email, and works fine when tested outside
 the ZEvent.

 - --
 Regards,  Graham Chiu
 gchiuatcompkarori.co.nz
 http://www.compkarori.co.nz/index.php
 Powered by Interbase and Zope



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