afraid not.. simple to create your own, NOTE that key words can be supplied more than once. Hence... ============================================ import urllib def urldecode(query): d = {} a = query.split('&') for s in a: if s.find('='): k,v = map(urllib.unquote, s.split('=')) try: d[k].append(v) except KeyError: d[k] = [v] return d s = 'Cat=1&by=down&start=1827&start=1234&anotherCat=me%3Dow%7e' print urldecode(s) ==================================================== prints out following and preserves the order of inputs for those keys given more than once as with 'start' key {'start': ['1827', '1234'], 'anotherCat': ['me=ow~'], 'by': ['down'], 'Cat': ['1']} hope that helps.. Edwin
-----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Behalf Of [EMAIL PROTECTED] Sent: Thursday, August 14, 2008 12:32 PM To: python-list@python.org Subject: urldecode function? hi is there a function that does the opposite of urllib.urlencode? for example urldecode('Cat=1&by=down&start=1827') returns a dictionary with {'Cat':1, 'by':'down','start':1827) thanks The information contained in this message and any attachment may be proprietary, confidential, and privileged or subject to the work product doctrine and thus protected from disclosure. If the reader of this message is not the intended recipient, or an employee or agent responsible for delivering this message to the intended recipient, you are hereby notified that any dissemination, distribution or copying of this communication is strictly prohibited. If you have received this communication in error, please notify me immediately by replying to this message and deleting it and all copies and backups thereof. Thank you.
-- http://mail.python.org/mailman/listinfo/python-list