[Zope] Re: Zope digest, Vol 1 #1213 - 22 msgs
yuzz
yuzz@emasonline.com
Mon, 26 Feb 2001 09:42:28 +0800
unsubscribe
zope-request@zope.org wrote:
>
> Send Zope mailing list submissions to
> zope@zope.org
>
> To subscribe or unsubscribe via the World Wide Web, visit
> http://lists.zope.org/mailman/listinfo/zope
> or, via email, send a message with subject or body 'help' to
> zope-request@zope.org
>
> You can reach the person managing the list at
> zope-admin@zope.org
>
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of Zope digest..."
>
> Today's Topics:
>
> 1. Re: LocalFS (J M Cerqueira Esteves)
> 2. Re: How do I personalize my error messages? (Chris Withers)
> 3. Adding Zope to Red Carpet (Donald Braman)
> 4. RPM, python scripts, threads (Philippe)
> 5. trouble adding roles on upgraded installation (Olaf Marc Zanger)
> 6. Re: Xron question--why won't method work (Chris Muldrow)
> 7. Re: RPM, python scripts, threads (Jens Vagelpohl)
> 8. Re: RPM, python scripts, threads (Philippe)
> 9. Re: How do I use variable variables in pythonscript? (Dieter Maurer)
> 10. Re: 2 more questions :-| (Dieter Maurer)
> 11. Re: sidebar sorting (Dieter Maurer)
> 12. Re: [ZCommerce] Frustrated with ALL zcommerce solutions! (Cees de Groot)
> 13. Owner, or not owner ? (Emmanuel Viennet)
> 14. FW: Reading properties from nested objects. (Michael Van Cleave)
> 15. Question about MySQL queries in Python Scripts (alankirk)
> 16. How to create a folder for a given user ? (Emmanuel Viennet)
> 17. Re: Question about MySQL queries in Python Scripts (Kevin Teague)
> 18. reinstall (Patrick)
> 19. Re: multipart pushing (Philippe J)
> 20. Re: Zope+Apache+ProxyPass (Ragnar Beer)
> 21. Re: multipart pushing (Ivan Cornell)
> 22. calling Zope objects from php (Guy Redwood)
>
> --__--__--
>
> Message: 1
> Date: Sat, 24 Feb 2001 17:51:21 +0000
> From: J M Cerqueira Esteves <jmce@artenumerica.com>
> To: zope@zope.org
> Subject: Re: [Zope] LocalFS
> Organization: Arte Numerica
>
> On Sat, Feb 24, 2001 at 03:55:17PM +0000, J M Cerqueira Esteves wrote:
> > ... however, it still states that in manage_upload(file) the
> > `file' parameter can be a string. It can't be a string, only a
> > FileUpload instance (see HTTPRequest.py), but it would be nice
> > if it could be.
>
> I ended up using the same method as for regular folders
> (with "foo.bar" a LocalFS):
>
> foo.bar.manage_addProduct['OFSP'].manage_addFile (file_name,
> file = content)
>
> where `content' is a string with the intended file content.
>
> --
> jmce: +351 919838775 ~ http://artenumerica.com/ ~ http://artenumerica.org/
>
> --__--__--
>
> Message: 2
> Date: Sat, 24 Feb 2001 17:55:26 +0000
> From: Chris Withers <chrisw@nipltd.com>
> Organization: New Information Paradigms
> To: Andy McKay <andym@ActiveState.com>
> CC: "Smith, RyanX" <ryanx.smith@intel.com>, zope@zope.org
> Subject: Re: [Zope] How do I personalize my error messages?
>
> Andy McKay wrote:
> >
> > Bizarre as it seems, not all error messages go to standard_error_message.
> > Some obvious ones such as 404 for example.
>
> Huh?!
>
> Our standard_error_message's catch 404s
>
> They don't catch Auth errors though, which is something that neesd fixing.
> What also neesd fixing is the way the traceback is plonked on the end of any
> generated HTML (yes, after the </HTML>), generating badly formed HTML and giving
> out information about your site you may not want to.
>
> Both of these I'd love to fix, and may well do if I can just squeeze 26 hours
> into a day ;-)
>
> cheers,
>
> Chris
>
> --__--__--
>
> Message: 3
> Reply-To: <donald.braman@yale.edu>
> From: "Donald Braman" <donald.braman@yale.edu>
> To: <zope@zope.org>
> Date: Sat, 24 Feb 2001 13:19:46 -0500
> Subject: [Zope] Adding Zope to Red Carpet
>
> Is the Zope team working on adding Zope to Red Carpet? If I could add a Zope
> channel with the various Zopey things I need, I'd be tickled pink. Just
> checking. -Don
>
> --__--__--
>
> Message: 4
> Date: Sat, 24 Feb 2001 12:22:00 -0600 (CST)
> From: Philippe <pouliot@fuelrod.ph.utexas.edu>
> To: zope@zope.org
> Subject: [Zope] RPM, python scripts, threads
>
> I've got zope 2.3.0 running with python 1.5.2 on RedHat 6.2.
>
> I'm afraid the threads for python have not been compiled in.
> Is there an RPM that does it? (My system administrator will not let
> me install anything without an RPM. How difficult is it to write an
> RPM?)
>
> thanks a lot,
>
> -Philippe
>
> (Below, I'm including the page source of an error message trying
> the Guest_Book example of the Zope Book, which btw is an excellent
> book :-)
>
> <!--
> Traceback (innermost last):
> File /usr/lib/python1.5/site-packages/ZPublisher/Publish.py, line
> 222, in publish_module
> File /usr/lib/python1.5/site-packages/ZPublisher/Publish.py, line
> 187, in publish
> File /usr/share/zope/lib/python/Zope/__init__.py, line 221, in
> zpublisher_exception_hook
> (Object: Traversable)
> File /usr/lib/python1.5/site-packages/ZPublisher/Publish.py, line
> 171, in publish
> File /usr/lib/python1.5/site-packages/ZPublisher/mapply.py, line
> 160, in mapply
> (Object: addEntryAction)
> File /usr/lib/python1.5/site-packages/ZPublisher/Publish.py, line
> 112, in call_object
> (Object: addEntryAction)
> File /usr/share/zope/lib/python/OFS/DTMLMethod.py, line 189, in
> __call__
> (Object: addEntryAction)
> File /usr/lib/python1.5/site-packages/DocumentTemplate/DT_String.py,
> line 538, in __call__
> (Object: addEntryAction)
> File /usr/lib/python1.5/site-packages/DocumentTemplate/DT_Util.py,
> line 334, in eval
> (Object: addEntry(guest_name, comments))
> (Info: guest_name)
> File <string>, line 0, in ?
> File /usr/share/zope/lib/python/Shared/DC/Scripts/Bindings.py, line
> 324, in __call__
> (Object: addEntry)
> File /usr/share/zope/lib/python/Shared/DC/Scripts/Bindings.py, line
> 353, in _bindAndExec
> (Object: addEntry)
> File
> /usr/share/zope/lib/python/Products/PythonScripts/PythonScript.py,
> line 330, in _exec
> (Object: addEntry)
> (Info: ({'script': <PythonScript instance at 86c6b40>, 'context':
> <Folder instance at 87b3998>, 'container': <Folder instance at
> 87b3998>, 'traverse_subpath': []}, ('Anonymous', 'this is a try'), {},
> None))
> TypeError: (see above)
>
> --__--__--
>
> Message: 5
> From: Olaf Marc Zanger <olaf.zanger@soli-con.com>
> Reply-To: olaf.zanger@soli-con.com
> Organization: soli-con Engineering Zanger
> To: Zope <zope@zope.org>
> Date: Sat, 24 Feb 2001 19:42:03 +0100
> Subject: [Zope] trouble adding roles on upgraded installation
>
> hi there,
>
> i upgraded a generic zope 2.2.4 installation on suse 7.0 to 2.3.0.
>
> now i can't add roles anymore
>
> thanks for help
>
> olaf
>
> the errormessage:
> ------------------------------------------
>
> Remarks for Errortracking
>
> (Please pass this information to your support)
>
> Error Type: TypeError
> Error Value: not enough arguments; expected 3, got 2
> Error URL:
> http://sino:8090/ipOperate/manage_defined_roles
> Error Message:
> Error Absolute URL: http://sino:8090/ipOperate
>
> The URL may be incorrect.
> The parameters passed to this resource may be
> incorrect.
> A resource that this resource relies on may be
> encountering an error.
>
>
>
>
> (c)2001 soli-con
> Engineering Zanger,
> Lorrainestrasse 23, 3013
> Bern, Switzerland,
> Fon: +41-31-332 9782, Mob: +41-76-572 9872,
> Email: info@soli-con.com
>
> Traceback (innermost last):
> File /home/soli-con/ipOffice/lib/python/ZPublisher/Publish.py, line 222, in
> publish_module
> File /home/soli-con/ipOffice/lib/python/ZPublisher/Publish.py, line 187, in
> publish
> File /home/soli-con/ipOffice/lib/python/Zope/__init__.py, line 221, in
> zpublisher_exception_hook
> (Object: Traversable)
> File /home/soli-con/ipOffice/lib/python/ZPublisher/Publish.py, line 171, in
> publish
> File /home/soli-con/ipOffice/lib/python/ZPublisher/mapply.py, line 160, in
> mapply
> (Object: manage_defined_roles)
> File /home/soli-con/ipOffice/lib/python/ZPublisher/Publish.py, line 112, in
> call_object
> (Object: manage_defined_roles)
> File /home/soli-con/ipOffice/lib/python/Products/zzLocale/patcher.py, line
> 160, in manage_defined_roles
> (Object: Traversable)
> File /home/soli-con/ipOffice/lib/python/AccessControl/Role.py, line 506, in
> _addRole
> (Object: Traversable)
> TypeError: (see above)
> --
> soli-con Engineering Zanger, Dipl.-Ing. (FH) Olaf Marc Zanger
> Lorrainestrasse 23, 3013 Bern / Switzerland
> fon:+41-31-332 9782, mob:+41-76-572 9782
> mailto:olaf.zanger@soli-con.com, http://www.soli-con.com
>
> --__--__--
>
> Message: 6
> Date: Sat, 24 Feb 2001 14:02:34 -0500
> Subject: Re: [Zope] Xron question--why won't method work
> From: Chris Muldrow <muldrow@mac.com>
> To: ender <kthangavelu@earthlink.net>,
> <zope@zope.org>
>
> Yep, I've set a manager proxy on Xron so it could create a news item. Still
> no luck.
>
> on 2/22/01 5:18 AM, ender at kthangavelu@earthlink.net wrote:
>
> > sounds like a permission problem, does the user that xron executes as have
> > permission to add a news item? xron uses zclient to request the method.
> >
> > cheers
> >
> > kapil
> >
> >
> >>
> >>
> >> And here's the external method that it's calling:
> >>
> >> def addFLSNews(self, newid, data, REQUEST=None):
> >> """ """
> >> # Get the actual destination object, using the this()
> >> # method, to be sure we get it in the right context..
> >> self=self.this()
> >>
> >> # Create the new instance
> >> newob=self.Control_Panel.Products.FLSNewsStory.FLSNewsStory(data)
> >> newob._setId(newid)
> >>
> >> self._setObject(newid, newob)
> >>
> >> It's hitting a problem at the self.setObject line. This method works when I
> >> run it as a regular DTML Document, but it hits an "Attribute Error on
> >> self.setObject when I run it as an Xron. I'm using the trigger tab, but
> >> I've also tried letting it run as scheduled--neither works.
> >>
>
> --__--__--
>
> Message: 7
> Date: Sat, 24 Feb 2001 15:49:21 -0500
> Subject: Re: [Zope] RPM, python scripts, threads
> From: Jens Vagelpohl <jens@digicool.com>
> To: Philippe <pouliot@fuelrod.ph.utexas.edu>, <zope@zope.org>
>
> the standard python-1.5.2 RPM that ships with RH 6.2 has thread support
> built in.
>
> jens
>
> on 2/24/01 13:22, Philippe at pouliot@fuelrod.ph.utexas.edu wrote:
>
> > I've got zope 2.3.0 running with python 1.5.2 on RedHat 6.2.
> >
> > I'm afraid the threads for python have not been compiled in.
> > Is there an RPM that does it? (My system administrator will not let
> > me install anything without an RPM. How difficult is it to write an
> > RPM?)
> >
> > thanks a lot,
> >
> > -Philippe
> >
> > (Below, I'm including the page source of an error message trying
> > the Guest_Book example of the Zope Book, which btw is an excellent
> > book :-)
> >
> > <!--
> > Traceback (innermost last):
> > File /usr/lib/python1.5/site-packages/ZPublisher/Publish.py, line
> > 222, in publish_module
> > File /usr/lib/python1.5/site-packages/ZPublisher/Publish.py, line
> > 187, in publish
> > File /usr/share/zope/lib/python/Zope/__init__.py, line 221, in
> > zpublisher_exception_hook
> > (Object: Traversable)
> > File /usr/lib/python1.5/site-packages/ZPublisher/Publish.py, line
> > 171, in publish
> > File /usr/lib/python1.5/site-packages/ZPublisher/mapply.py, line
> > 160, in mapply
> > (Object: addEntryAction)
> > File /usr/lib/python1.5/site-packages/ZPublisher/Publish.py, line
> > 112, in call_object
> > (Object: addEntryAction)
> > File /usr/share/zope/lib/python/OFS/DTMLMethod.py, line 189, in
> > __call__
> > (Object: addEntryAction)
> > File /usr/lib/python1.5/site-packages/DocumentTemplate/DT_String.py,
> > line 538, in __call__
> > (Object: addEntryAction)
> > File /usr/lib/python1.5/site-packages/DocumentTemplate/DT_Util.py,
> > line 334, in eval
> > (Object: addEntry(guest_name, comments))
> > (Info: guest_name)
> > File <string>, line 0, in ?
> > File /usr/share/zope/lib/python/Shared/DC/Scripts/Bindings.py, line
> > 324, in __call__
> > (Object: addEntry)
> > File /usr/share/zope/lib/python/Shared/DC/Scripts/Bindings.py, line
> > 353, in _bindAndExec
> > (Object: addEntry)
> > File
> > /usr/share/zope/lib/python/Products/PythonScripts/PythonScript.py,
> > line 330, in _exec
> > (Object: addEntry)
> > (Info: ({'script': <PythonScript instance at 86c6b40>, 'context':
> > <Folder instance at 87b3998>, 'container': <Folder instance at
> > 87b3998>, 'traverse_subpath': []}, ('Anonymous', 'this is a try'), {},
> > None))
> > TypeError: (see above)
> >
>
> --__--__--
>
> Message: 8
> Date: Sat, 24 Feb 2001 15:47:54 -0600 (CST)
> From: Philippe <pouliot@fuelrod.ph.utexas.edu>
> To: zope@zope.org
> Subject: [Zope] Re: RPM, python scripts, threads
>
> OK, my mistake was silly: I didn't pass the parameters to the python
> script. Now this example in Ch.5 of the Zope Book is working. But I still
> get the same error as Linda with the example in Ch.3: "Error Value: not
> enough arguments; expected 4, got 3".
>
> -Philippe
>
> On Sat, 24 Feb 2001, Philippe wrote:
>
> > I've got zope 2.3.0 running with python 1.5.2 on RedHat 6.2.
> >
> > I'm afraid the threads for python have not been compiled in.
> > Is there an RPM that does it? (My system administrator will not let
> > me install anything without an RPM. How difficult is it to write an
> > RPM?)
> >
> > thanks a lot,
> >
> > -Philippe
>
> --__--__--
>
> Message: 9
> From: Dieter Maurer <dieter@handshake.de>
> Date: Sat, 24 Feb 2001 23:06:17 +0100 (CET)
> To: Jason.Jones@awl.com
> Cc: zope@zope.org
> Subject: Re: [Zope] How do I use variable variables in pythonscript?
>
> Jason.Jones@awl.com writes:
> > I would like to do something like the following:
> >
> > <dtml-var "_[getform('do')]">
> When you have bound the namespace (--> bindings), then
> you can use "_[getform('do')]".
>
> Dieter
>
> --__--__--
>
> Message: 10
> From: Dieter Maurer <dieter@handshake.de>
> Date: Sat, 24 Feb 2001 23:04:56 +0100 (CET)
> To: Klaus Herrmann <klaus.herrmann@goelz.com>
> Cc: zope@zope.org
> Subject: Re: [Zope] 2 more questions :-|
>
> Klaus Herrmann writes:
> > <dtml-in "PARENTS[0].objectValues(['DTML Document','Folder'])" sort="id,
> > meta_type" >
> > BUT: i want to sort meta_type in reverse order (to have the folders on top),
> > and the id in "normal" order.
> > is that possible? how?
> "in"'s sort does not support this.
>
> You can do it in an external method using Python's "sort" method
> or extend "in"'s sorting capabilities.
>
> > (2) i have a dtml-tree, but i don't want to list the contents of the current
> > folder but of PARENTS[1].
> <dtml-tree "PARENTS[1]">
>
> Dieter
>
> --__--__--
>
> Message: 11
> From: Dieter Maurer <dieter@handshake.de>
> Date: Sat, 24 Feb 2001 23:08:59 +0100 (CET)
> To: Oliver Vecernik <vecernik@aon.at>
> Cc: "zope@zope.org" <zope@zope.org>
> Subject: Re: [Zope] sidebar sorting
>
> Oliver Vecernik writes:
> > I have following DTML method for a sidebar construction:
> > <ul>
> > <dtml-in expr="objectValues('Folder')" sort="_.[sort]">
> > <li><a class="sidemenu" href="&dtml-absolute_url;"><dtml-var
> > title_or_id></a><br></li>
> > </dtml-in>
> > </ul>
> "sort" interprets its value as a list attribute names separated
> by ','.
> In your example, it would use the attribute with the literal name "_.[sort]".
> But you want "_.[sort]" evaluated and use the result as sort
> specification. You can do that with "sort_expr" (rather than "sort").
>
> Dieter
>
> --__--__--
>
> Message: 12
> To: James Sintz <jsintz@ohiohistory.org>
> cc: zcommerce@codeit.com, "'zope@zope.org'" <zope@zope.org>
> From: cg@cdegroot.com (Cees de Groot)
> Reply-To: cg@cdegroot.com
> Date: Sat, 24 Feb 2001 23:51:15 +0100
> Subject: [Zope] Re: [ZCommerce] Frustrated with ALL zcommerce solutions!
>
> jsintz@ohiohistory.org said:
> > If anyone has created a simple store/shopping card that allows for
> > secure processing of orders (and maybe a Wampum hook) and possible
> > product images and would be willing to share the code, I would be
> > willing to try and rustle up some cash (not sure how much).
>
> If you're not a programmer, you shouldn't be messing around with Zope and
> e-commerce because it's not ready for prime-time and it won't be for a while.
> I suggest you install something more ready-to-go and proven, like Akopia
> (www.akopia.com).
> --
> Cees de Groot http://www.cdegroot.com <cg@cdegroot.com>
> GnuPG 1024D/E0989E8B 0016 F679 F38D 5946 4ECD 1986 F303 937F E098 9E8B
>
> --__--__--
>
> Message: 13
> Date: Sat, 24 Feb 2001 23:58:44 +0100
> From: Emmanuel Viennet <emmanuel.viennet.@lipn.univ-paris13.fr>
> To: zope@zope.org
> Subject: [Zope] Owner, or not owner ?
>
> I'm playing for the first time with Zope 2.3.0
> (I have an old site running happily since 18 months Zope 2.1.4:-)
>
> I try to setup a site with several authors, each owning its
> folder. The users are defined at the root (/acl_users).
>
> The folder "Team/foo" belongs to the user "foo".
> In this folder, I grant the permission "View management screens"
> to the role "Owner".
> Problem: user "foo" can't manage its folder.
> If I grant this permission to "Anonymous", it works...
>
> In the ZopeBook, we read "Owner: This role is assigned automatically
> to users in the context of objects they create.".
>
> What did I missed ?
>
> Thanks for your help or for pointers to relevant documentation.
>
> --
> Emmanuel Viennet
> Dpt GTR - IUT de Villetaneuse - Universite Paris-Nord
> 93430 Villetaneuse - France
> http://www-gtr.iutv.univ-paris13.fr/
>
> --__--__--
>
> Message: 14
> From: "Michael Van Cleave" <m@slack.net>
> To: <zope@zope.org>
> Date: Sun, 25 Feb 2001 02:46:31 -0500
> Subject: [Zope] FW: Reading properties from nested objects.
>
> I have am using something similar to the Yihaw Pointer in the Yihaw
> class to reference objects elsewhere in the folder structure of my
> site. The pointer has a property on it that stores the absolute url
> of an object that it is referencing. I cannot figure out how to use
> the stored absolute url to read elements off the remote object.
>
> >From an arbitrary dtml-method, how can I render a variable property
> on a remote object.
>
> For example in the following site structure
>
> /root
> /x
> index_html
> pointer_method (has a property "url" which is "/y/objectZ")
> /y
> objectZ
>
> The index_html file calls pointer_method and reads the
> property "url", creating a link to the object that "url" points to
> (objectZ). This works great. However, I would like to read
> properties off that remote item (say the title for example) and
> render them in the index_html file.
>
> I have tried this, but it generates a key error:
>
> <dtml-call "REQUEST.set('location', _.string.replace(pointer, '/', '.'))">
> <dtml-var location.id>
>
> If I hard code it as such:
>
> <dtml-with y>
> <dtml-with objectZ>
> <dtml-var title>
> </dtml-with>
> </dtml-with>
>
> I can read the title, but I cannot figure out how to convert the
> absolute url into a with statement or a var.
>
> Any help is greatly appreciated.
>
> -m
>
> --__--__--
>
> Message: 15
> From: "alankirk" <alankirk@genie.co.uk>
> To: <zope@zope.org>
> Date: Sun, 25 Feb 2001 10:42:39 -0000
> Subject: [Zope] Question about MySQL queries in Python Scripts
>
> This is a multi-part message in MIME format.
>
> ------=_NextPart_000_0010_01C09F17.ACC17E40
> Content-Type: text/plain;
> charset="iso-8859-1"
> Content-Transfer-Encoding: quoted-printable
>
> Hi,
>
> I've written a few python scripts that use some sql queries to a mysql =
> database. I have a script that can access the database and get =
> information ok but i have a sript that tries to insert data to the =
> database, but when i try to run it, i get a zope error that mentions =
> Unauthorized: query.
>
> Does anyone know why this is and how to get round it?
>
> Cheers=20
>
> Alan
>
> ------=_NextPart_000_0010_01C09F17.ACC17E40
> Content-Type: text/html;
> charset="iso-8859-1"
> Content-Transfer-Encoding: quoted-printable
>
> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
> <HTML><HEAD>
> <DEFANGED_META http-equiv=3DContent-Type content=3D"text/html; =
> charset=3Diso-8859-1">
> <DEFANGED_META content=3D"MSHTML 5.50.4611.1300" name=3DGENERATOR>
> <DEFANGED_STYLE></STYLE>
> </HEAD>
> <BODY bgColor=3D#ffffff>
> <DIV><FONT face=3DArial size=3D2>Hi,</FONT></DIV>
> <DIV><FONT face=3DArial size=3D2></FONT> </DIV>
> <DIV><FONT face=3DArial size=3D2>I've written a few python scripts that =
> use some sql=20
> queries to a mysql database. I have a script that can access the =
> database and=20
> get information ok but i have a sript that tries to insert data to the =
> database,=20
> but when i try to run it, i get a zope error that mentions Unauthorized: =
>
> query.</FONT></DIV>
> <DIV><FONT face=3DArial size=3D2></FONT> </DIV>
> <DIV><FONT face=3DArial size=3D2>Does anyone know why this is and how to =
> get round=20
> it?</FONT></DIV>
> <DIV><FONT face=3DArial size=3D2></FONT> </DIV>
> <DIV><FONT face=3DArial size=3D2>Cheers </FONT></DIV>
> <DIV><FONT face=3DArial size=3D2></FONT> </DIV>
> <DIV><FONT face=3DArial size=3D2>Alan</FONT></DIV></BODY></HTML>
>
> ------=_NextPart_000_0010_01C09F17.ACC17E40--
>
> --__--__--
>
> Message: 16
> Date: Sun, 25 Feb 2001 11:39:57 +0100
> From: Emmanuel Viennet <emmanuel.viennet.@lipn.univ-paris13.fr>
> To: zope@zope.org
> Subject: [Zope] How to create a folder for a given user ?
>
> Apologies for these simples questions...
>
> What is the correct procedure to follow in order
> to create a Folder owned by a given user
> (ie I want to create the equivalent of a unix account
> with a home directory).
>
> By the way: in the (near) future I'd like
> to automate this task (using XML-RPC or some other
> scripting technique).
> Where can I find a documentation of the API
> (I didn't find informations about user creation,
> ownership change etc in the Zope Book nor in
> the QuickStart help).
>
> Thanks,
> Emmanuel
>
> --
> Emmanuel Viennet
> Dpt GTR - IUT de Villetaneuse - Universite Paris-Nord
> 93430 Villetaneuse - France
> http://www-gtr.iutv.univ-paris13.fr/
>
> --__--__--
>
> Message: 17
> Date: Sun, 25 Feb 2001 03:25:36 -0800
> Subject: Re: [Zope] Question about MySQL queries in Python Scripts
> From: Kevin Teague <kevin@bud.ca>
> To: alankirk <alankirk@genie.co.uk>,
> Zope <zope@zope.org>
>
> > I've written a few python scripts that use some sql queries to a mysql
> > database. I have a script that can access the database and get information ok
> > but i have a sript that tries to insert data to the database, but when i try
> > to run it, i get a zope error that mentions Unauthorized: query.
> >
> > Does anyone know why this is and how to get round it?
>
> Hmm, some more information about your script or the traceback in your error
> message would be helpful. If I wanted to create SQL queries in a python
> script, I would create a MySQL DB connection in Zope, then a simple Z SQL
> Method that took a single arguement as a string, like this:
>
> Params: query:string
> Method: <dtml-var query>
>
> Then I'd only allow Manager access to this Z SQL Method and then give the
> python script a proxy role so that it could access the Z SQL Method. Then
> call that Z SQL Method from the Python Script perhaps like this:
>
> container['zsqlmethodid'](query='SELECT * FROM your_table')
>
> Kevin Teague
> http://www.bud.ca
>
> --__--__--
>
> Message: 18
> To: zope@zope.org
> Date: Sun, 25 Feb 2001 14:12:07 +0300 (EAT)
> From: Patrick <patrick@eahd.or.ug>
> Subject: [Zope] reinstall
>
> Hi,
> I am running FreeBsd and I did a make install to upgrade my zope from 2.2 to
> 2.3. My validation is done by apache using the <directory> directive of the cgi-
> bin directory but it does not seem to work. I keep getting the error below. Can
> anyone give me any ideas on how to set it up again probably from scratch?
>
> Thanx.
>
> Zope Error
> Zope has encountered an error while publishing this resource.
>
> Error Type: IndexError
> Error Value: list index out of range
>
> --------------------------------------------------------------------------------
>
> Troubleshooting Suggestions
>
> The URL may be incorrect.
> The parameters passed to this resource may be incorrect.
> A resource that this resource relies on may be encountering an error.
> For more detailed information about the error, please refer to the HTML source
> for this page.
>
> If the error persists please contact the site maintainer. Thank you for your
> patience.
>
>
> Traceback (innermost last):
> File /usr/local/www/Zope/lib/python/ZPublisher/Publish.py, line 222, in
> publish_module
> File /usr/local/www/Zope/lib/python/ZPublisher/Publish.py, line 187, in
> publish
> File /usr/local/www/Zope/lib/python/Zope/__init__.py, line 221, in
> zpublisher_exception_hook
> (Object: ApplicationDefaultPermissions)
> File /usr/local/www/Zope/lib/python/ZPublisher/Publish.py, line 162, in
> publish
> File /usr/local/www/Zope/lib/python/ZPublisher/BaseRequest.py, line 440, in
> traverse
> File /usr/local/www/Zope/lib/python/AccessControl/User.py, line 505, in
> validate
> (Object: RoleManager)
> IndexError: (see above)
>
> --__--__--
>
> Message: 19
> From: "Philippe J" <philippejadin2@swing.be>
> To: <zope@zope.org>
> Subject: Re: [Zope] multipart pushing
> Date: Sun, 25 Feb 2001 14:13:14 +0100
>
> The idea come from the book "web application development with php4.0" by
> Ratschiller and Gerken. The web site is http://www.phpwizard.net/
>
> The idea was to build an irc client.
>
> You may ask them wether it's a foolproof solution or not.
>
> Beside the fact that some browsers may have a timeout setting, I do not see
> why it wouldn't work.
>
> Philippe
>
> > Cool idea! I never heard about it. Do you know whether that works
> > with all kinds of browsers (especially older versions)?
> >
> > Ragnar Beer
>
> --__--__--
>
> Message: 20
> Date: Sun, 25 Feb 2001 14:42:34 +0100
> To: zope@zope.org
> From: Ragnar Beer <rbeer@uni-goettingen.de>
> Subject: Re: [Zope] Zope+Apache+ProxyPass
>
> >I'm confused by a note in your caching howto about managing Zope using
> >an SSL connection:
> >
> > Apache+ZServer+SSL From the author of this How-To I also got a very
> > good tip for what to do if you want to manage your website via https
> > to avoid sending your unencrypted password over the net: Reverse the
> > setup he describes, i.e. instead of creating a folder "ssl" and
> > making the base of the site root "https://..." create a folder
> > "http" and make the base of the site root "http://..."
> >
> >Isn't the username/password still sent in clear text (mime-encoded) as
> >soon as you attempt to manage anything in the /http folder because of
> >the unencrytped connection (http://...) specified by the siteroot?
> >
> >-kevin
>
> Of course you need to use the https protocol! The advantage of the
> reversed setup is that if you configure it that way then the
> "natural" way to access the site can be https and http is the special
> case and not the other way round.
>
> Ragnar
>
> --__--__--
>
> Message: 21
> Date: Sun, 25 Feb 2001 14:51:35 +0000
> From: Ivan Cornell <ivan.cornell@framestore.co.uk>
> Organization: FrameStore
> To: Philippe J <philippejadin2@swing.be>
> CC: zope@zope.org, Ragnar Beer <rbeer@uni-goettingen.de>
> Subject: Re: [Zope] multipart pushing
>
> Philippe J wrote:
>
> > > I'd like to implement a chat function using the multipart content type and
> > I
> > > wonder if that is possible with Zope. My idea is to write a python script
> > that
> > > pushes the content of a database until e.g. the stop button is pressed in
> > the
> > > Browser. But how would the script know that it's supposed to stop? And
> > would
> > > such a longtime connection completely occupy one Zope thread so that I'd
> > have
> > > to increase the number of threads?
> >
> > Not sure about the threads, but a quite comonly used trick is to generate
> > the html page as the chat evolves, without writting the ending </html> tag.
> > The browser will think the connexion is slow, and will continue to display
> > the page. You should not, however, use complex layout (tables), as the
> > browser sometimes need a complete page to display those.
> >
>
> I fairly sure this won't work, as I believe Zope renders a complete page before
> sending it the client browser. This is unlike something like PHP which sends
> the page as it interprets it. This confused me when I first switched as I was
> trained to always send headers before any output, however in zope you can
> manipulate the REQUEST object right up to the end of your page.
>
> Ivan
>
> --__--__--
>
> Message: 22
> Date: Sun, 25 Feb 2001 15:58:21 +0000
> From: Guy Redwood <webmaster@siberianhuskyclub.com>
> To: <zope@zope.org>
> Subject: [Zope] calling Zope objects from php
>
> Hi
>
> Just wanted to share this with you.
>
> We use the phorum bulletin board in php and Zope for the rest of our site
> (truly smitten with Zope). I've just realised how to add the menus and
> banner adverts (built in Zope) into the headers and footers of the bulletin
> board php scripts. I originally thought of embedding php into Zope... but
> it's easier to call zope from php!
>
> Use the 'include' function to call Zope dtml methods through http.
>
> Really easy....
>
> <?php
> include ("http://www.siberianhuskyclub.com/banners/show_banner");
> ?>
>
> This just places the code for our banner adverts in the right place.
>
> Guy
>
> http://www.siberianhuskyclub.com
>
> --__--__--
>
> _______________________________________________
> Zope maillist - Zope@zope.org
>
> End of Zope Digest