[Zope] Keys in Request

Chris Withers lists at simplistix.co.uk
Wed Mar 3 05:27:17 EST 2004


Philip Kilner wrote:

> if not request.has_key('the_key'):

Try:

if not request.form.has_key('the_key'):

...if you're worried about for mvariables or URL parameters.

Otherwise:

value = request.get('the_key'):
if value is not None:

cheers,

Chris

-- 
Simplistix - Content Management, Zope & Python Consulting
            - http://www.simplistix.co.uk




More information about the Zope mailing list