[Zope3-Users] Using z3c.jsonrpc with an existing skin

2008-07-22 Thread Dominique Lederer
Hi i want to switch from jsonserver to z3c.jsonrpc, but i cant get it working. i have a skin defined: py: from zope.publisher.interfaces.browser import IDefaultBrowserLayer class IPreview(IDefaultBrowserLayer): zcml: interface interface=.IPreview

[Zope3-Users] searching for easy buildout.cfg to start with

2008-07-20 Thread Dominique Lederer
hi i am searching for a simple buildout.cfg, which installs the latest zope 3.4 rc1 with a filestorage and one instance. i would like to switch an existing z3 applikation to buildout, for a comfortable deployment. this app i would check out via infrae.subversion. build i cant find any

[Zope3-Users] Re: catalog of objects' states (hurry.workflow)

2007-08-04 Thread Dominique Lederer
Alek Kowalczyk schrieb: Hello again, I have a rather big tree of MyObjects. MyObjects are adaptable to hurry.workflow's IWorklowState. Now I'd like to create a catalog to index all MyObjects by their current states. How to do that? An option might be(?) to add to MyObject property like that:

[Zope3-Users] Using RAMCache

2007-07-03 Thread Dominique Lederer
hi i would like to cache the results of method in a view, and thougt, that RAMCache could be of use here. After spending a lot of time searching for some documentation or examples, i came to this: from zope.app.cache.ram import RAMCache cache = RAMCache() query = cache.query('test',key={'x':1})

[Zope3-Users] problems deleting objects in containers

2007-06-06 Thread Dominique Lederer
hi i want to delete objects in my container, for that i do for xx in container.keys(): logging.info(xx) del container[xx] but only every second obj is deleted, the loop touches objects in this order: 1,3,5,7,. if i remove the del statement from the upper example, the loop works as

Re: [Zope3-Users] problems deleting objects in containers

2007-06-06 Thread Dominique Lederer
Dominique Lederer wrote: hi i want to delete objects in my container, for that i do for xx in container.keys(): logging.info(xx) del container[xx] but only every second obj is deleted, the loop touches objects in this order: 1,3,5,7,. if i remove the del statement from

Re: [Zope3-Users] Blog naming proposals

2007-05-28 Thread Dominique Lederer
Florian Lindner wrote: Hello, some people might have noticed I am developing a Blog package for Zope3. Since it slowly becomes functional (an older version is working at http://xgm.de) I want to release it (under an free and open source licence). One thing still missing is a good name. A

[Zope3-Users] formlib handling of adapters

2007-05-05 Thread Dominique Lederer
hi i just tried to adapt an object with two similar interfaces: class IBaseAdapter(Interface): content = Text(title=uContent, required=False) class IHomeAdapter(IBaseAdapter): class ILinksAdapter(IBaseAdapter): after that, i created two formlib editform views and registered

[Zope3-Users] getting random results out of a catalogs field index

2007-05-05 Thread Dominique Lederer
hi i would like to retrieve a number of *random* entries out of a catalogs field index. i tried it with first getting the catalogindex-length an then accessing a randomized list-index, but this is very slow, because of the large number of entries in the index. do you know any better solution?

Re: [Zope3-Users] getting random results out of a catalogs field index

2007-05-05 Thread Dominique Lederer
Christian Theune wrote: Am Samstag, den 05.05.2007, 17:42 +0200 schrieb Dominique Lederer: hi i would like to retrieve a number of *random* entries out of a catalogs field index. i tried it with first getting the catalogindex-length an then accessing a randomized list-index

[Zope3-Users] handling a mass of images/files

2007-04-11 Thread Dominique Lederer
hi i´m just thinking about, how to handle a lot of images within my zope3 application. what would you recommend to do: a) save all images into the zodb b) use z3c.extfile i looked a bit into z3c.extfile´s documentation, an found, that i returns file-data from the filesystem, which are stored

[Zope3-Users] problems with catalog: indexing field from an objects adapter

2007-03-28 Thread Dominique Lederer
hi, I want to index a field from an object, which works perfectly via Catalog and Field Index. But if my callable field returns a value, which is returned from an adapter of the object, things get complicated for me: i create my object an add it to a container (not via zmi). i do the

Re: [Zope3-Users] view vs page confused

2007-03-27 Thread Dominique Lederer
Marius Gedminas schrieb: On Wed, Jan 24, 2007 at 08:31:52PM +0100, Dominique Lederer wrote: can someone explain me please when to use browser:view and when browser:page? As far as I understand, the intended use of browser:page is to define views that are accessible to browsers by using URLs

[Zope3-Users] i18n question

2007-03-14 Thread Dominique Lederer
i have a viewlet where this method resides: def title(self): from zope.i18nmessageid import MessageFactory _ = MessageFactory('my_domain') return _(self.__name__) the pagetemplates for the viewlet renders the title like p tal:content=view/title / the templates renders

Re: [Zope3-Users] i18n question

2007-03-14 Thread Dominique Lederer
Dominique Lederer schrieb: i have a viewlet where this method resides: def title(self): from zope.i18nmessageid import MessageFactory _ = MessageFactory('my_domain') return _(self.__name__) the pagetemplates for the viewlet renders the title like p tal:content=view

Re: [Zope3-Users] Error when calling addform

2007-02-18 Thread Dominique Lederer
Florian Lindner schrieb: Am Dienstag, 13. Februar 2007 12:04 schrieb Stephan Richter: On Monday 12 February 2007 15:56, David Johnson wrote: Many people have offered approaches. I find the simplest and cleanest approach for declaring interfaces is as follows: The cleanest way, in my

Re: [Zope3-Users] Standard Macros

2007-02-12 Thread Dominique Lederer
Hassan Alirezaei schrieb: Hi Marius thanks for the response. you are right that was a typo, views/standard_macros is totaly wrong. however, the problem still remains the same: even html metal:use-macro=context/@@standard_macros/page /html or html

Re: [Zope3-Users] Permission problem on adapter

2007-02-11 Thread Dominique Lederer
FB schrieb: Hi, On Sun, Feb 11, 2007 at 01:16:51AM +0100, Dominique Lederer wrote: hi i created a trusted adapter on a content object. then i created a formlib edit page for the ZMI, to be able to edit the new attributes on the adapted content object. the adapters interface is correctly

Re: [Zope3-Users] css/page template ?

2007-02-10 Thread Dominique Lederer
tyson schrieb: I am having trouble getting my style sheet to load in my page template. I added my .css file within the local package directory. How can I point to this file on the filesystem. I tried using a layer with a resource in my configure file, but that didn't work. Any help would

[Zope3-Users] Permission problem on adapter

2007-02-10 Thread Dominique Lederer
hi i created a trusted adapter on a content object. then i created a formlib edit page for the ZMI, to be able to edit the new attributes on the adapted content object. the adapters interface is correctly rendered to the form. if i try to edit, an unauthorized error is shown, which i also get,

[Zope3-Users] select field with Choice widget and formlib

2007-02-07 Thread Dominique Lederer
hi i render a form with formlib which contains a selectbox: form_fields = Fields( Choice(__name__='selectbox', required=False, values=[value1,value2,value3]), ) the rendered output always includes a extra option which contains this message-id

Re: [Zope3-Users] interview for my diploma thesis about Zope 3 in education

2007-01-24 Thread Dominique Lederer
David Johnson schrieb: * Do you think Zope (3) can be used at school or university level to support topics in computer science education? What topics would you recommend? Why? I definitely think Zope 3 can be used to support education. We plan on developing a number of applications in this

[Zope3-Users] view vs page confused

2007-01-24 Thread Dominique Lederer
hi! can someone explain me please when to use browser:view and when browser:page? and when would i inherit a View Class from zope.publisher.BrowserView and when from zope.publisher.BrowserPage, and why do i need them when i could just inherit from object without any errors? and what means the

[Zope3-Users] interview for my diploma thesis about Zope 3 in education

2007-01-22 Thread Dominique Lederer
Hello list! currently i am writing my diploma thesis at the University of Applied Science in Austria, Vienna. The topic is about the usage of Python and Zope (3) in education. There are a lot of papers concerning Python and education, but i found not much about Zope there. So this seems an

Re: [Zope3-Users] zope.testbrowser and vhost

2007-01-04 Thread Dominique Lederer
Gary Poster schrieb: On Jan 2, 2007, at 2:29 PM, Benji York wrote: Dominique Lederer wrote: i see there is a VirtualHostingBrowser class in zope.testbrowser.testing, but i dont have a clue on how to use this. Use VirtualHostTestBrowserSuite instead of unittest.TestSuite and the tests

[Zope3-Users] zope.testbrowser and vhost

2007-01-02 Thread Dominique Lederer
hi! i would like to use zope.testbrowser to test my vhosted site http://localhost:8080/++skin++myskin/mysite/++vh++http:my.example.com:80/++/ i see there is a VirtualHostingBrowser class in zope.testbrowser.testing, but i dont have a clue on how to use this. any help would be nice. thanks Dom

Re: [Zope3-Users] ForbiddenAttribute when adding to a folder

2006-11-24 Thread Dominique Lederer
Darryl Cousins schrieb: Hi Tim, On Sat, 2006-10-21 at 12:18 +0200, Tim Terlegård wrote: Is there a way to add content without having @@+ in the URL? For instance I'd like the url for adding events to be /addEvent. I get security problems when not having @@+ in the URL. I have this view:

Re: [Zope3-Users] no object attributes on IObjectAddedEvent / IObjectCreatedEvent?

2006-11-24 Thread Dominique Lederer
Florian Lindner schrieb: Am Freitag, 24. November 2006 16:55 schrieb Dominique Lederer: hi just tried to retrive some objects attributes (from an object i created vie ZMI) on the IObjectCreatedEvent. Got just emty attributes, so i tried it with IObjectAddedEvent, but my attributes are still

[Zope3-Users] changing behaviour of PAU SessionCredentialsPlugin

2006-11-16 Thread Dominique Lederer
hi i would like to change the behaviour of extractCredentials in the SessionCredentialsPlugin of the PAU. i´m still fighting a bit with the framework: would i use an adapter for this, or subclassing? or would i use the override directive somehow? thank you Dominique

Re: [Zope3-Users] changing behaviour of PAU SessionCredentialsPlugin

2006-11-16 Thread Dominique Lederer
Dominique Lederer schrieb: hi i would like to change the behaviour of extractCredentials in the SessionCredentialsPlugin of the PAU. i´m still fighting a bit with the framework: would i use an adapter for this, or subclassing? or would i use the override directive somehow? hi, made

[Zope3-Users] security problem setting Annotations with an adapter

2006-11-10 Thread Dominique Lederer
hi! i just added an adapter to my content-class, which gets and sets some Annotations. at the moment i do this in the adapters init to be able to set them: def __init__(self, context): from zope.security.proxy import removeSecurityProxy self.context =

[Zope3-Users] how to catalog principal annotations?

2006-11-02 Thread Dominique Lederer
hi I have users residing in an external database.I store user data with principal annotations. Now i want to create a view where users with a special annotation are listed. Is it possible to catalog principal annotations and how? Or do i have to create a special Person Class where all principal

[Zope3-Users] how to set predefined values on newly created content object

2006-10-25 Thread Dominique Lederer
hello i would like to set predefined metadata, when i create a new content object. from my point of knowledge i could to this with a custom factory or by listening to events. is there any other possibility to to this, mabe somehow in the interface? thanks cheers Dom