Re: [Zope-dev] ZPatterns design question

2000-07-31 Thread Steve Alexander

"Phillip J. Eby" wrote:
 
 At 11:09 PM 7/30/00 +0100, Steve Alexander wrote:
 Let's say I have an AddressBook specialist.
 
 Why?  :)
 
 Seriously, what is the function of "address book" in your application?  Is
 it to find people in general?  Or...?

As in your example later, the Addresses specialist is at a different
level of abstraction than other specialists.

The domain expert tells me that he want to keep particular information
about Suppliers: what they supply, and their address details. However,
he also wants to store the address details of any other contacts he
wishes. He'll sometimes need to search through all of the contacts and
suppliers (and in future, anyone that has an address) by phone number or
name or address. The domain expert calls the thing that allows him to do
the searching (and also browsing) of addresses his "address book", and
it reflects a real paper-based artifact. I'm sure I could rename it
"Contacts" or "Addresses" without causing too much confusion, though.

From the way I just described it, there is no requirement for the
addresses to be stored all in one place. There is a requirement that you
can search and browse through all addresses, and return the appropriate
object.

So, I guess a good way to go is to add an "address" propertysheet to
Contact and Supplier, and have triggers that add the address details of
both to an Address catalogue.

 
 Bunch of questions:
 
 Is this the ZPatterns ideomatic way to do this?
 
 Dunno.  Explain the problem you're trying to solve, and I'll
 tell you the simplest way I know to do it.
   

Aha... the missing link :-)


 What kind of propertysheet should I be using?
 
 Depends on what your application needs.  I can see circumstances where the
 best place for that sheet could be LDAP, SQL, or the ZODB.  

I wasn't being very clear there.  What kind of propertysheet should I be
adding to my DataSkin-derived ZClasses?

There are two kinds: "Common instance" and "DataSkin attribute".

It looks to me like at present the "DataSkin attribute" flavour will
work better with SkinScript.


 In which case, I think your
 confusion comes from terminology.  I would expect to store "Contacts" or
 "Entries" in an addressbook, and these would have address sheets, as would
 "Suppliers" or whatever else.

That makes sense. Suppliers are sored in the Suppliers specialist, and
general Contacts are stored in the Contacts specialist. The contacts
specialist provides searching appropriate to the domain of addresses and
contacts.


 Anyway, to answer your question - I think that your getItem() for an
 address specialist wants to return some object with an address sheet.  But
 not an address object.  Contact, Entry, Supplier, TennisBuddy...  whatever
 the heck kind of object it is.

This is starting to make much more sense.

Many thanks.

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

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




Re: [Zope-dev] Ids starting with _

2000-07-31 Thread Toby Dickenson

On Sun, 30 Jul 2000 10:38:44 +0100, Chris Withers [EMAIL PROTECTED]
wrote:

Dieter Maurer wrote:
   I wonder why starting folders with _ is so bad in Zope?

 In the time, when everything was allowed what was not explicitely
 forbidden, an easy way was necessary to forbid access. Jim
 (and, therefore, Zope) used:
 
   anything starting with "_" is private: no DTML access, no Web access.
 
 Now, with the change to a security policy "Everything is
 forbidden when not explicitely allowed", the need for
 such a rule based on naming dwindles. Maybe, it will disappear
 sometime in the future.

That rules applies at a lower level. It removes the need to have
special-case handling for the many low-level objects that should never
be web-accessible.

Almost all zope-manageable classes (and certainly Folders, that Dieter
mentioned) use the old rule. This happens because they derive from
SimpleItem.Item, which has __allow_access_to_unprotected_subobjects__.





Toby Dickenson
[EMAIL PROTECTED]

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




[Zope-dev] RE: Additional Quoting; Exposing Auxiliary Tag Functions via _

2000-07-31 Thread Casey Duncan

Dieter Maurer writes:
 The existing "quote features" name the context for which quoting
 is needed. The context determines what needs to be quoted and
 how quoting has to be done.
 Your proposal does not state the context but only the how.
 Otherwise, I would think such an extension would be good.

You are right here. I just came up with "slash_quote" off the top of my
head. "string_quote" is a good language-neutral name I think that is similar
in spirit to the present format options.

 Thus, I propose:

 1. new quoting directive "string_quote" quoting Python strings
i.e. ", ' and \ are quoted.
This would work for Javascript (and other languages with
C-like quotation and string literals), too.

 2. all auxiliary functions for DTML tags, especially quoting,
should be available via the namespace.

To avaid namespace pollution, they may go into a separate
module, say 'aux'.
E.g. I would like to use quoting, formatting etc.
inside DTML embedded Python expressions in a form like that:

   dtml-var "... _.aux.fmt(x,'%m/%d/%Y')..."
and
dtml-var " _.aux.sql_quote(x)..."

This idea has merit, and extends the usefulness of these options to parts of
an expression rather than just the whole thing. I think calling the module
'aux' might not be the best for code readability sake though. Perhaps it
should just be called fmt or format. Perhaps like so:

dtml-var "... _.fmt.expr(x, '%.2f') ..."
and
dtml-var "... _.fmt.string_quote(x) ..."

newbie format methods could be added too (Feature creep alert!) like:

dtml-var "... _.fmt.currency(x) ..."

in place of the first one.


___
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] Acquisition Confusion :S

2000-07-31 Thread Chris Withers

Hi Jim, (or any zope-dev'ers who can explain this ;-)

I've just been reading:
http://www.zope.org/Members/jim/Info/IPC8/AcquisitionAlgebra

...and I've got confused on the 'Getting the containment wrapper'
section.

In anser to 'What is A.B.C.D?' I can't see how you can get:
((D o (C o A)) o (B o A))

Here's my working:

A.B.C.D = (B o A) : .C.D
= ((C o A) o (B o A)) : .D
= ((D o C) o ((C o A) o (B o A)))

You can't apply the simplification:
((Z o Y) o (Y o Z))

to the leftmost section 'cos the brackets are in the wrong place...

so how to you make the jump to:

= ((D o (C o A)) o (B o A)) (but should it?!)

Also, is the definition "aq_inner is obtained by finding the innermost
wrapped object" the same as "aq_inner is the 'self'/'object' part of the
current aquisiton wrapper"?

Confusedly and looking for help,

Chris

___
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] ZOracle LOB Questions

2000-07-31 Thread Matthew T. Kromer

Alexander Schad wrote:
 
  Alex, Oracle 8i broke DCOracle's support for LOBs; DCOracle primarily
  uses OCI 7 (Oracle 7) calls, and Oracle 8i enforces a restriction that
  OCI 8 objects cannot be used in the context of an OCI 7 statement.
 
  You can use Oracle 8.0 for this, the restriction isn't enforced until
  Oracle 8.1.
 
 
 Hello!
 thank you for your answer. but does that mean that i can only use LOBS
 with Oracle 8.0 ?
 i'm confused. i need to use LOBs. if i use oracle 8.1 can i use LOBS and
 if yes which Databse adapter do i need?

If your database adapter is 8.0 you can probably use LOBs, if
the adapter is 8.1 you probably can't.  I never mix and match
adatpters vs. databases, though, so your mileage my vary.  By
this I mean, you could use 8.0 libraries to access an 8.1
database via SQL*NET.  I *think* the error is actually being
raised at the library level, not the server itself.

___
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] Are full pathnames in error messages a security bug?

2000-07-31 Thread R. David Murray

I don't know if this has been raised before, but the following excerpt
from the most recent SANS security alert concensus made me think:

-- Forwarded message --
[...]
-- {00.31.014} Apache TomCat leaks system information

Apache's TomCat server has been found to provide various types of system
information to an attacker-such as full system paths being displayed in
error messages. TomCat also comes with the "snoop" servlet, which
provides even more detailed information about the system when invoked.



Obviously the 'snoop' servlet is the reason this was posted, but
still, they are calling full path information a security leak.
Not perhaps something to put high on a priority list, but should there
be a way to prevent full path information from appearing in
error messages?  It would have the side benefit of making the
error messages more readable grin.

--RDM


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




Re: [Zope-dev] MethodGeddon

2000-07-31 Thread Shane Hathaway

Chris Withers wrote:
 
 http://www.zope.org/Wikis/zope-dev/MethodGeddon
 
 Just been reading about this and I was wondering how is coming along...

After more pondering I decided to throw out the idea for typed
arguments.  I was trying to solve a difficult problem with a
roundabout, and in the end more difficult solution.

 Is it in the fishbowl under another name or should it be in the
 fishbowl?

It would actually fall under the the "Current Projects" section.

http://dev.zope.org/Wikis/DevSite/Projects/PythonMethods/MethodObjectInterface

Alright, I didn't put it my comments in exactly the right place, but
it's close enough. :-)

 Shane, would the argument list be a management tab for methods?
 That sounds cool to me :-)

What I have done instead (and this is exactly the way Jim envisioned it
months ago) is added a "Bindings" tab to Python methods.  You just fill
in the names to be populated with an object's container, its context,
itself, the DTML namespace, and (this just in :-) the traversal
subpath.  Then I did the same thing with External Methods and combined
them into one product.  Unless my changes are vetoed, in the future you
won't be adding "External Methods" and "Python Methods" anymore, you'll
be adding "Python Method (Internal)" and "Python Method (External)"
instead.

I've checked it all into CVS but I'm not sure it's available to the
public.  Perhaps it should be; lobby Ken or Brian.  It's the module
Packages/Products/PythonMethod.

 I reckon 'self' should always be the equivalent of the python 'self' or
 not exist to avoid confusion. I guess that means it wouldn't get used
 much since it would be the actual method-object (and I thought that was
 an oxymoron ;-) but with the possibility opf things like __render__ and
 __call__, who knows...

Jim solved this confusion by letting you invent your own names, then we
made it easier to use by providing "recommended names": container,
self, m_self (the method object), _, and traverse_subpath.

Now, the bindings still aren't available to DTML methods.  But it
shouldn't be difficult to add.

 ...
 So you could get to any or all of those as you need in your method. Of
 course, new users wouldn't have to worry about this until they needed to
 do something that used it.

Right.  An important feature.

Shane

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




Re: [Zope-dev] Re: ZScheduler and SSL

2000-07-31 Thread R. David Murray

On Mon, 31 Jul 2000, Loren Stafford wrote:
 If there is a generally available solution to this SSL client problem, I
 wouldn't mind building it into ZScheduler as an option. At the very least, I
 could encapsulate the client interface in a separate module. Then you could
 conveniently replace that module with your own.

Lynx has an ssl capable version, but it is currently considered
too buggy to be safe.

w3m also has an ssl version. 

Unfortunately I don't know if the ssl version of either one is
available for Windows.

--RDM


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




Re: [Zope-dev] Ids starting with _

2000-07-31 Thread Chris Withers

Toby Dickenson wrote:
 Almost all zope-manageable classes (and certainly Folders, that Dieter
 mentioned) use the old rule. This happens because they derive from
 SimpleItem.Item, which has __allow_access_to_unprotected_subobjects__=1

1) Why does SimpleItem still have this?! Since so much, IIRC, is derived
from SimpleItem.Item, surely this goes very much against the grain of
'everything should be protected unless I say otherwise'?

2) Why does having __allow_access_to_unprotected_subobjects__=1 mean
that the 'start with _ = hidden/no DTML, no web Access' ruel applies?

cheers,

Chris

___
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: Collector #1457: DateTime strftime() -- still broken

2000-07-31 Thread Steve Alexander

[EMAIL PROTECTED] wrote:
 
 Steve Alexander reported:
 
  This is a patch to address collector item 1455.
 
  Here's a working patch to make formatting of a DateTime instance work as generally 
expected, when you use
 
dtml-var "_.DateTime()" fmt="%d %H %z"
 
  or whatever.
 
  It could be made more efficient by compiling the two regular expressions into 
class attributes. However, a bug in ts_regex stops it using compiled regular 
expressions in gsub.
 
  See the following URL for a description of the regex bug.
 
  http://lists.zope.org/pipermail/zope-dev/2000-July/006105.html
 
 
 
 with patch:
 
  *** lib/python/DateTime/DateTime.old.py   Sun Jul 23 20:03:04 2000
  --- lib/python/DateTime/DateTime.py   Mon Jul 24 14:01:37 2000
  ***
  *** 1376,1382 
return millis
 
def strftime(self, format):
  ! return strftime(format, gmtime(self.timeTime()))
 
# General formats from previous DateTime
def Date(self):
  --- 1376,1385 
return millis
 
def strftime(self, format):
  ! diff=_tzoffset(self._tz, self._t)
  ! format = ts_regex.gsub('\(^\|[^%]\)%Z', '\\1'+self._tz, format)
  ! format = ts_regex.gsub('\(^\|[^%]\)%z', '\\1%+05d' % (diff/36), format)
  ! return strftime(format, gmtime(self.timeTime()+diff))
 
# General formats from previous DateTime
def Date(self):
 
 
 Thanks for the report. Per popular demand based on list
 feedback, strftime() now formats using the current timezone
 representation of the DateTime object (consistent with all
 of the other DT formatting methods).
 
 For those who really needed it to format based on GMT, you
 can use the toZone() method to get a copy of the DateTime
 object represented in GMT and call the formatting methods
 on that object:
 
   dtml-var "myDate.toZone('GMT')" fmt="%y, %m, %d"
 
   or
 
   dtml-var "myDate.toZone('GMT').strftime('%y, %m, %d')"
 
 -Brian

I just looked at the fix in CVS. I'm sad to report that it is still
broken.

Here's the patched method from CVS:

def strftime(self, format):
# Format the date/time using the *current timezone
representation*.
jfirst = _julianday(self._year, 1, 1) - 1
jtoday = _julianday(self._year, self._month, self._day)
julian = jtoday - jfirst
time_info=(self._year, self._month, self._day,
   self._hour, self._minute, self._nearsec,
   (self._dayoffset + 6) % 7,
   julian,
   0)
return strftime(format, time_info)


This gets time.strftime to format the time in the DateTime instance,
shifted by an appropriate amount. However, if you try and format with %z
or %Z to display the timezone information, it always comes out as GMT.
So, the implementation has gone from correct but not useful, to
generally useful but technically incorrect.

To see the problem, apply the patch and try this DTML snippet:

dtml-let time1="_.DateTime('2000/07/23 14:03 BST')"
  Time: dtml-var time1 fmt="%B %d, %Y %H:%M %Z" br
  Time: dtml-var "time1.fCommonZ()" br
/dtml-let



This prints out the following:

Time: July 23, 2000 14:03 GMT 
Time: July 23, 2000 2:03 pm GMT+1 

They are being presented as different times.
The first one should read "Time: July 23, 2000 14:03 GMT+1".

A solution is to replace the %Z and %z format substrings with correctly
calculated values, as in my original patch, included towards the start
of this message.

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

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




Re: [Zope-dev] Acquisition Confusion :S

2000-07-31 Thread Chris Withers

I still don't get this :(

Here's the situation:

A has attributes B and C, C has attribute D

my old working:

A.B.C.D = (B o A) : .C.D

now, since C is found in A:

= ((C o A) o (B o A)) : .D

again since D is found in C:
 
= ((D o C) o ((C o A) o (B o A)))

However, this:
 This last line should be (((D o C) o (C o A)) o ((C o A) o (B o A))), which

Implies that rather than the rule I was working on which was:
If X is found in Y, the next line becomes ((X o Y) o {the last line})

This rule applies:
If X is found in Y, then the next line becomes (((X o Y) o (wrapper of
which Y was either parent or self)) o {the last line})

Is this the case?

If so, why? ;-)

 In this case aq_inner is the entire
 expression, since aq_self is not a wrapper.

I still don't get this at all :(

I hoep someone can help more :~(

 The IPC8 slides are in error, and need to be fixed.

Similarly, does the dev-wiki still have a purpose? It feels like the
unmaintained precursor to dev.zope.org...

cheers,

Chris

___
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] ZOracle LOB Questions

2000-07-31 Thread Matthew T. Kromer

Alexander Schad wrote:
 
 Hello!
 
 i have Oracle 8.1.6 ZOracleDA 2.2 installed with Zope 2.1.6 on a red hat
 linux machine.
 
 i have an oracle table with one column containing blobs. Now i have
 the following problems:
 
 1. How can i retrieve data from that table in zope or in python (syntax) ?
 
 2. How can i insert data to that table ?
i need the zope syntax something like:
 insert into blob_table values ('dtml-var image') ???
or the python syntax
 
 i have written a little script:
 
 import DCOracle, sys, os, DCOracle.dbi
 
 dbc = DCOracle.Connect('mozdb_dba/mozdb_dba')
 cur = dbc.cursor()
 fn = open('test_img.jpg','rb')
 data = fn.read()
 fn.close()
 param = DCOracle.dbi.dbiRaw(data)
 cur.execute('select blobcol from blobtable')
 dat = cur.fetchone()
 cur.close()
 dbc.close()
 print dat
 
 when i try to execute it i get the following error:
 
 Traceback (innermost last):
   File "blobtest.py", line 12, in ?
 dat = cur.fetchone()
   File "DCOracle/ociCurs.py", line 339, in fetchone
 self._error()
   File "DCOracle/ociCurs.py", line 109, in _error
 raise error, (rc, oci_.OracleErrorMessage(self._c.lda, rc))
 oci.error: (24813, 'ORA-24813: cannot send or receive an unsupported
 LOB\012')
 
 3. Is there a way to call a stored procedure or function that actually
return values ?
i succeeded in retrieving one particular value out of a table but when
i try a function like :
 select * from some_table
i fail...
 
 4. Changes.txt:
 
   Z Oracle DA Releases
 
   2.2.0
 
 Added a small feature that allows you to access LOBs in the Oracle
 database.  To do this, you must have your maximum number of
 results set to '1'.  Otherwise, it won't work.
 
   i don't know what this is referring to. where should i make this change?
 
 Ciao,
 Alex


Alex, Oracle 8i broke DCOracle's support for LOBs; DCOracle primarily
uses OCI 7 (Oracle 7) calls, and Oracle 8i enforces a restriction that
OCI 8 objects cannot be used in the context of an OCI 7 statement.

You can use Oracle 8.0 for this, the restriction isn't enforced until
Oracle 8.1.

___
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/Zope API

2000-07-31 Thread Kapil Thangavelu

 2. Are there ways to improve it? For example I would love to know how
you can check if you can actually render an object. (For example
you can not render Control_Panel).

To render your python product objects in Zope like
dtml-var yourObject
you just define a method __str__

take a look at python code for the base ZClass Renderable

probably the easiest thing to do in your python product

install renderable

in your python file 

import Renderable

and add Renderable as base class.

if you want have the display html in python you can do an extended
python string ''' '''

and define a method render that returns it

or use the HTMLFile and Globals (ala most Zope Products) and do it as an
html file

Cheers

Kapil

"Alexandre A. Rodioukov" wrote:
 
 Hello folks.
 
 I want to be able to render Zope objects from my python external
 method/product. Idea is to use it to render parent object. Here is
 code I came up so far with:
 
 def view(self, REQUEST):
 if self.meta_type == 'Folder':
 doc = self.aq_base.index_html(self, self.REQUEST)
 else:
 doc = self.aq_base(self, self.REQUEST)
 return doc
 
 It does return rendered parent object, but I have some questions and
 probably request for improvement ideas :)
 
 1. The whole thing becomes broken with SiteAccess. Complains about
premissions/PhysicalRoot (AFAIR)
 
 2. Are there ways to improve it? For example I would love to know how
you can check if you can actually render an object. (For example
you can not render Control_Panel).
 
 Possible use for it (to make the whole idea a bit clearer)
 
 /index_html (some stuff in it)
 /view (above code in external method)
 
 /index_html/view returns rendered index_html doing some magic with
 HTML/whatever is in it (for example encrypts it with public key, strips
 down carriage returns/tabs/spaces etc...) In other words acts as a
 filter.
 
 Thanks for any advice,
 
 Regards, Simuran.
 
 ___
 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] Calender Tag SQL caching

2000-07-31 Thread Kapil Thangavelu

Arjan Scherpenisse wrote:
 
 Hi everybody,
 
 This is my first posting to this list. I have a website which will
 make use of a calender, with events on it stored in a MySQL
 database. Now, i wondered how to efficiently show this data from the
 database in the calender. I mean, not in a way that a sql query is
 made for each day on the calender (which would make up to 31 queries
 in the Calender Tag 'month' view...)

 So i wondered, is there some way to 'cache' the result of the SQL
 method, so that i can use just one query to fill up an entire month,
 for instance?

welcome to zopeland.

SQL methods automatically cache themselves (check the advanced screen
under /manage of the SQL method in question). unless you're passing in
different arguements for each day, in which case you're probably better
off retrieving all the calendar events at once you should have to worry
about it. if you have any questions how, send me a copy of the schema
for
the tables. there is a tradeoff for ram but unless you have a large
calendar it shouldn't make a difference.

cheers

Kapil



 
 regards,
 --
 Arjan Scherpenisse
 [EMAIL PROTECTED]
 
 may the source be with you
 === http://www.gnu.org ===
 
 ___
 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] Calender Tag SQL caching

2000-07-31 Thread Kapil Thangavelu

Arjan Scherpenisse wrote:
 
 Hi everybody,
 
 This is my first posting to this list. I have a website which will
 make use of a calender, with events on it stored in a MySQL
 database. Now, i wondered how to efficiently show this data from the
 database in the calender. I mean, not in a way that a sql query is
 made for each day on the calender (which would make up to 31 queries
 in the Calender Tag 'month' view...)
 
 So i wondered, is there some way to 'cache' the result of the SQL
 method, so that i can use just one query to fill up an entire month,
 for instance?

welcome to zopeland.

SQL methods automatically cache themselves (check the advanced screen
under /manage of the SQL method in question). unless you're passing in
different arguements for each day, in which case you're probably better
off retrieving all the calendar events at once you should have to worry
about it. if you have any questions how send me a copy of the schema for
the tables. there is a tradeoff for ram but unless you have a large
calendar it shouldn't make a difference.

cheers

Kapil

 
 regards,
 --
 Arjan Scherpenisse
 [EMAIL PROTECTED]
 
 may the source be with you
 === http://www.gnu.org ===
 
 ___
 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] getslice Error?

2000-07-31 Thread Marko MARKOVIC

Hi all,

with this little code :

dtml-in "showNSDetails(nsref=old_nsref)" start=query_start
dtml-call "REQUEST.set('sdate','%s.%s.%s' %
(ns_entrydate[8:],ns_entrydate[5:7],ns_entrydate[:4]))"
input type="text" name="new_nsentrydate" value="dtml-var sdate"
size="10"
/dtml-in

ns_entrydate is a field of my query.

i get an getslice error:

Zope Error
Zope has encountered an error while publishing this resource.

Error Type: AttributeError
Error Value: __getslice__

Traceback (innermost last):
  File D:\PROGRA~1\INTRAN~1\lib\python\ZPublisher\Publish.py, line 214, in
publish_module
  File D:\PROGRA~1\INTRAN~1\lib\python\ZPublisher\Publish.py, line 179, in
publish
  File D:\PROGRA~1\INTRAN~1\lib\python\Zope\__init__.py, line 202, in
zpublisher_exception_hook
(Object: ElementWithAttributes)
  File D:\PROGRA~1\INTRAN~1\lib\python\ZPublisher\Publish.py, line 165, in
publish
  File D:\PROGRA~1\INTRAN~1\lib\python\ZPublisher\mapply.py, line 160, in
mapply
(Object: editNoteServiceForm_html)
  File D:\PROGRA~1\INTRAN~1\lib\python\ZPublisher\Publish.py, line 102, in
call_object
(Object: editNoteServiceForm_html)
  File D:\PROGRA~1\INTRAN~1\lib\python\OFS\DTMLMethod.py, line 150, in
__call__
(Object: editNoteServiceForm_html)
  File D:\PROGRA~1\INTRAN~1\lib\python\DocumentTemplate\DT_String.py, line
502, in __call__
(Object: editNoteServiceForm_html)
  File D:\PROGRA~1\INTRAN~1\lib\python\DocumentTemplate\DT_In.py, line 611,
in renderwb
(Object: showNSDetails(nsref=old_nsref))
  File D:\PROGRA~1\INTRAN~1\lib\python\DocumentTemplate\DT_Util.py, line
335, in eval
(Object: REQUEST.set('sdate','%s.%s.%s' %
(ns_entrydate[8:],ns_entrydate[5:7],ns_entrydate[:4])))
(Info: REQUEST)
  File string, line 0, in ?
  File D:\PROGRA~1\INTRAN~1\lib\python\DocumentTemplate\DT_Util.py, line
174, in careful_getslice
  File D:\PROGRA~1\INTRAN~1\lib\python\DateTime\DateTime.py, line 922, in
__getattr__
AttributeError: (see above)


what's wrong?  Do you know where i can found information about zope erorrs,
i want to know what means all these errors that we get?

Thanks for your help!

$Regards

MM



___
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: What is the best method to enter more attributes about DTL Document?

2000-07-31 Thread Frederic QUIN

Hi Marcin,


you can write a new HTML page which add a new document. This page must
contains a form which post the datas to the method "AddDTMLDocument",
responsible for the creation of this object.
But, if you need for example, to associate new properties to the new
Document, you have to rewrite also the method "AddDTMLDocument". The
destination of your form is now "AddMyDoc" and this new method must contains
a line similar to :

dtml-call "manage_AddDTMLDocument(...)"


Just write me for more details
Bye
Frederic


___
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] FSSession - don't call FSSession twice!

2000-07-31 Thread icottee



I've been using the excellent FSSession product (many thanks Mr Christoforou) to
hold some information on the language a user wishes to display a page in. I kept
having weird errors however - every now and again I'd change some code somewhere
completely unrelated (even just adding a user) and FSSession would break.
Undoing the last change wouldn't help. The error was to do with _v_data and (I
think) _v_id or something similar.

This post isn't about that problem.

From reading through the extremely useful nipltd archives it appeared the
problem was not doing a dtml-call FSSession at the beginning of the code. This
was bemusing because that code was sitting in my standard header and called
everywhere. However, I had an uneasy workaround which did a 'try' on using
FSSession and if it failed initialise it in the normal way. I say 'uneasy'
because I didn't know why I needed it and when I added another bit of code to
handle another cookie that needed to be recorded it broke again.

This post isn't about that problem either.

I decided enough was enough today and thought I'd try and find out what was
happening. So I could give some proper information to Pavlos Christoforou I
downloaded the latest version of FSSession and tried to reproduce my error. Bang
- I got a much more impressive error. Whenever I went to any of my pages that
used FSSession I got the following.

Zope has encountered an error while publishing this resource.

Error Type: OSError
Error Value: [Errno 2] No such file or directory


Followed by the following traceback

Traceback (innermost last):
  File /usr/local/zope/lib/python/ZPublisher/Publish.py, line 222, in
publish_module
  File /usr/local/zope/lib/python/ZPublisher/Publish.py, line 187, in publish
  File /usr/local/zope/lib/python/Zope/__init__.py, line 221, in
zpublisher_exception_hook
(Object: ElementWithAttributes)
  File /usr/local/zope/lib/python/ZPublisher/Publish.py, line 175, in publish
  File /usr/local/zope/lib/python/Zope/__init__.py, line 235, in commit
  File /usr/local/zope/lib/python/ZODB/Transaction.py, line 296, in commit
  File /usr/local/zope/lib/python/Shared/DC/ZRDB/TM.py, line 122, in tpc_finish
(Object: TM)
  File /usr/local/zope/lib/python/Products/FSSession/FSSession.py, line 84, in
_finish
(Object: TM)
  File /usr/local/zope/lib/python/Products/FSSession/FSSession.py, line 193, in
final_commit
(Object: FSSession)
OSError: (see above)

Interestingly the line above 193 in FSSession.py is a comment which reads
'should never fail'.  Well it does and the reason is (as you may have guessed
from the title) that I called FSSession twice. Line 193 appears to rename a .tmp
file and I'd guess that by calling it twice my second attempt fails as the file
has already been renamed. Obviously this isn't the way I should be doing things
and I'm going to have a go and see if the new version of FSSession cures my
earlier problems. The reason I mention this now is that the problem causes any
future attempts at transactions to give the following error - which can only be
remedied by restarting zope.

Error Type: TransactionError
Error Value: A serious error, which was probably a system error, occurred in a
previous database transaction. This application may be in an invalid state and
must be restarted before database updates can be allowed. Beware though that if
the error was due to a serious system problem, such as a disk full condition,
then the application may not come up until you deal with the system problem. See
your application log for information on the error that lead to this problem.

So if you make the same mistake as I did on a production server you will not be
popular :-). I'm running this on Zope 2.2.0 by the way (although it happens on
the previous production version as well).

Hope this is of some use

Ian



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




[Zope] Log Out

2000-07-31 Thread Kapil Thangavelu

Is there a way to log out of Zope without presenting a netscape dialog
or killing the browser?

i'd prefer that users have a link 'logout' that takes them back to the
/root/index_html as anonymous

___
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] zodbc and mssql

2000-07-31 Thread shortie



hello zopers,

 i have swithed to windows 2000 from redhat 
linux 6.2,
 and now zope can response to my 
request.there comes
 another problem.

 the situation is i can add a z odbc 
database connection
 to mssql and i can add a sql method using 
this database
 connection. but when i try to include the 
sql method in
 dtml document, zope keeps asking me 
username and
 password. how could this happen? did i miss 
something again?

 thanks

--'Life is like boxes of chocolate, Forrest. You never 
know what you're gonnaget.' -- Forrest Gump (1994)Lo Chung-Chang 
(shortie)[EMAIL PROTECTED] 
ICQ#27118251Kaohsiung.Taiwan.Roc.Earth.Solar.Galaxy.Universe



[Zope] what products to use?

2000-07-31 Thread Owen Smith

Hi all
I am trying to implement a site which needs the following-
A forum/discussion
a database of members (400+) who can access certain parts of the site
not available to anonymous users
the ability for members to change their details online
the ability for new members to sign up online
which products or methods should I look at using with Zope
anyone running a similar setup?
(I am confused by choice what works whats current etc etc!)
Owen (newbie!)


___
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] using sister folder methods ?

2000-07-31 Thread Gijs Reulen

Hi

I have a root level folder with a DTML Document. From within this document I
want to use a DTML Method that is located in a sister folder; another folder
from the root.
I tried the full path but that does not seem to work.
What else ?

Gijs Reulen


___
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: Unique id product

2000-07-31 Thread Gijs Reulen

A different approach:
For each entry I just use the current date/time including a call:
time.sleep(0.001) This way I am sure each entry will have a unique id. It is
only slightly slower (0.001 second for each calc). However, it requires
serial processing of entries and a stable time (only server-side
processing). Therefore very usable for processing batch-entries as I do.

Gijs Reulen

 -Oorspronkelijk bericht-
 Van: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]Namens Steve
 Alexander
 Verzonden: vrijdag 28 juli 2000 19:20
 Aan: [EMAIL PROTECTED]; Sin Hang Kin
 Onderwerp: [Zope] Re: Unique id product


 On 2 July, 2000 Steve Alexander wrote:
 
  If you just want ids that are unique to a folder, try the following
  algorithm (taken originally from the Discussion object code in the PTK).
  The variable "self" is the one passed to the constructor method of a
  particular Python class, and represents the folder you want to put the
  new object into. I'm assuming the object is a "FooBar Item". The
  "foobar-%06d" bit generates a unique id for the object that looks like
  "foobar-290172837", based on the current time.
 
  id = int(DateTime().timeTime())
  while hasattr(self, str(id)):
  id = id +1
  id = 'foobar-%09d' % id
 
  The advantage of this approach is that there is very little contention
  in most cases.

 I just looked back over some code where I used this algorithm, and I
 realised that it doesn't actually work :-(  The identifiers that are
 searched for do not reflect the identifiers that are produced.

 The original code from the PTK does work. Here it is, adapted very
 slightly:

 # Find an unused id in location
 id = int(DateTime().timeTime())
 while hasattr(self, `id`):
 id = id + 1
 return id

 Here's my own, now fixed, code. Note the addition of a "max_tries"
 variable.

 if id == 'auto' or id == None:
 n = int(DateTime().timeTime())
 max_tries = 10
 fk = lambda key: 'foobar-%d' % key  # function to format key
 id = fk(n)
 while max_tries and hasattr(self, str(id)):
 n = n + 1
 max_tries = max_tries-1
 id = fk(n)


 Sorry for posting such rubbish the first time around :-/

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

 ___
 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: zodbc and mssql

2000-07-31 Thread shortie



answer to my own question:

anyone who have exact problem can find your answer 
at

http://www.egroups.com/message/zope/36394

i will search the archive before asking any question next 
time.
sorry for the inconvinence.

--'Life is like boxes of chocolate, Forrest. You never 
know what you're gonnaget.' -- Forrest Gump (1994)Lo Chung-Chang 
(shortie)[EMAIL PROTECTED] 
ICQ#27118251Kaohsiung.Taiwan.Roc.Earth.Solar.Galaxy.Universe


- Original Message - 
±H¥óªÌ: shortie 

¦¬¥óªÌ: [EMAIL PROTECTED] 
¶Ç°e¤é´Á: 2000¦~7¤ë31¤é ¤U¤È 05:03
¥D¦®: zodbc and mssql

hello zopers,

 i have swithed to windows 2000 from redhat 
linux 6.2,
 and now zope can response to my 
request.there comes
 another problem.

 the situation is i can add a z odbc 
database connection
 to mssql and i can add a sql method using 
this database
 connection. but when i try to include the 
sql method in
 dtml document, zope keeps asking me 
username and
 password. how could this happen? did i miss 
something again?

 thanks

--'Life is like boxes of chocolate, Forrest. You never 
know what you're gonnaget.' -- Forrest Gump (1994)Lo Chung-Chang 
(shortie)[EMAIL PROTECTED] 
ICQ#27118251Kaohsiung.Taiwan.Roc.Earth.Solar.Galaxy.Universe



Re: [Zope] PTK question ..

2000-07-31 Thread Chris Withers

Jean Jordaan wrote:
   ZopePTK-0.7.1.tar.gz

Erk :(

Theres' a much newer snapshot available at:

http://www.zope.org/Members/taz/PTK

cheers,

Chris

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




Re: [Zope] How can I proxy from apache to zope and keep source host info?

2000-07-31 Thread Marcin Kasperski

Phil Harris wrote:
 
 There is a patch to Apache that you could apply that passes the client IP
 along in a different HTTP header, if that helps.
 
 It's at http://modules.apache.org/search?id=124.
 

Does anyone has this module compiled for apache 1.3 handy (I mean
mod_add_proxy.so file)? I use binary Debian apache distribution and it
will take some time to download and rebuild apache from sources...

--
 www.mk.maxi.pl  | Teams do not make linear progress through analysis.  
Marcin.Kasperski | They don't start with requirement 1 and analyze it,  
  @softax.com.pl | then move to requirement 2 and analyze it. (...) 
@bigfoot.com | Analysis tends to be revolutionary. (Martin)

___
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] Can't create ZClass under 2.2.0

2000-07-31 Thread Tony McDonald

Hi all,
I've got the Beehive tutorial on Zclasses and thought I'd try it out 
on a 2.2.0 system we have here.

I have 'create constructor types'  and 'nclude standard Zope 
persistent object base classes?
' set. I've tried selecting various Base Classes (and no base 
classes), but get the following traceback.

!--
  Error type:  Could not load oid 
info maycontain clues
  Error value: None
  --
!-- end of bodytext area --

/body
/html


!--
Traceback (innermost last):
   File /home/zope/Zope-2.2.0/lib/python/ZPublisher/Publish.py, line 
222, in publish_module
   File /home/zope/Zope-2.2.0/lib/python/ZPublisher/Publish.py, line 
187, in publish
   File /home/zope/Zope-2.2.0/lib/python/Zope/__init__.py, line 221, 
in zpublisher_exception_hook
 (Object: ElementWithAttributes)
   File /home/zope/Zope-2.2.0/lib/python/ZPublisher/Publish.py, line 
171, in publish
   File /home/zope/Zope-2.2.0/lib/python/ZPublisher/mapply.py, line 
160, in mapply
 (Object: manage_addZClass)
   File /home/zope/Zope-2.2.0/lib/python/ZPublisher/Publish.py, line 
112, in call_object
 (Object: manage_addZClass)
   File /home/zope/Zope-2.2.0/lib/python/ZClasses/ZClass.py, line 154, 
in manage_addZClass
 (Object: ElementWithAttributes)
   File /home/zope/Zope-2.2.0/lib/python/OFS/ObjectManager.py, line 
260, in _setObject
 (Object: ElementWithAttributes)
   File /home/zope/Zope-2.2.0/lib/python/ZClasses/ZClass.py, line 421, 
in manage_afterAdd
 (Object: bookclass)
   File /home/zope/Zope-2.2.0/lib/python/ZClasses/ZClass.py, line 374, 
in _register
 (Object: bookclass)
   File /home/zope/Zope-2.2.0/lib/python/ZODB/Connection.py, line 447, 
in setstate
   File /home/zope/Zope-2.2.0/lib/python/ZODB/Connection.py, line 213, 
in _persistent_load
 (Info: 
   File /home/zope/Zope-2.2.0/lib/python/ZODB/Connection.py, line 154, 
in __getitem__
 (Info: ('\000\000\000\000\000\000\014\300', 
'(cExtensionClass\012ExtensionClass\012q\001(U\006ZDItemq\002(cZClasse 
s.ZClass\012PersistentClass\012q\003cProducts.ZDBase.ZDiscussions\012Z 
DItem\012q\004cOFS.SimpleItem\012SimpleItem\012q\005tq\006}q\007(U\004 
iconq\010UWControl_Panel/Products/ZDiscussions/ZDTopic/propertysheets/ 
methods/ZDItem%20/ziconImageq\011U\012_p_changedq\012K\001U\007__doc__ 
q\013U\021ZDiscussions 
Itemq\014U\006_p_oidq\015U\010\000\000\000\000\000\000\002Lq\016U\011m 
eta_typeq\017U\021ZDiscussions 
Itemq\020U\016propertysheetsq\021(U\010\000\000\000\000\000\000\014\30 
3q\022(NU\010\000\000\000\000\000\000\014\277q\023Qttq\024QU\011replyF 
ormq\025cZClasses.Method\012MW\012q\026NRq\027}q\030U$_ZClassMethodPer 
missionMapperMethod_q\031(U\010\000\000\000\000\000\000\014\304q\032(U 
\016OFS.DTMLMethodq\033cOFS.DTMLMethod\012DTMLMethod\012q\034ttq\035Qs 
bU\012index_htmlq\036h\026NRq\037}q 
h\031(U\010\000\000\000\000\000\000\014\305q!(h\033h\034ttqquot;QsbU\ 
016manage_optionsq#(}q$(U\005labelq%U\010Securityqamp;U\006actionq\'U 
\015manage_accessq(u}q)(h%U\004Viewq*h\'U\012index_htmlq+u}q,(U\005lab 
elq-U\012Propertiesq.U\006actionq/U\025manage_propertiesFormq0utq1U\01 
2ziconImageq2(U\010\000\000\000\000\000\000\014\306q3(U\011OFS.Imageq4 
cOFS.Image\012Image\012q5tq6tq7QU\022__ac_permissions__q8)U\011_p_seri 
alq9U\010\003/\363\246\016\005\353\325q:U\012__module__q;U\031*73biqpA 
I2QDa2iKPitv57g==qlt;utq=t.N.'))
Could not load oid 
contain clues: (see above)

--

Thing is, I've deleted the ZDiscussions and ZBase products as well as 
packing the database - these products shouldn't be there Anyone 
got any ideas?

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

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




Re: [Zope] zope.org down

2000-07-31 Thread Diny van Gool

Hi,

After downloading the InterBase 6.0 check the version of IBConsole because
the 309 version is corrupt. When you try to connect to a database you'll
get the following message:
"error connecting to database" ... "DPB Constant (0) is unknown"

Download the 308 version of OBConsole at:

http://www.interbase.com/open/downloads/ib_download.html

Diny

At 17:57 29-7-00 +0200, [EMAIL PROTECTED] wrote:
Chris Withers wrote:
 
 Chris McDonough wrote:
  The InterbaseStorage product is full-featured (undo, versioning).  But
  I've gotten little response to releasing it, and I don't think anyone is
  using it, so bugs are sure to exist.
 
 I don't think you announced this loudly enough ;-)
 
 Is interbase stable/OSS? 

Yes, it has been developed by Borland/Inprise commercially for
many years. They open-sourced it recently, going through a long
beta period.

 Where can I get it from?

http://www.inprise.com

 Where is the
 InterBaseStorage product (and documentation ;-) available?

See the ZopeTreasures page Beehive has set up. A nice piece of
work in tasteful day-glo colors :-)

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 )



DIVA, Faculty of Veterinary Medicine
Utrecht University,  The Netherlands
http://www.vet.uu.nl 

___
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] Problem displaying Informix INTERVALs using DTML

2000-07-31 Thread Raymond Kelly

Hi,

I am using Zope on a PC running on NT and using ODBC to connect to a
Informix database. I am running a query that returns a column of
INTERVAL type, calculated by subtracting to DATE types.

The query, when tested using the test tab, displays the results as I
expected. However, when I try to display the results using either a
search interface, or my own DTML method, NETSCAPE 4.7 refuses to display
the results. Instead it reckons it cannot handle the resultant HTML from
the DTML used to produce the results page. Instead, it decides the best
thing to do is save the file but when it is reloaded it load just fine.
IE5 does get a little further and it will display the page but there are
numerous strange characters at the end of the expected interval field.

This seems like some additional characters are coming back from the
query and they may cause Netscape to trip up and IE5 to display odd
characters.

What I have tried to do, without sucess, is to get access to the DTML,
within Zope, which produces the results of a test on an SQL query. This
is where the solution lives!, but I plain just can't find it.

I have tried formating the the INTERVAL type and truncating but nothing
yields the same results as the 'test' DTML.

Any ideas for a poor Zope newbie.

Thanks

Raymond

___
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] Sorting XML nodes?

2000-07-31 Thread Jean Jordaan

Hi Zopers (and Lex),

From the (excellent) 'How-To: XMLDocument Example' (Created 
by eukreign. Last modified on 2000/06/06) I get the following 
to display all the nodes of an XML document:

dtml-in "contacts[0].getElementsByTagName('contact')"
tr
td dtml-var "text_content('firstname')"
 dtml-var "text_content('lastname')"/td
td dtml-var "text_content('extension')"/td
td a href="dtml-var "absolute_url()"/edit"edit/a/td
td a href="dtml-var "absolute_url()"/delete"delete/a/td
/tr
/dtml-in

I want something along the lines of:
  dtml-in "contacts[0].getElementsByTagName('contact')" 
   sort="lastname"

Is such a thing possible?

Thanks!
-- 
jean

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




[Zope] ZCatalog updating

2000-07-31 Thread Aaron Williamson

I am convinced this is a stupid question that has been answered a
hundred times already, but after scouring zope.org and the archives, I
still don't know the answer, so...

How can I automatically update my ZCatalog when items have been
added/modified/changed?

Thanks for any help,

Aaron


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




Re: [Zope] ZCatalog updating

2000-07-31 Thread Chris Withers

Aaron Williamson wrote:
 How can I automatically update my ZCatalog when items have been
 added/modified/changed?

CatalogAware

Chris

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




[Zope] Passing 'document_title' to 'standard_html_header' from a method?

2000-07-31 Thread Jonathan

Hi all,

I can't seem to get the 'document_title' from a method into a 
standard header (when using 'dtml-var document_title' in the header 
file the generated page uses the title of the header file itself.

Using 'title_or_id' in the header file for a method uses the title or 
id from the folder it is in, not the title from the method itself.

Any ideas? I didn't really find a solution in the archives; it does 
work with DTML Documents, but not with DTML Methods?

Thnx,
Jonathan

___
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] what products to use?

2000-07-31 Thread Kapil Thangavelu

Owen Smith wrote:
 
 Hi all
 I am trying to implement a site which needs the following-
 A forum/discussion
 a database of members (400+) who can access certain parts of the site
 not available to anonymous users
 the ability for members to change their details online
 the ability for new members to sign up online
 which products or methods should I look at using with Zope
 anyone running a similar setup?
 (I am confused by choice what works whats current etc etc!)
 Owen (newbie!)
 

ZopePTK plus squishdot sounds perfect depending on what kind of user
info you want to store you stick it in FSSession or SQLSession if you're
comfortable with DBs and SQL. squishdot should be coming out with a PTK
based version in the future (no idea when) but for now just install the
PTK edit the dtml drop a squishdot and voila instant site... 

Kapil


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

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




[Zope] ZOracle LOB Questions

2000-07-31 Thread Alexander Schad

Hello!

i have Oracle 8.1.6 ZOracleDA 2.2 installed with Zope 2.1.6 on a red hat
linux machine.

i have an oracle table with one column containing blobs. Now i have
the following problems:

1. How can i retrieve data from that table in zope or in python (syntax) ?

2. How can i insert data to that table ?
   i need the zope syntax something like:
insert into blob_table values ('dtml-var image') ???
   or the python syntax 

i have written a little script:

import DCOracle, sys, os, DCOracle.dbi

dbc = DCOracle.Connect('mozdb_dba/mozdb_dba')
cur = dbc.cursor()
fn = open('test_img.jpg','rb')
data = fn.read()
fn.close()
param = DCOracle.dbi.dbiRaw(data)
cur.execute('select blobcol from blobtable')
dat = cur.fetchone()
cur.close()
dbc.close()
print dat

when i try to execute it i get the following error:

Traceback (innermost last):
  File "blobtest.py", line 12, in ?
dat = cur.fetchone()
  File "DCOracle/ociCurs.py", line 339, in fetchone
self._error()
  File "DCOracle/ociCurs.py", line 109, in _error
raise error, (rc, oci_.OracleErrorMessage(self._c.lda, rc))
oci.error: (24813, 'ORA-24813: cannot send or receive an unsupported
LOB\012')

3. Is there a way to call a stored procedure or function that actually
   return values ? 
   i succeeded in retrieving one particular value out of a table but when
   i try a function like :
select * from some_table
   i fail...


4. Changes.txt:

  Z Oracle DA Releases

  2.2.0

Added a small feature that allows you to access LOBs in the Oracle 
database.  To do this, you must have your maximum number of
results set to '1'.  Otherwise, it won't work.

  i don't know what this is referring to. where should i make this change?

Ciao,
Alex


--
 Alexander G. Schad (Programmer)beehive elektronische medien gmbh
--
 mailto:[EMAIL PROTECTED]  mailto:[EMAIL PROTECTED]
http://www.beehive.de
fon: (+49 30) 84 78 20
fax: (+49 30) 84 78 22 99


___
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] Passing 'document_title' to 'standard_html_header' from a method?

2000-07-31 Thread Peter Bengtsson

http://www.zope.org/Members/michel/HowTos/DTMLMethodsandDocsHowTo
"They [methods] do not act like most other Zope objects because they are
methods of the folder that contains them. "

Very important reading. I've forgotten most of it, but what I remember is
important.

- Original Message -
From: Jonathan [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Monday, July 31, 2000 1:06 PM
Subject: [Zope] Passing 'document_title' to 'standard_html_header' from a
method?


 Hi all,

 I can't seem to get the 'document_title' from a method into a
 standard header (when using 'dtml-var document_title' in the header
 file the generated page uses the title of the header file itself.

 Using 'title_or_id' in the header file for a method uses the title or
 id from the folder it is in, not the title from the method itself.

 Any ideas? I didn't really find a solution in the archives; it does
 work with DTML Documents, but not with DTML Methods?

 Thnx,
 Jonathan

 ___
 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] dynamic -- statically pages

2000-07-31 Thread Matthias Füsting

Hi!

We have two server, a development-server and a
"official-server" where the website are stored.
On the development-server is ZOPE installed and
on the "official-server" not.
Is there any possibility, to produce the dynamic
website statically.
So that, I can transfer the website as normal
.html pages on the "official-server".


Thanks.


Matthias Füsting


   


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




[Zope] ANN: ZUBB (Zope Ultimate Bulletin Board) 0.5.0 Release

2000-07-31 Thread J. Atwood

I have uploaded the update to ZUBB. Both the changes and readme are linked
below. There are a few major presentation and feature changes but It still
does not work with Zope 2.2.  I will work on that when I have a chance (if
anyone would like to help that would be great).

http://www.zope.org/Members/BwanaZulia/ZUBB/

http://www.zope.org/Members/BwanaZulia/ZUBB/README

http://www.zope.org/Members/BwanaZulia/ZUBB/CHANGES

As always the sample / test / development board is

http://www.bwanazulia.com/kenya/discussions/test/


I have about 6 of these boards in production environments and things seem to
be pretty stable as I work to squash bugs. My major concern for now is to
see how many posts it can handle before I have to move to something like the
SQL based version (which is still in the basic planning stages and will be a
whole new game).

Suggestions, comments are welcome.

J



___
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] Info SendMail + doctype

2000-07-31 Thread Vincent



OK,

Following my 
previous Mail about HTML in the body of 
emails...

I tryed several of your answers, but it doesn't 
work.
My Oultook just displays evrything (included the 
br, body, etc...), eventhough I often receive mail with an HTML 
content (so my client is well configured).

If you have other solution, I'm really interested (I 
begin to be despaired).

Thnaks to all of you

Vincent



Re: [Zope] Limiting folder space

2000-07-31 Thread Kapil Thangavelu

Brendon Grunewald wrote:
 
 I want to use Zope to offer registered visitors to my site a little free
 webspace on the site. Since I use hosting service that restricts and charges
 me for space, I would like to restrict the size that their zope folders can
 consume.
 
 Hence:
 Is there any simple way of limiting the amount of space that a folder is
 allowed to consume including its subfolders? Alternatively, is there anyway
 of checking how much space a folder with subfolders consumes?

I set something up like this for myself at imeme.net (minus the file
limits) its basically just a simple zodb based remote file storage for
friends. basically to do it you can't let your visitors have access to
your manage screens.

example implementation.

create a folder called filesystem 
stick all your adding and managing methods in filesystem
add a size limit property to filesystem
for each user create a folder under filesystem.
that folder should probably have a property called current_size

basically you're going to have forms for people uploading a file. on the
page where you would do the manage_addFile stuff you're going to
implement the logic. check size of the file with _.len(file) on the form
submit page and add to current_size see if its above the limit. if it is
don't add tell the user why. if it isn't add it update the current_size
on the directory. voila.

here's some sample code which does the basics of getting file info 
without the management logic to get you started. it pretty prints a
table of file info.

table align="center" border="1"

trth colspan="4"dtml-var id Directory Contents/th/tr
trtdFile Name/tdtdType/tdtdSize/tdtdTimeStamp/td/tr

dtml-in "objectItems(['File', 'Image'])"
dtml-with sequence-item
dtml-call "REQUEST.set('DirectorySize', DirectorySize+size)"

tr
tda href="dtml-var sequence-key"dtml-var sequence-key/a/td
tddtml-var content_type/td
tddtml-var size/td
tddtml-var bobobase_modification_time/td
/tr
/dtml-with
/dtml-in

dtml-call "REQUEST.set('DirectorySize', DirectorySize/1000)"
trtd colspan="4"Total Directory Size: dtml-var
DirectorySizeK/td/tr
/table

 Regards,
 Brendon
 --
 70South: the No.1 source for Antarcticles.
 For the latest news and views on Antarctica visit : http://www.70south.com
 
 ___
 Zope maillist  -  [EMAIL PROTECTED]
 http://lists.zope.org/mailman/listinfo/zope
 **   No cross posts or HTML encoding!  **
 (Related lists -
  http://lists.zope.org/mailman/listinfo/zope-announce
  http://lists.zope.org/mailman/listinfo/zope-dev )

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




Re: [Zope] Starting Zope

2000-07-31 Thread Cary O'Brien

Bill wrote...

 
 Of course, it is entirely possible the user meant something other than s/he wrote. 
;) But
 that last one doesn't seem to indicate that.
 
 To put it succinctly:
 If you want Zope to bind to port 80 on *nix
 you have few options:
 
  o Change Zope to run SID ** Bad Idea
  o Modify the kernel so _anyone_
can bind to ports under 1024 ** even worse
  o START Zope as root, run it as a 
non-priviledged user, preferably one without 
a login.
 

You could also run zope behind Apache. The Apache bits that handle
root permissions seem pretty well accepted.  This doesn't really run
Zope listening to port 80, but if you go to port 80 on the machine
running Apache, you get to zope.

One advantage is that you can bounce Zope all day long without even
touching root.  Plus depending on your setup you can have Apache
running on a separate machine.  This can be better depending on the
situation (i.e.  development machines behind a firewall with private
addresses.

The downside is that you need to become aquainted with the wonderful
worlds of mod-rewrite and site-access[1].  Plus you may take a
performance hit.

-- cary

[1] Can someone explain (or point me to the reason) why the base tag
is necessary?  It sure can make life difficult!


 File permissions are irrelevenat when binding to ports under 1024 on Unix.
 
 
 
 
 --
 Do not meddle in the affairs of sysadmins, for they are easy to annoy,
 and have the root password.
 
 --__--__--
 


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




Re: [Zope] Starting Zope

2000-07-31 Thread Cary O'Brien

 
 Interesting argument. However, consider this: if you completely trust your
 'firewalled' box, then why not run the web server as root? One response,

Protection of the system from simple mistakes by trusted users?  Also
root can do a lot more, such as putting interfaces into promiscious
mode.  So the idea is to just lift the bind-to-low-ports check.

 in your case is the fact that you mention your trust on users(humans are
 the most easy to compromise, however that argument is a bit OT). However,
 do you trust all of your webserver code? Do you trust your cgi-bin
 scripts and applications? And by trust I not only mean harmful intent by
 the authors of software, but unintentional bugs which can be exploited,
 and will be given the privilege to bind to 1024 ports even when they run
 as a user with least privileges.
 

My revised thinking is that the patch should only lift the restriction
for just the necessary ports.  

Another idea is to do it with groups, say let group n be a "net-privileged" group.


-- cary

 Just my opinion.
 
 nitesh.
 
 
 On Sun, 30 Jul 2000, Cary O'Brien wrote:
 
   Cary O'Brien wrote:
   
Well...

If you are running on Linux you could simply edit the kernel code to
elimitate the check on being root to bind to low ports.  That's what
we did.
   
   Which is an even worse idea.
   
  
  Why?  On a sufficiently firewalled off box, where the few logins are
  completly trusted, what's the diff?  If you were worried about people
  cracking a user account and getting underneath telnet, than limit the
  lifting of the restriction to port 80.  If you are concerned that
  non-root users could launch attacks from low ports at other machines,
  assuming that only good guys can come from low ports is pretty naive.
  
  The whole business about not letting anyone but root bind to low ports
  makes sense for a public access machine where all the first year
  engineering students have an account, but for a dedicated application
  server it is kind of misdirected.  You ought to be running next to
  nothing but the application, and you had better trust everyone that
  you give a login to, and you out to have the thing locked
  down/firewalled well.  So the tiny bit of possible protection may not
  be worth the hassle/risks of writing your own suid-wrapper, or the
  complexity of having a redirect and messing with site-access so that
  the port numbers in the zope -- what it is that parameter -- base or
  whatever, comes out write.
  
  Just for fun - does NT have the same restriction?
  
  -- cary
  
  ___
  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] FSSession - don't call FSSession twice!

2000-07-31 Thread Pavlos Christoforou

On Tue, 1 Aug 2000 [EMAIL PROTECTED] wrote:

 
 Zope has encountered an error while publishing this resource.
 
 Error Type: OSError
 Error Value: [Errno 2] No such file or directory
 
 
 from the title) that I called FSSession twice. Line 193 appears to
 rename a .tmp file and I'd guess that by calling it twice my second
 attempt fails as the file has already been renamed. Obviously this
 
 Hope this is of some use
 
 Ian
 

Ian 

Thanks for the report and the excellent analysis. Unfortunately I did not
consider the case of calling FSSession twice. During the last couple of
days I had a few suggestions (Brian and Dieter) on improving FSSession so
a new version soon.

Thanks

Pavlos



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




[Zope] boolean property bug

2000-07-31 Thread Aleksander Salwa


Probably I found a bug in handling boolean properties in Zope 2.2.0.
I can only set them "on", and then can't turn "off". I can have default
value "off" (in ZClass definition), but after first switch to "true",
it can't be changed.
It only refers to handling properties via Zope's management screens.
API functions manage_changeProperty, manage_editProperty work fine, so
maybe it's an error in generated HTML forms, or in processing of these
forms.


ololo


___
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] Log Out

2000-07-31 Thread Aleksander Salwa



On Sun, 30 Jul 2000, Kapil Thangavelu wrote:

 Is there a way to log out of Zope without presenting a netscape dialog
 or killing the browser?
 
 i'd prefer that users have a link 'logout' that takes them back to the
 /root/index_html as anonymous
 

You can do it with one of the replacements for 'User Folder' - products
'GenericUserFolder' (aka 'GUF') or newer 'LoginManager', running in cookie
mode.
GUF has method 'logout', LoginManager - 'logoutForm', you can custumize it
to make right redirection.


ololo


___
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] Starting Zope

2000-07-31 Thread Costagliola Giovanni

Hello I'm the man who generate this jungly mailing

Simply, I use thesescripts:

---/usr/local/scripts/zstart-
#!/bin/bash

$ZOPE_BASE/start -u $ZOPE_USER -w 80 1/dev/null 21 
---
the previous is invoked by the next one:
---/etc/rc.d/init.d/zope---
#!/bin/bash
# zope
#
# chkconfig: 345 90 10
# description: Starts and stops the Zope instances
# processname: z2.py

# ZOPE ENVIRONMENT
export ZOPE_BASE=/Zope-2.2.0
export ZOPE_USER=zope

# Source function library.
.. /etc/rc.d/init.d/functions

# Get config.
.. /etc/sysconfig/network

# Check that networking is up.
[ ${NETWORKING} = "no" ]  exit 1

[ -x /usr/local/scripts/zstart ] || exit 1
[ -x /usr/local/scripts/zstop ] || exit 1

# See how we were called.
case "$1" in
start)
echo -n "Starting Zope instances: "
if /usr/local/scripts/zstart; then
success zope startup
else
failure zope startup
fi
echo
;;

stop)
echo -n "Stopping Zope instances: "
if /usr/local/scripts/zstop /etc/zope.conf; then
success zope shutdown
else
failure zope shutdown
fi
echo
;;

status)
status /Zope-2.2.0/bin/python 
exit $?
;;

restart)
$0 stop
sleep 2
$0 start
;;

*)
echo "Usage: $0 {start|stop|status|restart}"
exit 1
esac

exit 0

which invokes also this one to stop all.
---/usr/local/scripts/zstop---
#!/bin/bash

kill `/bin/cat "$ZOPE_BASE/var/Z2.pid"`
--

Many thanks to jec who's the author of the original suite of scripts that a
mangled, stupidely, to realize which ones I shown to you here.

Thanx to all.


-- 

  
  / *  * /
 / /
__oOOo__/__/_oOOo

(° Giovanni Costagliola  (jancos)
//\ email: [EMAIL PROTECTED]
V_/_voice:  +39 (0)347 1174139
_
  /  /
 /  /
(  (__
 \  \  / /#*** *  **
  \  \/ /*** *  *
   \   /###*** *  **
\ /##*** *  *
 \___/#*** *  **

___
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] Starting Zope

2000-07-31 Thread Otto Hammersmith

I've done it this way:

http://www.zope.org/Members/otto/portfw

It's also relatively easy to convince a hosting provider to add this, as
long as you have a dedicated IP address.

Perhaps I should have done a news item when I created this... seems a
lot of people have hacked around the issue is all sorts of odd ways. :)

-Otto.


Costagliola Giovanni wrote:
 
 Hello All,
 How can I to start Zope whit a different user than root and 
 cath the default HTTP port?
 
 If I try for example:
 su - -c './start -w 80 -u zope'
 
 I receive an error becouse root hasn't granted the need 
 privileges on /Zope/var/ directory.
 
 Thanx

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




[Zope] ANN: ZUBB 0.5.0 Release (Now works with Zope 2.2)

2000-07-31 Thread J. Atwood

After further testing I have a work around for 2.2 users. See the install
doc for more information.

I have uploaded the update to ZUBB. Both the changes and readme are linked
below. There are a few major presentation and feature changes.

http://www.zope.org/Members/BwanaZulia/ZUBB/

http://www.zope.org/Members/BwanaZulia/ZUBB/README

http://www.zope.org/Members/BwanaZulia/ZUBB/CHANGES

http://www.zope.org/Members/BwanaZulia/ZUBB/INSTALL

As always the sample / test / development board is

http://www.bwanazulia.com/kenya/discussions/test/


I have about 6 of these boards in production environments and things seem to
be pretty stable as I work to squash bugs. My major concern for now is to
see how many posts it can handle before I have to move to something like the
SQL based version (which is still in the basic planning stages and will be a
whole new game). So far I have been able to push it up to about 500 posts.
If you are using it and have pushed it farther let me know.

Suggestions, comments are welcome.

J



___
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] Limiting folder space

2000-07-31 Thread Otto Hammersmith

One thing I considered doing was using 2.2's mountable databases for
something like this.  Give each user their own database (possibly
without undo information) and use a cron job to check file sizes.  If
you have root on the box, you could create users id's for each user and
use quota on the filesystem to handle quota checking for you.

Of course, this wouldn't be horribly practical for a *lot* of users.

-Otto.

Kapil Thangavelu wrote:
 
 Brendon Grunewald wrote:
 
  I want to use Zope to offer registered visitors to my site a 
  little free webspace on the site. Since I use hosting service that 
  restricts and charges me for space, I would like to restrict the 
  size that their zope folders can consume.
 
  Hence:
  Is there any simple way of limiting the amount of space that a 
  folder is allowed to consume including its subfolders? 
  Alternatively, is there anyway of checking how much space a folder 
  with subfolders consumes?
[snip]

___
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] Zope and large files strategies?

2000-07-31 Thread Marcin Kasperski

Are there any limitations for placing large (say 15 MB) files inside
zope databases? What people running zope services and having to serve
such a files usually do - place them in zope or serve them with apache
(placing links inside zope web)?

--
 www.mk.maxi.pl  | As a slow-witted human being I have a very small head
Marcin.Kasperski | and I had better learn to live with it and to respect
  @softax.com.pl | my limitations, rather than to try to ignore them.   
@bigfoot.com | (Dijskstra)

___
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] Does 'favicon.ico' sound familiar to anyone?

2000-07-31 Thread Phil Harris

favicon.ico is the name of the icon file that MS IE uses to customize
favorite listings.

Your site must be being added to a few peoples favorites lists.

You have two basic options:

1. live with it
2. use it, stick a file called favicon.ico in the root of your site.

Do a search on the MS site for favicon.ico and you should find out exactly
what it is.

Phil
- Original Message -
From: "Marcin Kasperski" [EMAIL PROTECTED]
To: "Zope List Submission" [EMAIL PROTECTED]
Sent: Monday, July 31, 2000 3:57 PM
Subject: [Zope] Does 'favicon.ico' sound familiar to anyone?


 Recently i started using Zope and so far I have Apache running on port
 80 and shielding it (I employ ProxyPass and SiteAccess). Quickly after
 starting this configuration I notified a lot of

 File does not exist: [apache document root]/favicon.ico

 messages in Apache error log.

 Does it sounds familiar to anyone? I do not remember myself using file
 of such name anywhere (in fact I do not use any .ico file, I tried
 grepping my files in different ways but without success). Could it be
 some Zope or Apache specific file or should I re-try my grepping
 attempts?

 From the other side: what strategies would you use to search for such a
 problem source? I tried Zope Find. I downloaded my site via FTP and
 performed recursive grep. I mirrored my site with wget and performed
 recursive grep. No help, no bonus, no results.

 --
  www.mk.maxi.pl  | People resist change, regardless of what it is.
 Marcin.Kasperski | (Michael Reed)
   @softax.com.pl |
 @bigfoot.com |

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


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




[Zope] Zpatterns makefile problem

2000-07-31 Thread Owen Smith

Hello
Having a problem doing the Make file bit for ZPatterns

zope@phonix:/usr/local/dc/zope/lib/python/Products/ZPatterns$ make -f
Makefile.pre.in boot
rm -f *.o *~
rm -f *.a tags TAGS config.c Makefile.pre python sedscript
rm -f *.so *.sl so_locations
VERSION=`python -c "import sys; print sys.version[:3]"`; \
installdir=`python -c "import sys; print sys.prefix"`; \
exec_installdir=`python -c "import sys; print sys.exec_prefix"`; \
make -f ./Makefile.pre.in VPATH=. srcdir=. \
VERSION=$VERSION \
installdir=$installdir \
exec_installdir=$exec_installdir \
Makefile
make[1]: Entering directory
`/usr/local/dc/zope/lib/python/Products/ZPatterns'
make[1]: *** No rule to make target
`/usr/lib/python1.5/config/Makefile', needed by `sedscript'.  Stop.
make[1]: Leaving directory
`/usr/local/dc/zope/lib/python/Products/ZPatterns'
make: *** [boot] Error 2

Where am I going wrong?
I know /usr/lib/python1.5/config/ doesnt exist so I tried

zope@phonix:/usr/local/dc/zope/lib/python/Products/ZPatterns$  make -f
Makefile.pre.in Makefile VERSION=1.5 installdir=/usr/local/dc/zope
make: *** No rule to make target
`/usr/local/dc/zope/lib/python1.5/config/Makefile', needed by
`sedscript'.  Stop.

any help much appreciated

Owen
newbie:)





___
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] Does 'favicon.ico' sound familiar to anyone?

2000-07-31 Thread Owen Smith

hi
Its the file IE looks for when you bookmark a page
Owen

Marcin Kasperski wrote:

 Recently i started using Zope and so far I have Apache running on port
 80 and shielding it (I employ ProxyPass and SiteAccess). Quickly after
 starting this configuration I notified a lot of

 File does not exist: [apache document root]/favicon.ico

 messages in Apache error log.

 Does it sounds familiar to anyone? I do not remember myself using file
 of such name anywhere (in fact I do not use any .ico file, I tried
 grepping my files in different ways but without success). Could it be
 some Zope or Apache specific file or should I re-try my grepping
 attempts?

 From the other side: what strategies would you use to search for such a
 problem source? I tried Zope Find. I downloaded my site via FTP and
 performed recursive grep. I mirrored my site with wget and performed
 recursive grep. No help, no bonus, no results.

 --
  www.mk.maxi.pl  | People resist change, regardless of what it is.
 Marcin.Kasperski | (Michael Reed)
   @softax.com.pl |
 @bigfoot.com |

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


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




[Zope] Trouble installing on Solaris

2000-07-31 Thread Paul Smith

Hi

After playing with Zope on NT for a while, I decided it was time to try
it on Solaris. I have duly downloaded the file, followed the 
installation instructions for the precompiled binary version, but when 
I run ./install I get get the following error:

--
Compiling python modules
ld.so.1: /work3/cultivate-eu/Zope-2.1.6-solaris-2.6-sparc/bin/python: 
fatal: relocation error: file 
/work3/cultivate-eu/Zope-2.1.6-solaris-2.6-sparc/bin/python: symbol 
fseeko: referenced symbol not found
Killed


I can't find any references to this error anywhere. Can anyone help out
here?

Thanks

Paul

-
Paul Smith : [EMAIL PROTECTED]  
http://www.ilrt.bris.ac.uk/
Institute for Learning and Research Technology
University of Bristol,  BS8 1HH, UK   
Tel: 0117 928 7192 Fax: 0117 928 7112


___
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-dev] ZOracle LOB Questions

2000-07-31 Thread Chris McDonough

Please do not cross post to the zope and zope-dev mailing lists.

 -Original Message-
 From: Alexander Schad [mailto:[EMAIL PROTECTED]]
 Sent: Monday, July 31, 2000 11:38 AM
 To: Matthew T. Kromer
 Cc: [EMAIL PROTECTED]; [EMAIL PROTECTED]
 Subject: [Zope] Re: [Zope-dev] ZOracle LOB Questions
 
 
 
  Alex, Oracle 8i broke DCOracle's support for LOBs; DCOracle 
 primarily
  uses OCI 7 (Oracle 7) calls, and Oracle 8i enforces a 
 restriction that
  OCI 8 objects cannot be used in the context of an OCI 7 statement.
  
  You can use Oracle 8.0 for this, the restriction isn't 
 enforced until
  Oracle 8.1.
  
 
 Hello!
 thank you for your answer. but does that mean that i can only use LOBS
 with Oracle 8.0 ?
 i'm confused. i need to use LOBs. if i use oracle 8.1 can i 
 use LOBS and
 if yes which Databse adapter do i need?
 
 Ciao,
   Alex
 
 --
 
  Alexander G. Schad (Programmer)beehive elektronische medien gmbh
 --
 
  mailto:[EMAIL PROTECTED]  mailto:[EMAIL PROTECTED]
 http://www.beehive.de
 fon: (+49 30) 84 78 20
 fax: (+49 30) 84 78 22 99
 
 
 
 ___
 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] newbie question: user login

2000-07-31 Thread Peter Schneider-Kamp

I hope this is the right place to ask. Sorry, if it is not.

I can login into zope as superuser without any problems,
but I cannot login as the user "me" I created (with
password "meme"). I have given owner and manager rights
to "me". What else do I have to do?

Python raises an "Unauthorized" exception. Here's the traceback:

Traceback (innermost last):
File C:\Programme\WebSite\lib\python\ZPublisher\Publish.py, line 222, in 
publish_module
File C:\Programme\WebSite\lib\python\ZPublisher\Publish.py, line 187, in publish
File C:\Programme\WebSite\lib\python\ZPublisher\Publish.py, line 162, in publish
File C:\Programme\WebSite\lib\python\ZPublisher\BaseRequest.py, line 443, in 
traverse
File C:\Programme\WebSite\lib\python\ZPublisher\HTTPResponse.py, line 563, in 
unauthorized
Unauthorized: (see above)

help-appreciated,
Peter
--
Peter Schneider-Kamp  ++47-7388-7331
Herman Krags veg 51-11mailto:[EMAIL PROTECTED]
N-7050 Trondheim  http://schneider-kamp.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 )




Re: [Zope] FSSession - don't call FSSession twice!

2000-07-31 Thread icottee



You are very welcome.

By the way, just to confirm I don't have the problems I had before with the new
0.4 version of FSSession so I have no need now to try and call FSSession twice.

Thanks once again

Ian



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




Re: [Zope] Info SendMail + doctype

2000-07-31 Thread Aleksander Salwa


On Mon, 31 Jul 2000, Vincent wrote:
 Following my previous Mail about HTML in the body of emails...
 
 I tryed several of your answers, but it doesn't work.
 My Oultook just displays evrything (included the br, body, etc...),
 eventhough I often receive mail with an HTML content (so my client is well
 configured).
 
 If you have other solution, I'm really interested (I begin to be despaired).
 

Just take a look at any mail with HTML content, to understand, how such
messages are built. I mean reading raw headers and content, so Outlook
probably won't do it. You can do it on Unix account by simply reading your
incoming mail file (/var/mail/username or /var/spool/mail/username).

Try this DTML code (works fine with Pine 4.10):

dtml-sendmail smtphost=localhost
From: swienty@mikolaj
To: ololo@localhost
Subject: hejka5
MIME-Version: 1.0
dtml-mime type=text/html encode=quoted-printable

Hello !br
Here we have some bHTML/b tags.

/dtml-mime
/dtml-sendmail


ololo


___
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] getslice Error?

2000-07-31 Thread R. David Murray

On Mon, 31 Jul 2000, Marko MARKOVIC wrote:
 dtml-in "showNSDetails(nsref=old_nsref)" start=query_start
 dtml-call "REQUEST.set('sdate','%s.%s.%s' %
 (ns_entrydate[8:],ns_entrydate[5:7],ns_entrydate[:4]))"
 input type="text" name="new_nsentrydate" value="dtml-var sdate"
 size="10"
 /dtml-in
 
 ns_entrydate is a field of my query.

What is the type of ns_entrydate by the time it is used in this method?

 Error Type: AttributeError
 Error Value: __getslice__
[...]
   File D:\PROGRA~1\INTRAN~1\lib\python\DocumentTemplate\DT_Util.py, line
 335, in eval
 (Object: REQUEST.set('sdate','%s.%s.%s' %
 (ns_entrydate[8:],ns_entrydate[5:7],ns_entrydate[:4])))
 (Info: REQUEST)
   File string, line 0, in ?
   File D:\PROGRA~1\INTRAN~1\lib\python\DocumentTemplate\DT_Util.py, line
 174, in careful_getslice
   File D:\PROGRA~1\INTRAN~1\lib\python\DateTime\DateTime.py, line 922, in
 __getattr__
 AttributeError: (see above)
 
 what's wrong?  Do you know where i can found information about zope erorrs,
 i want to know what means all these errors that we get?

Well, unfortunately there is no one place you can go to to find
out about zope errors.  In fact, I'm not sure I've seen the zope
error machinery documented anywhere (and documenting it involves
discussing exactly how the dtml interpretation machinery works, which
would be a good document all by itself grin). 

I can tell you what is happening in this case, I think.  You will note
that in the part of the traceback I quoted above the last Object listed
is your line that takes slices out of ns_entrydate ([n:m] is called
a 'slice' in Python jargon).  The error received is a 'getslice' error.
So it looks like the zope machinery got an error when it tried to
take a slice of ns_entrydate.

Since Python is an OO language and operators can be defined for any
object (well, more or less), whatever type ns_entrydate is *could*
have defined a slice operator.  It appears, however, that whatever type
it is, it does *not* define one, since __getslice__ is being flagged
as a non-existent attribute, and that is the attribute that the
object's class would have to define, as a function, in order to
implement the slice operator.

From your code it appears you believe ns_entrydate is a string.  Is
it possible that it is instead some sort of datetime object?  If
so, then you'd have to call a function on it that returns the string
you want to parse, and call the slice operators on the returned
string.  But if it is a DateTime object, you can probably just call
functions to get exactly the strings you want without having
to slice anyway.

I hope this helps.

--RDM


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




[Zope] restarting zope.org

2000-07-31 Thread ethan mindlace fremen

back in a second
-- 
ethan mindlace fremen
Zopatista Community Liason
Abnegate I!

___
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 start developing in zope

2000-07-31 Thread Nico Grubert

Date: Thu, 27 Jul 2000 06:42:39 -0400 (EDT)
From: Firestar [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Subject: [Zope] How to start developing in zope

Hi, I have read through(and tried out) the tutorials and Guides at Zope.org,
and now eager to port my company's website over to Zope. (The website was
originally programmed in PHP)

In my original design, I used OOP mainly. I defined each section(e.g. News,
Events, Products) as a class by itself, inheriting from a "main" superclass.
Each class would contain their own set of attributes(such as font-color,
title) and methods(e.g. display news headline, or display events schedule).
Common attributes  method that are widely used are placed(shared) in the
"main" class(e.g. talking to MySQL database).

So, if there's any changes or updates, inheritance will propagate the
changes to the rest of the subclasses. (As usual, management will require
extra features such as personalised page, membership or web-based email to
be added in future. Hopefully, this kind of structure would make adding new
features a breeze.)

I believe Zope is based on a similar way (and much more powerful). I was
wondering how shld i start something like this in Zope - i read abt
ZClasses(where you can define your own Folders), Products(for defining yr
business logic) and DTML(for dynamic data display). Your opinions will be
much appreciated.

regards,
firestar


also, use properties which can be used as global variables...
by the way, zclasses are a very good way using object-oriented tasks

cheers,
nico

___
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] 2.2.0, LoginManager and ZPatterns

2000-07-31 Thread ethan mindlace fremen

Bill Anderson wrote:

  Where I can find this 'Membership' product ? (I've tried
  www.zope-treasures.com and 'Search' on www.zope.org).
 
 http://www.zope.org/Members/Bill/Products/Membership

well, it may be alpha, but I catalogued it anyway (so that people can
find it)

-- 
ethan mindlace fremen
Zopatista Community Liason
Abnegate I!

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




[Zope] How do I control iteration over XML elements?

2000-07-31 Thread Jean Jordaan

Hi all 

If I have (in an XML Document):

teams
 team
  nameName of team/name 
  descWhite papers, brochures, case studies./desc 
  member class="leader"Tracey/member
  memberEduan/member
  memberJacqui/member
 /team
/teams

Then:

dtml-in "teams[0].getElementsByTagName('team')"
 dtml-var "text_content('member')" br 
/dtml-in

gives me this:

TraceyEduanJacqui br

I'd like to format the output, putting br's between
all the names, for example. How do I do that?

Cheers,
-- 
jean

___
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] Old Zope

2000-07-31 Thread Luis Cortes



Does anybody know where I might still be able to 
download Zope 2.1.6? 

Thank ahead of time for any help,
Luis.



Re: [Zope] ZCatalog updating

2000-07-31 Thread R. David Murray

On Mon, 31 Jul 2000, Aaron Williamson wrote:
 I am convinced this is a stupid question that has been answered a
 hundred times already, but after scouring zope.org and the archives, I
 still don't know the answer, so...
 
 How can I automatically update my ZCatalog when items have been
 added/modified/changed?

Any objects that you want to be automatically updated in the Catalog
must have CatalogAware as one of their base classes.  And then you
have to add a reindex_object call to any forms that add or update
them.  (I fail to understand why one has to explictly call
reindex_object when properties change, even though I think someone
tried to explain it to me once).

I suppose you could do something similar with non-catalog aware
objects, where you made sure the add/update forms called the Catalog
to index them, but they wouldn't get deleted from the catalog automatically,
or reindexed automaticaly when moved.  If you are writing your own
management screens for those operations, though, you could make
it all work, I think.

You could also use ZSchedular to perioducally run the commands to
reindex your site, if instaneous reindexing is not a requirement.

--RDM


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




[Zope] HTML in Mail - It is working

2000-07-31 Thread Vincent

All good, it is working :



dtml-var standard_html_header

dtml-sendmail mailhost="MailHost"
From: [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Subject: hejka5
MIME-Version: 1.0
dtml-mime type=text/html encode=quoted-printable

Hello !br
Here we have some bHTML/b tags.brbr

/dtml-mime
/dtml-sendmail

It is working

!--#var standard_html_footer--


___
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] Full path var on Zope.org login link (Ethan!)?

2000-07-31 Thread Nick Garcia

ethan mindlace fremen wrote:
 
 "J. Atwood" wrote:
 
  What DTML-VAR do they use on Zope.org to populate the came_from variable for
  the 'login' link?
 
 http://www.zope.org/standard_html_header/view_source
 
 dtml-URL0;

Note that if you have any variables in your URL, this won't work.  You
have to do:

dtml-var URL0dtml-if QUERY_STRING?dtml-var QUERY_STRING/dtml-if

-- 
Nick Garcia | [EMAIL PROTECTED]
CodeIt Computing | http://codeit.com

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




Re: [Zope] Zope and large files strategies?

2000-07-31 Thread R. David Murray

On Mon, 31 Jul 2000, Marcin Kasperski wrote:
 Are there any limitations for placing large (say 15 MB) files inside
 zope databases? What people running zope services and having to serve
 such a files usually do - place them in zope or serve them with apache
 (placing links inside zope web)?

No limits other than those imposed by the OS file system (ie: Linux
is currently limited to 2GB Data.fs files).  If your large objects
are static, placing them in the ZODB is reasonable.  If they are dynamic,
then your Data.fs is going to grown *fast* (a new 15MB chuck for
every change to the object).  You might want to look at the LocalFS
product, which allows you to serve files out of the local file
system through Zope.  Depending on your specific application, that
is probably the better way to go.

--RDM


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




Re: [Zope] Zpatterns makefile problem

2000-07-31 Thread R. David Murray

On Mon, 31 Jul 2000, Owen Smith wrote:
 make[1]: *** No rule to make target
 `/usr/lib/python1.5/config/Makefile', needed by `sedscript'.  Stop.
 make[1]: Leaving directory
 `/usr/local/dc/zope/lib/python/Products/ZPatterns'
 make: *** [boot] Error 2
 
 Where am I going wrong?
 I know /usr/lib/python1.5/config/ doesnt exist so I tried

You need to install the source or development version of Python, to
get that missing file.

This is a Zope/ZPattern's FAQ grin.

--RDM


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




Re: [Zope] Old Zope

2000-07-31 Thread R. David Murray

On Mon, 31 Jul 2000, Luis Cortes wrote:
 Does anybody know where I might still be able to download Zope 2.1.6?   
 
 Thank ahead of time for any help,

If you look at the URL you would access to download 2.2.0, and replace
the version number with 2.1.6, I think you'll find you can still download
the old version.  At least, that was true when I downloaded 2.1.4 
after 2.1.6 came out...

--RDM


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




Re: [Zope] Does 'favicon.ico' sound familiar to anyone?

2000-07-31 Thread Marcin Kasperski

Phil Harris wrote:
 
 favicon.ico is the name of the icon file that MS IE uses to customize
 favorite listings.
 
 Your site must be being added to a few peoples favorites lists.
 (...)

Thank you very very much. I was doing desparate searches including zope
and apache sources grep, mirroring my site and grepping it etc 

My main conclusion: even if something is going strange on Linux,
Microsoft can be the reason ;-)


--
 www.mk.maxi.pl  | You have the right to an overall plan, to know what  
Marcin.Kasperski | can be accomplished, when, and at what cost. (Ken
  @softax.com.pl | Beck's First Customer Right) 
@bigfoot.com |

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




[Zope] Permissions question.

2000-07-31 Thread Jeff K. Hoffman

Hello,

I am having a permissions problem, and am hoping someone on the list will
see the error in my ways. I have a ZClass, called a FooManager, that
inherits from ObjectManager. It is responsible for creating (and managing)
Foo objects.

In the FooManager ZClass, I created a DTMLMethod called 'addFoo', and a
form called 'fooForm'. Following the "How to Create ZClass Instances
Programmatically" How-To, I modified my 'Foo_add' constructor to avoid
redirecting if the request contains a noRedir parameter.

In my 'addFoo' method, I have:

  dtml-with "manage_addProduct['FooProduct']"
dtml-call "Foo_add(_.None, _, noRedir=1)"
  /dtml-with

and I set it's Proxy role to 'Manager'.

My form, obviously, calls 'addFoo' with:

  form action="addFoo" method="..."

When I submit the form, I get:

  Unauthorized.

  You are not authorized to access FooObject.

'FooObject' is the name of my ZClass.

The traceback is:

  ...
  File /d1/zope/pcalc.ptec.com/lib/python/DocumentTemplate/DT_Util.py,
line 331, in eval
  (Object: FooObject.createInObjectManager(REQUEST['id'], REQUEST))
  (Info: FooObject)
File /d1/zope/pcalc.ptec.com/lib/python/OFS/DTMLMethod.py, line 189,
in validate
  (Object: addFoo)
File
/d1/zope/pcalc.ptec.com/lib/python/AccessControl/SecurityManager.py, line
139, in validate
File
/d1/zope/pcalc.ptec.com/lib/python/AccessControl/ZopeSecurityPolicy.py,
line 209, in validate
  Unauthorized: (see above)

I can fix the problem by going directly to my 'FooManager' instance and
giving Anonymous permission to 'Add a Foo Object'. However, I don't want
to do this on a general basis, nor do I want to have to manually adjust
each instance of 'FooManager'. I ONLY want my 'addFoo' method to be able
to do it. I thought the Proxy role in the ZClass's 'addFoo' method would
do the trick, but it did not.

Sorry if I haven't explained this well. As you can probably tell, ZClass
permissions are not exactly my strong suit in Zope.

Anyone have any ideas?

--Jeff

---
Jeff K. Hoffman   704.849.0731 x108
Chief Technology Officer  mailto:[EMAIL PROTECTED]
Going Virtual, L.L.C. http://www.goingv.com/


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




Re: [Zope] boolean property bug

2000-07-31 Thread Aleksander Salwa


On Mon, 31 Jul 2000, I wrote:
 
 Probably I found a bug in handling boolean properties in Zope 2.2.0.
 I can only set them "on", and then can't turn "off". I can have default
 value "off" (in ZClass definition), but after first switch to "true",
 it can't be changed.
 It only refers to handling properties via Zope's management screens.
 API functions manage_changeProperty, manage_editProperty work fine, so
 maybe it's an error in generated HTML forms, or in processing of these
 forms.

I've located this bug, I think.
It's in file 'lib/python/OFS/PropertySheets.py' in method
'manage_editProperties'. This method should change all properties, even
those not included in REQUEST. But there are handled only properties
included in REQUEST, so checkboxes that get turned off are ignored.


ololo


___
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] boolean property bug

2000-07-31 Thread Jonothan Farr

You should submit this to the collector, preferable with a patch! ;)
Otherwise it's likely to get lost in the chaos of the list.

http://classic.zope.org:8080/Collector

--jfarr

"Perl is worse than Python because people wanted it worse."
Larry Wall, 14 Oct 1998

- Original Message - 
From: Aleksander Salwa [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Monday, July 31, 2000 11:02 AM
Subject: Re: [Zope] boolean property bug


 
 On Mon, 31 Jul 2000, I wrote:
  
  Probably I found a bug in handling boolean properties in Zope 2.2.0.
  I can only set them "on", and then can't turn "off". I can have default
  value "off" (in ZClass definition), but after first switch to "true",
  it can't be changed.
  It only refers to handling properties via Zope's management screens.
  API functions manage_changeProperty, manage_editProperty work fine, so
  maybe it's an error in generated HTML forms, or in processing of these
  forms.
 
 I've located this bug, I think.
 It's in file 'lib/python/OFS/PropertySheets.py' in method
 'manage_editProperties'. This method should change all properties, even
 those not included in REQUEST. But there are handled only properties
 included in REQUEST, so checkboxes that get turned off are ignored.
 
 
 ololo
 
 
 ___
 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] 2.2 and ZLDAPConnection - editAttributes fails.

2000-07-31 Thread Corey Zimmet

Has anyone succeeded in getting ZLDAPConnections to work with Zope 2.2? 
When I try to perform an edit on an Entry object, the edit appears to
work. However, the transaction is never committed to the LDAP server.

Also,  when doing the examples from the Howto,  I have to explicitly
call the Entry object's get method rather than using the attribute
directly.  For example:

dtml-var uid will fail

dtml-var expr="get('uid')" is successful



Thanks,
Corey

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




[Zope] LoginManager / Membership: WTFM (Where's the...)

2000-07-31 Thread Danny William Adair

Hi all!

I've successfully installed current releases of ZPatterns, LoginManager and
"Membership". This Membership product comes up with some nice high level
methods / forms for the common procedures, but still doesn't help me with my
basic LoginManager question: How do I add users? I can see there's a
UserSource, and its property sheet "storage" says something about
"LoginUser"s (resp. "LoginMember"s), and that they are to be "stored
persistently", "directly in this object". Now how does this happen?

(I would like to put my users in a gadfly db, because they are 500, but not
ZODB because too many transactions will happen)

What am I supposed to do?

TY VM IA
Danny


___
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] newbie question: how do I adjust field width?

2000-07-31 Thread Joe Hewitt

Hi,

I'm making an input form.  When I try to change the form's input field
width, it automagically displays 30 char for each field.  Is there any way
to adjust the width?

Different question: where can I find some good examples of how to validate
input?

Thanks.


-- 
Joe Hewitt  email: [EMAIL PROTECTED]
Linux Coordinator
Washburn University Law School


___
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] getslice Error?

2000-07-31 Thread Dieter Maurer

Marko MARKOVIC writes:
  dtml-in "showNSDetails(nsref=old_nsref)" start=query_start
  dtml-call "REQUEST.set('sdate','%s.%s.%s' %
  (ns_entrydate[8:],ns_entrydate[5:7],ns_entrydate[:4]))"
  input type="text" name="new_nsentrydate" value="dtml-var sdate"
  size="10"
  /dtml-in
  
  ns_entrydate is a field of my query.
  ...
  Error Type: AttributeError
  Error Value: __getslice__
Obviously, "ns_entrydate" is an object and it has no "__getslice__".

The name suggests, that it is a date object, probably a "DateTime.DateTime"
object. Look at its source to determine what methods is has
(probably ".Day()" or ".day()" etc.).


Dieter

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




Re: [Zope] using sister folder methods ?

2000-07-31 Thread Dieter Maurer

Gijs Reulen writes:
  I have a root level folder with a DTML Document. From within this document I
  want to use a DTML Method that is located in a sister folder; another folder
  from the root.
  I tried the full path but that does not seem to work.
  What else ?
dtml-with other_folder
  dtml-var method
/dtml-with



Dieter

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




Re: [Zope] Python/Zope API

2000-07-31 Thread Kapil Thangavelu

"Alexandre A. Rodioukov" wrote:
 
 Kapil Thangavelu [EMAIL PROTECTED] writes:
 
   2. Are there ways to improve it? For example I would love to know how
  you can check if you can actually render an object. (For example
  you can not render Control_Panel).
 
  To render your python product objects in Zope like
  dtml-var yourObject
  you just define a method __str__
 
 I probably wasn't clear enough describing the issue :) I don't want to
 render Product, i want to make Zope to render some object from ZODB
 from python... i.e. to obtain rendered HTML code of some dtml
 document/method from external python method for filtering/doing some
 magic :) purposes.

Yikes, its __call__ that gets rendered not __str__. 

About your question... you still want to call __call__ :)
ala dtml_code_to_be_rendered() from within python. if you're accessing
any other zope elements that are not native to it(likely) you will need
to pass in the proper namespace and methods. Something along the lines 
dtcbr(client, namespace, request, response, *). you can safely leave
most of these blank. the keys ones in this context are probably
namespace and client. 

i played around with this and got rendering simple pages but nothing
with other zope objects.

take a look at the source for more inspiration.

Zope/lib/python/OFS/DTMLDocument.py

and HTML class.

Hope that helps 

Kapil

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




[Zope] server dies

2000-07-31 Thread Leichtman, David J


I was wondering if anyone else had experienced this problem: Ever since we
installed the ZPoPy database adapter, the server has been occasionally
crashing, and it gets worse and worse over time. Has anyone else experienced
this problem? We're running Zope through Apache, on a Solaris box, with
PostgreSQL. I'm really curious as to what could be causing this behavior. I
know that that adapter is still in development, but it seems like that would
be non-desirable behavior :) If there is some way that our setup is causing
this, any input would be appreciated. We are also still running the last
stable release of Zope (2.1.6, I think) with plans to upgrade next week.

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] ZUBB / ZDiscussions Users or Examples

2000-07-31 Thread J. Atwood

I have started a page (http://www.zope.org/Members/BwanaZulia/ZUBB/EXAMPLES)
to list sites that are building / using ZUBB or ZDiscussions. I would love
if you are using it to send me a link and you permission to add you to the
list.

I will also add you to a mailing list to let you know what the future looks
like it.

Thanks,
J


___
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] From a Folder to a Product

2000-07-31 Thread Cesar A. K. Grossmann

Hi!

I'm pretty satisfied with a group of reports I have done in Zope, and
want to put a copy of it in every customer's folder I have in the Zope
Server.

Are there a document/tutorial I can use as a guide or tutorial to do
this?

If someone wants to point some general guidelines, the folder contains
only the dtml docs/methods and SQL connection/SQL Queries used to do the
report, and the only thing that changes from one to another customer is
the SQL connection (every different customer have his own database).
Even the security properties are the same.

It can be draft as bellow:

/
+-- Report
   +- SQL Connection (PostgreSQL)
   +- SQL queries
   +- Reports based on the SQL queries
   +- Forms that are used to chose parameters and call the
Reports
   +- index_html, standart_error, standart_html_header/footer

TIA
-- 
César A. K. Grossmann [EMAIL PROTECTED] http://members.xoom.com/ckant/
http://www.halcyon.com/sciclub/cgi-pvt/instr/instr.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] PTK question ..

2000-07-31 Thread ethan mindlace fremen

Chris Withers wrote:
 
 Jean Jordaan wrote:
ZopePTK-0.7.1.tar.gz
 
 Erk :(
 
 Theres' a much newer snapshot available at:
 
 http://www.zope.org/Members/taz/PTK
 

This is catalogued now.

-- 
ethan mindlace fremen
Zopatista Community Liason
Abnegate I!

___
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] Passing 'document_title' to 'standard_html_header' from a method?

2000-07-31 Thread Dieter Maurer

  I can't seem to get the 'document_title' from a method into a
  standard header (when using 'dtml-var document_title' in the header
  file the generated page uses the title of the header file itself.
I just read in "zope-ptk" that a namespace has an (undocumented) "this"
attribute pointing to the DTML method/document that created the
namespace.

If this is true, you can use
  dtml-var "_.this.title"
to get what you want.


Dieter

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




Re: [Zope] Starting Zope

2000-07-31 Thread Cary O'Brien

 I've done it this way:
 
 http://www.zope.org/Members/otto/portfw
 
 It's also relatively easy to convince a hosting provider to add this, as
 long as you have a dedicated IP address.
 
 Perhaps I should have done a news item when I created this... seems a
 lot of people have hacked around the issue is all sorts of odd ways. :)
 
   -Otto.
 

How can this work?  Won't Zope put a "base href=http://server:8080" tag 
into the head of the document and mess things up?  Won't you need
site-access to work around this?

-- cary 

 
 Costagliola Giovanni wrote:
  
  Hello All,
  How can I to start Zope whit a different user than root and 
  cath the default HTTP port?
  
  If I try for example:
  su - -c './start -w 80 -u zope'
  
  I receive an error becouse root hasn't granted the need 
  privileges on /Zope/var/ directory.
  
  Thanx
 
 --__--__--
 


___
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 sister folder methods ?

2000-07-31 Thread Gijs Reulen

Thanks everybody for the tons of hints ! Works great now and I really start
to understand some things.

 Gijs Reulen wrote:
 
  Hi
 
  I have a root level folder with a DTML Document. From within
 this document I
  want to use a DTML Method that is located in a sister folder;
 another folder
  from the root.
  I tried the full path but that does not seem to work.
  What else ?


___
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 do I control iteration over XML elements?

2000-07-31 Thread Curtis Maloney

On Tue, 01 Aug 2000, Jean Jordaan wrote:
 Hi all

 If I have (in an XML Document):

 teams
  team
   nameName of team/name
   descWhite papers, brochures, case studies./desc
   member class="leader"Tracey/member
   memberEduan/member
   memberJacqui/member
  /team
 /teams

 Then:

 dtml-in "teams[0].getElementsByTagName('team')"
  dtml-var "text_content('member')" br
 /dtml-in

 gives me this:

 TraceyEduanJacqui br

 I'd like to format the output, putting br's between
 all the names, for example. How do I do that?

Simple enough.  You just need another dtml-in inside

replace:
dtml-var "text_content('member')"br
with:
dtml-in "objectValues('member')"
  dtml-var text_contentbr
/dtml-in

Works for me. (o8

 Cheers,

Have a better one,
Curtis.

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




Re: [Zope] From a Folder to a Product

2000-07-31 Thread R. David Murray

On Mon, 31 Jul 2000, Cesar A. K. Grossmann wrote:
 If someone wants to point some general guidelines, the folder contains
 only the dtml docs/methods and SQL connection/SQL Queries used to do the
 report, and the only thing that changes from one to another customer is
 the SQL connection (every different customer have his own database).
 Even the security properties are the same.

If you put everthing at the top level except the DB connection, and
put the appropriate one of those in each user's folder, I should
think they could access the report via acquisition.

--RDM


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




Re: [Zope] dtml-tree question

2000-07-31 Thread Jonothan Farr

 Jonothan Farr wrote:
  Is it because the document is at the top of the namespace stack instead of
the
  request object in the dtml document case, but not in the dtml method case?

 Hurm, thinking for the right words and I think(?) namespace is the right
 one.

 Anyway, DTML documents have one and DTML methods don't.

 Hence your tree tag is using the DTML documents namespace, which has
 nothing in it apart from the properties of the document.


I don't think that's entirely accurate. There's a lot more in the namespace of a
DTML document. I think you're right, though, in that it's a namespace issue. I
found that the results of the SQL query where not part of the namespace in the
DTML Document case, but they were in the DTML Method case. Here's how I got it
working:

dtml-var standard_html_header

dtml-tree
branches_expr="select_subprojects(project_id=REQUEST.get('project_id',0)
id=project_id

  dtml-call "REQUEST.set('project_id', project_id)"

  smalla
href="edit_project?project_id=dtml-project_id;"edit/a/smallnbsp;

  a href="view_project?project_id=dtml-project_id;"dtml-var
project_name/anbsp;/td

  td align=right valign=topdtml-var task_count

/dtml-tree

dtml-var standard_html_footer


In other words, I have to explicitly get the parameter from the result object
and pass it back into the sql query. What I'd like to know is why? Is this a bug
or a feature?

Thanks,
--jfarr



___
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] OT: Unix Permissions (was Re: [Zope] Starting Zope)

2000-07-31 Thread Bill Anderson

Cary O'Brien wrote:

[...]

  in your case is the fact that you mention your trust on users(humans are
  the most easy to compromise, however that argument is a bit OT). However,
  do you trust all of your webserver code? Do you trust your cgi-bin
  scripts and applications? And by trust I not only mean harmful intent by
  the authors of software, but unintentional bugs which can be exploited,
  and will be given the privilege to bind to 1024 ports even when they run
  as a user with least privileges.
 
 
 My revised thinking is that the patch should only lift the restriction
 for just the necessary ports.
 
 Another idea is to do it with groups, say let group n be a "net-privileged" group.


And yet another (and perhaps the better) is to look into the ACL support work being 
done
atthe kernel level. You can search the Linux Kernel mailing list archives for further
details. Note: this is not production work, last I heard.

Then again, neither is modifying the kenrel in non-standard ways ;^)


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

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




Re: [Zope] LoginManager / Membership: WTFM (Where's the...)

2000-07-31 Thread Bill Anderson

Danny William Adair wrote:
 
 Hi all!
 
 I've successfully installed current releases of ZPatterns, LoginManager and
 "Membership". This Membership product comes up with some nice high level
 methods / forms for the common procedures, but still doesn't help me with my
 basic LoginManager question: How do I add users? I can see there's a
 UserSource, and its property sheet "storage" says something about
 "LoginUser"s (resp. "LoginMember"s), and that they are to be "stored
 persistently", "directly in this object". Now how does this happen?
 
 (I would like to put my users in a gadfly db, because they are 500, but not
 ZODB because too many transactions will happen)
 
 What am I supposed to do?

First: Remember that all of the above are either _alpha_ or beta, AFAIK. IOW, not 
aimed at
production/still in development.

That will make the rest of it come into perspective, and help keep blood pressure form
spiraling ;^)

Next:
For membership, you add members by 'joining the site'. That is what Membership's intent
is, so of course it won't provide documentation on how to do the above.

To use your gadfly db for users would mean you need to write a Usersource fo rLogin
Manager that would do this. Membership, and the default LoginManager stuff does not 
(yet)
do this. For details on how to do this see
http://www.zope.org/Members/tsarna/LoginManager/Help/API.txt
and post questions on this to zope-dev, since that is the appropriate list.

Bill Anderson



 TY VM IA
 Danny
 
 ___
 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 )

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

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




Re: [Zope] newbie question: how do I adjust field width?

2000-07-31 Thread Bill Anderson

Joe Hewitt wrote:
 
 Hi,
 
 I'm making an input form.  When I try to change the form's input field
 width, it automagically displays 30 char for each field.  Is there any way
 to adjust the width?

Basic HTML Question. Please read HTML docs.

 
 Different question: where can I find some good examples of how to validate
 input?

Depends on how you want to do it, ie. server or client side. Consult the mailing list
archives for many references and examples. 
They can be reached from zope.org - Resources - Mailing Lists

Cheers,

Bill


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

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




Re: [Zope] 2.2.0, LoginManager and ZPatterns

2000-07-31 Thread Bill Anderson

ethan mindlace fremen wrote:
 
 Bill Anderson wrote:
 
   Where I can find this 'Membership' product ? (I've tried
   www.zope-treasures.com and 'Search' on www.zope.org).
 
  http://www.zope.org/Members/Bill/Products/Membership
 
 well, it may be alpha, but I catalogued it anyway (so that people can
 find it)


OK. I marked in RED letters that it is alpha. :)


Thinking aluod
Perhaps the Product Release page can put 'development' in red, so that devel products 
are
easier to spot?


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

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




Re: [Zope] ZUBB / ZDiscussions Users or Examples

2000-07-31 Thread Bill Anderson

"J. Atwood" wrote:
 
 I have started a page (http://www.zope.org/Members/BwanaZulia/ZUBB/EXAMPLES)
 to list sites that are building / using ZUBB or ZDiscussions. I would love
 if you are using it to send me a link and you permission to add you to the
 list.
 
 I will also add you to a mailing list to let you know what the future looks
 like it.
 


Umm, not using it quite yet, but ...

I have worked arounf the keyword error in ZUBB's regenerate methods method.

In the method, delete the 'this()' line.
Works for me, YMMV.

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

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




[Zope] The Western Web Newsletter

2000-07-31 Thread The Western Web

THE WESTERN WEB WEEKLY NEWS LETTER   Week of July 24, 2000
Serving Over 75000 Recipients

With your assistance "The Western Web" continues to improve and your input 
is helpful.Our goal is to make "The Western Web" THE one place stop for 
all your Horse, Livestock and Western Life Style needs.

If You have added your site to our search engine, please make sure
everything is correct.


If you haven't noticed we have upgraded the look and capabilities of The
Western Web search engine.  You can now type in your search word and 
find all related site links. Don't forget to add your Web Site to
our search engine too.

http://www.searchthewesternweb.com

This week you might take a look at our "Events Calendar" in our 
Classified Ad section. You can post your upcoming events in subcategories
such as: Events, Shows, Cuttings, Team Roping, Gymkhana, Clinics, Trail, 
Auctions, Rodeos, Reining, Barrel Racing, Team Penning and Performance
 Halter.  We also have a subcategory for "Other" to place any event
not categorized.  These ads are free and you can add pictures, video
and audio. A note to our subscribers who have posted ads, with you 
User Name and Password you can update your events.

http://www.westernwebclassified.com/cgi-bin/classifieds/classifieds.cgi




At last, an online service available with the horse lover in mind,
The Sale Barn.Com (www.thesalebarn.com).  The Sale Barn offers an 
online auction specifically for horse-related items, whether you
are buying or selling.  The Sale Barn auctions off 100s of items 
daily with many items in the Hot Items Listing starting at $1.00! 
Usually there are from 150 to 200 items starting at only $1.00. 
From saddles, bridles, bits, spurs and unique gift items. Register
now to qualify for our weekly drawing.  The current prize is a 
34 x 36 Wool Blend Show Blanket with wear leathers and silver 
conchos valued at $99.95!  This item is featured on our Home Page
at www.thesalebarn.com.  Registration is free on our secure site 
with no credit card necessary.  

The Sale Barn is amongst the top 10 visited horse sites on the 
Internet with over 10,000 hits a day.  A perfect opportunity to 
turn unneeded horse related items in to cash. The Sale Barn is 
the ebay of the horse world with categories directed to specific 
items such as saddles, headstalls, bits, spurs, ropes, gift items,
 horse trailers, etc.

http://www.thesalebarn.com

We appreciate you patronizing our sponsors.  You to can have your
web site on our front page along with Banks Power, Roo-hyde Saddlery, 
GMC, Bootbarn.com,Truckloads.net, Zig Zigler, Comforce, The Gaited 
Horse, Cowboy Tack, Painted Acres Ranch,The ShawnOshine,Tom Balding 
Bits  Spurs, Centenary of Federation and Stoxrus.com.  You can find
our reasonable rates at:

http://www.thewesternweb.com/Advertising/Advertising.htm

While at The Western Web site take a look at our message board:

http://www.westernmessageboard.com/cgi-bin/Ultimate.cgi


We can Design  Host your web site.  Check out our low domain name
registration prices at:

http://www.thewesternweb.com/Web_Design/Domain_Name_Registration.htm


For you convenience, there are links to these sites and more, from 
The Western Web Home Page.

http://www.thewesternweb.com/

If you receive this message in error or want us to remove you from
our newsletter e-mail list, please reply to this email address with 
the word "Remove" in the subject line.

Thank You,
http://www.thewesternweb.com

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




[Zope] Re: [Zope-dev] ZOracle LOB Questions

2000-07-31 Thread Matthew T. Kromer

Alexander Schad wrote:
 
 Hello!
 
 i have Oracle 8.1.6 ZOracleDA 2.2 installed with Zope 2.1.6 on a red hat
 linux machine.
 
 i have an oracle table with one column containing blobs. Now i have
 the following problems:
 
 1. How can i retrieve data from that table in zope or in python (syntax) ?
 
 2. How can i insert data to that table ?
i need the zope syntax something like:
 insert into blob_table values ('dtml-var image') ???
or the python syntax
 
 i have written a little script:
 
 import DCOracle, sys, os, DCOracle.dbi
 
 dbc = DCOracle.Connect('mozdb_dba/mozdb_dba')
 cur = dbc.cursor()
 fn = open('test_img.jpg','rb')
 data = fn.read()
 fn.close()
 param = DCOracle.dbi.dbiRaw(data)
 cur.execute('select blobcol from blobtable')
 dat = cur.fetchone()
 cur.close()
 dbc.close()
 print dat
 
 when i try to execute it i get the following error:
 
 Traceback (innermost last):
   File "blobtest.py", line 12, in ?
 dat = cur.fetchone()
   File "DCOracle/ociCurs.py", line 339, in fetchone
 self._error()
   File "DCOracle/ociCurs.py", line 109, in _error
 raise error, (rc, oci_.OracleErrorMessage(self._c.lda, rc))
 oci.error: (24813, 'ORA-24813: cannot send or receive an unsupported
 LOB\012')
 
 3. Is there a way to call a stored procedure or function that actually
return values ?
i succeeded in retrieving one particular value out of a table but when
i try a function like :
 select * from some_table
i fail...
 
 4. Changes.txt:
 
   Z Oracle DA Releases
 
   2.2.0
 
 Added a small feature that allows you to access LOBs in the Oracle
 database.  To do this, you must have your maximum number of
 results set to '1'.  Otherwise, it won't work.
 
   i don't know what this is referring to. where should i make this change?
 
 Ciao,
 Alex


Alex, Oracle 8i broke DCOracle's support for LOBs; DCOracle primarily
uses OCI 7 (Oracle 7) calls, and Oracle 8i enforces a restriction that
OCI 8 objects cannot be used in the context of an OCI 7 statement.

You can use Oracle 8.0 for this, the restriction isn't enforced until
Oracle 8.1.

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




[Zope] Re: [Zope-dev] ZOracle LOB Questions

2000-07-31 Thread Alexander Schad


 Alex, Oracle 8i broke DCOracle's support for LOBs; DCOracle primarily
 uses OCI 7 (Oracle 7) calls, and Oracle 8i enforces a restriction that
 OCI 8 objects cannot be used in the context of an OCI 7 statement.
 
 You can use Oracle 8.0 for this, the restriction isn't enforced until
 Oracle 8.1.
 

Hello!
thank you for your answer. but does that mean that i can only use LOBS
with Oracle 8.0 ?
i'm confused. i need to use LOBs. if i use oracle 8.1 can i use LOBS and
if yes which Databse adapter do i need?

Ciao,
Alex

--
 Alexander G. Schad (Programmer)beehive elektronische medien gmbh
--
 mailto:[EMAIL PROTECTED]  mailto:[EMAIL PROTECTED]
http://www.beehive.de
fon: (+49 30) 84 78 20
fax: (+49 30) 84 78 22 99



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