Difference between revisions of "Unquote.py"
Jump to navigation
Jump to search
PeterHarding (talk | contribs) (New page: =Script= <pre> #!/usr/bin/env python import urllib str = """ <input type="hidden" name="pecontexthandle" value="%3CPromptEngineRuntimeContext%20xmlns%3D%22http%3A%2F%2Fwww.cry...) |
PeterHarding (talk | contribs) |
||
| Line 1: | Line 1: | ||
=Script= | =Script= | ||
A simple example of using the Python urllib to decode a quoted string. | |||
<pre> | <pre> | ||
Revision as of 17:03, 11 July 2008
Script
A simple example of using the Python urllib to decode a quoted string.
#!/usr/bin/env python
import urllib
str = """
<input type="hidden" name="pecontexthandle" value="%3CPromptEngineRuntimeContext%20xmlns%3D%22http%3A%2F%2Fwww.crystaldecisions.com%2Freport%22%20xmlns%3Axsi%3D%22http%3A%2F
...
%3C%2FCascadingPID%3E%3C%2FWorkingUnits%3E%3CNextPID%3E2%3C%2FNextPID%3E%3C%2FPromptEngineRuntimeContext%3E" />
<input type="hidden" name="pevalue" value="" />
<link rel="stylesheet" type="text/css" href="../../../viewers/crystalreportviewers115/prompting/css/promptengine_default.css">
"""
decoded = urllib.unquote(str)
print decoded