[Zope-dev] getPassword() from PythonScript
Hi, Zope 2-7-0 Linux Ispossible to get user's passwordby getPassword()method using Python Script?Any proxes don't work. the code below:user = context.getMemberById(context,'koperski')return user.getPassword()returns:The object is marked as private. Access to 'getPassword' of (MemberData at0x2353aea0) denied. Thanks in advanceKK ___ Zope-Dev maillist - Zope-Dev@zope.org http://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope )
[Zope-dev] i18n:translate - problem
Hi, I have the Zope 2.7.0 instaled under Linux OS. I want tohave my website in many languages in one Plone site. So Ihave installed "Placeless Translation Service". I've made2 .po files (cms_pl.po, cms_en.po)and compiled to .mo files (cms_pl.mo, cms_en.mo). I want to change website language version based on varriable value in ZPTand this is the problem (I think). When I do .po files with the same domain, e.g: "Domain: CMS\n"andthey have different "Language-Code:" headere.g:"Language-Code: pl\n" and "Language-Code: en\n" Zope chooses language based on web browser settings :(. When I'm setting "xml:lang" and"lang" attributtes it doesen't make effect. There is second way. I can do 2 .po files with different "Domain" and choose the one depends on variablebut I cant dynamicialyset "i18n:domain" attribute. How to manage that? Thanks in advance Krzysztof Kubacki ___ Zope-Dev maillist - [EMAIL PROTECTED] http://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope )
[Zope-dev] FlashMovie
Hallo I have added new product named "FlashMovie". I'm adding new FlashMovie's object in Zope's folder and next I want to get it from ZTP: table tal:define="img python:getattr(here, 'FlashMovieObject', None)". After it ZPT is beingredirected to ZPT named "flashmovie_view". I can not find ina ZMI the place where I can change it. I don't want to be redirected. Thanks in advance Krzychu ___ Zope-Dev maillist - [EMAIL PROTECTED] http://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope )
[Zope-dev] Zope+PIL+ image resizing
Hallo.I have Zope 2-7-0 on Linux platform and the following problem :)I'm sending an image through form on the pythonScript. I want script toresize image and save on the zope folder in 3 different size. OK, I useExternalMethod which uses PIL library to resize these images.External method:def xImageScale(img_file, maxx, maxy): from PIL import Image from cStringIO import StringIO im = Image.open(img_file) im.thumbnail((maxx, maxy), Image.ANTIALIAS) out_file_str = StringIO() im.save(out_file_str, im.format) out_file_str.seek(0) tmp=out_file_str.read() out_file_str.close() return tmppyrthonScript:cAnimation = form.get('cAnimation','') # image from the formif cAnimation: o.invokeFactory(id='cAnimationS.'+timeStamp, type_name='Image',file=context.xImageScale(cAnimation, 100, 100) o.invokeFactory(id='cAnimationM.'+timeStamp, type_name='Image',file=context.xImageScale(cAnimation, 200, 200) o.invokeFactory(id='cAnimationB.'+timeStamp, type_name='Image',file=context.xImageScale(cAnimation, 300,300)The result is "IOError, cannot identify image file". So, when I want toresize and save only one image it works properly.Thanks in advance for any helpKK ___ Zope-Dev maillist - [EMAIL PROTECTED] http://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope )
[Zope-dev] Fw: executing API functions and zope's security
Hi, I have a Xron productinstalled onto Zope 2-6-2. I would like to flush permanent and not referenced objects atgiven timefrom cache. To do it I have to use API function manage_minimize() (You can do it in ZMI as well: Control_panel-Database-Flush). I prepared a DTMLdocument with source as follows: dtml-var "Control_Panel.Database.manage_minimize()" When Xron tries to execute DTMLdocument above, it occurs as anonymous user andends failure becouse of zope's security restrictions. I tried to add permisions to DTMLdocument and Schedule objects in "Security" tabbut without success. Does anybody know which of permissions I have to mark to execute that operation? Krzychu K ___ Zope-Dev maillist - [EMAIL PROTECTED] http://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope )
[Zope-dev] portal_actions via listFilteredActionsFor
Hallo, I have the problem. Zope 2.7.0, Plone-2.0.3, Linux I list actions from portal_actions actions python: here.portal_actions.listFilteredActionsFor(here) I recive a list with actions. Depending on kind of logged user I recive that list in diffrent count.I mean that when I'm Manager the list is bigger than I'm SiteManager. I suppose that it depends on permissions.Where I can set it? I would like to recive the same list being Manager and SiteManage as well. Thanks in advanceKK ___ Zope-Dev maillist - [EMAIL PROTECTED] http://mail.zope.org/mailman/listinfo/zope-dev ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope )