O'Reilly logo

Plone 3 Products Development Cookbook by Marcos F. Romero, Juan Pablo Giménez

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Creating a configuration form

In order to establish communication with the remote OpenX server, we first need at least three pieces of data: the URL to connect to, a username with sufficient rights access to fetch the inventory, and the password.

We could just hard-code them and it would work perfectly well, but that's not even close to the ideal solution. That's why we will now create a general purpose form with the previously introduced z3c.form library.

Getting ready

All the code detailed in this chapter will be added to the existing pox.controlpanel package developed earlier. If you don't have it, you can download it from this book's webpage.

How to do it...

  1. Edit the interfaces.py file in the pox.controlpanel package:
    from zope import schema from ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required