Hello again,

By looking at the source to ZWiki I've managed to get
a dummy version of my searching working, passing the
data from the form by GET instead of POST. As well as
changing the form method to "get", I've changed the
Python View Class to read:

    def getMatchingAdverts(self):
        max_rent = int(self.request.get('max_rent'))
 (etc)

So, the method is only picking up one argument in its
definition, and gets the rest from self.request.get.

I have two questions:

1. Where should I be looking for documentation on how
to use self.request.get?
2. What is the equivalent way of getting arguments
from POST methods? (I guessed self.request.post, but
that didn't seem to work).

With reference to GET and POST, I'm a little torn on
which to use. This page:

http://www.cs.tut.fi/~jkorpela/forms/methods.html

says that I should be using GET only if the results of
the form will not be making any changes. My intention
is that the act of searching should make some changes
(albeit small) - specifically, I want to create a
record of the search having been done, so we can build
stats of what types of searches are being done. Does
anybody have any guidance on whether the theory would
suggest that this would be considered a small enough
change that it's appropriate to use GET? (Or indeed
from a practical perspective whether there are any
features of the way GET and POST are handled that
would make one of them more useful in actually causing
the change).

Thanks,
Jim


                
___________________________________________________________ 
How much free photo storage do you get? Store your holiday 
snaps for FREE with Yahoo! Photos http://uk.photos.yahoo.com
_______________________________________________
Zope3-users mailing list
Zope3-users@zope.org
http://mail.zope.org/mailman/listinfo/zope3-users

Reply via email to