plone

How do you scale an animated GIF image in PIL and preserve the animation

痞子三分冷 提交于 2019-12-23 09:11:18
问题 I'm wondering if it's possible to scale an animated GIF image using PIL. In particular Plone’s archetypes ImageField currently loses the animation from images scaled using its scale method: def scale(self, data, w, h, default_format = 'PNG'): """ scale image (with material from ImageTag_Hotfix)""" #make sure we have valid int's size = int(w), int(h) original_file=StringIO(data) image = PIL.Image.open(original_file) # consider image mode when scaling # source images can be mode '1','L,','P',

cant download wkhtmltopdf for sendaspdf add on in Plone

与世无争的帅哥 提交于 2019-12-23 04:24:18
问题 When I try to install wkhtmltopdf through build out by using bin/buildout after modifying the buildout.cfg file as suggested by Dan, I get the following error: Updating wkhtmltopdf_executable. mv: cannot stat `wkhtmltopdf-amd64': No such file or directory chmod: cannot access `wkhtmltopdf': No such file or directory Installing wkhtmltopdf. wkhtmltopdf: Unable to extract the package /home/user/Plone/buildout-cache/downloads/94af137dfe94508c7d7bfab08214118c. Unknown format. While: Installing

Plone - attach multiple files

柔情痞子 提交于 2019-12-23 03:00:09
问题 I do not have much experience with plone, I searched on other forums an answer to my problem but without success. I saw that with plone you can enter text via "Add" event, news, page, file .... is to add a file that I have encountered a problem, that I can not add more files. I need to add multiple files with a single description, there is a way to do it? Thank you ! 回答1: Supposing you are looking for a possibility to batch-upload files into a folder, there are several add-ons for help out

An error when trying to change Image workflow

╄→尐↘猪︶ㄣ 提交于 2019-12-23 02:53:12
问题 In short, when I go into Site Setup -> Types and try and change the workflow for Images from "No Workflow" to any other workflow, I get the following error: Traceback (innermost last): Module ZPublisher.Publish, line 126, in publish Module ZPublisher.mapply, line 77, in mapply Module ZPublisher.Publish, line 46, in call_object Module plone.app.controlpanel.types, line 165, in __call__ Module zope.event, line 31, in notify Module zope.component.event, line 24, in dispatch Module zope.component

An error when trying to change Image workflow

梦想的初衷 提交于 2019-12-23 02:53:07
问题 In short, when I go into Site Setup -> Types and try and change the workflow for Images from "No Workflow" to any other workflow, I get the following error: Traceback (innermost last): Module ZPublisher.Publish, line 126, in publish Module ZPublisher.mapply, line 77, in mapply Module ZPublisher.Publish, line 46, in call_object Module plone.app.controlpanel.types, line 165, in __call__ Module zope.event, line 31, in notify Module zope.component.event, line 24, in dispatch Module zope.component

Plone 4.2 - how can I change the logo in a diazo theme?

风流意气都作罢 提交于 2019-12-22 15:26:22
问题 I have just installed a theme in Plone called beyondskins.responsive. Now I want to change the logo so that it uses the logo for my site and not the default Plone logo. I've spent an hour googling this problem and I have not found a solution. One of the places I looked was here: http://pypi.python.org/pypi/plone.app.theming#modifying-the-theme This site tells me "You can modify a theme by clicking Modify theme underneath a theme in the Themes tab of the Theming control panel." However, I don

Plone 4.2 - how can I change the logo in a diazo theme?

蹲街弑〆低调 提交于 2019-12-22 15:25:10
问题 I have just installed a theme in Plone called beyondskins.responsive. Now I want to change the logo so that it uses the logo for my site and not the default Plone logo. I've spent an hour googling this problem and I have not found a solution. One of the places I looked was here: http://pypi.python.org/pypi/plone.app.theming#modifying-the-theme This site tells me "You can modify a theme by clicking Modify theme underneath a theme in the Themes tab of the Theming control panel." However, I don

Restrict upload by filetype or mimetype using Dexterity on Plone

微笑、不失礼 提交于 2019-12-22 09:25:17
问题 I have a custom content type, built with dexterity. In the schema (The schema is listed below), I use ' plone.namedfile.field.NamedFile ' for attachements/uploads. I would like to restrict uploads so that only mp3 files can be attached to my content type. What is the best approach for achieving this? Here is the full schema/model for my content type: <model xmlns="http://namespaces.plone.org/supermodel/schema"> <schema> <field name="date" type="zope.schema.Date"> <description /> <title>Date<

Migrating from (now obsolete) custom ATImage content type

半城伤御伤魂 提交于 2019-12-22 08:58:03
问题 We had a whole collection of Plone 3 sites with a custom Image type subclassed from ATImage. This allowed us to add an extra image scaling to the standard list ("'logo':(454, 58)", used by our theme package). While this still works in Plone 4, it isn't really the correct approach now that plone.app.imaging is part of the standard toolkit. That can define custom scales on the fly. It looks like I can enable plone.app.imaging on any type subclassed from ATImage by simply setting "sizes = None"

How to make footer to show items from main menu automatically in Plone?

别说谁变了你拦得住时间么 提交于 2019-12-22 08:17:27
问题 I am using Plone 4.1.4 with Doormat and Diazo in an institute I work and the Footer has to be made manually by adding each column and item that links internally to items from main menu. What I want is that this footer, which is the site map , to change automatically every-time some user create, edite or delete an item from the main menu ( content folders ). When I got the job I noticed many of those links in footer are out of date, and as there are many users in their each sections of the