Personal tools
You are here: Home Documentation Error References AttributeError: toPortalTime
Support

Get Help

Join our chat rooms or support forums if you have more specific questions.

Plone Training
Learn how to design, build, and deploy a website in Plone through one of the numerous Plone training sessions around the world.
Find Plone training…
 
Document Actions

AttributeError: toPortalTime

This Error Reference applies to: Plone 2.5.x, Plone 2.1.x
This Error Reference is intended for: Any audience.

In Plone 2.1.2 or 2.5 you get an error message: AttributeError: toPortalTime

In Plone 2.1.2, toPortalTime (that had been marked as deprecated for a while) was replaced with toLocalizedTime, causing products and customizations that use the old name to raise this error.

This should not happen in a minor release, so toPortalTime was re-introduced in Plone 2.1.3. As a quick fix for this problem you can upgrade to Plone 2.1.3, or copy the toPortalTime.py file of 2.1.3 into a custom skin.

We do recommend, however, that you change all calls from toPortalTime to toLocalizedTime. toPortalTime is still deprecated in Plone 2.1, and it was removed in Plone 2.5.

When you encounter this error in Plone 2.5, it's probably caused by a product that hasn't been upgraded for Plone 2.5. Check the product's requirements and supported releases, and notify its maintainer of the problem. You may be able to work around the problem by copying the toPortalTime.py file of Plone 2.1.3 into a custom skin, but you should be prepared to deal with other compatibility problems of the product as well.

by Rene Pijlman last modified July 16, 2007 - 09:29
Contributors: Sydney Weidman, Alexander Limi, Nick Davis
All content is copyright Plone Foundation and the individual contributors.

For any issues with the web site functionality, please file a ticket.

Please consult the policy on plone.org content if you want your content published on this site.

Servers and hosting by