[Product-Developers] Can I add an "external method" without using the ZMI?
Gilles Lenfant
gilles.lenfant at alterway.fr
Tue Jan 25 14:58:25 UTC 2011
Le 25 janv. 2011 à 00:49, kellys a écrit :
>
> Hi,
> I've created an "Extensions" directory in the root product folder, and added
> a python script which contains a function I want to call from the new
> product.
As Alex says, external methods are outdated (use views). Bu if you need something quickly, just drop an empty __init__.py in the "Extensions" folder of your product, and use your external method as any other python function
from Products.MyProduct.Extensions.mymodule import myfunc
...
foo = myfunc(anything, thats, expected)
>
> How can I reference these functions in the product without assuming that an
> external method has been added though the ZMI?
>
> Thanks!
> Kelly
> --
> View this message in context: http://plone.293351.n2.nabble.com/Can-I-add-an-external-method-without-using-the-ZMI-tp5957050p5957050.html
> Sent from the Product Developers mailing list archive at Nabble.com.
> _______________________________________________
> Product-Developers mailing list
> Product-Developers at lists.plone.org
> https://lists.plone.org/mailman/listinfo/product-developers
More information about the Product-Developers
mailing list