[Zope3-Users] Problems with "form" package and widget
Paolo Cilmo
blackeight_zope at yahoo.it
Tue Jan 3 14:14:08 EST 2006
Hi!
I'm tryng to create in Zope3 a "select tag" with this code:
voc=SimpleVocabulary.fromValues(lst)
repository_choice=Choice(title=u'Repository',
vocabulary='voc')
repository_list=List(__name__='replist', title=u'Repositories',
description=u'The repositories',
value_type=repository_choice)
field = Int(__name__='numero', title=u'Numero', min=0, max=10)
request = TestRequest(form={'repository_list.replist': u'9'})
widget = SelectWidget(repository_list, request)
widget.hasInput()
widget.getInputValue()
a= widget().replace(' ', '\n ')
print a
n.b. lst is a generic list
but it take this error:
__init__() takes exactly 4 arguments (3 given) How i correct this code?
And, where i can find a GOOD document for using widget? Zope3 book is very bad...
Please help me
---------------------------------
Yahoo! Mail: gratis 1GB per i messaggi, antispam, antivirus, POP3
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.zope.org/pipermail/zope3-users/attachments/20060103/f9789c1d/attachment.htm
More information about the Zope3-users
mailing list