1.1 --- a/examples/Common/SimpleApplication/__init__.py Sun Feb 01 18:46:33 2004 +0000
1.2 +++ b/examples/Common/SimpleApplication/__init__.py Sun Feb 01 19:26:01 2004 +0000
1.3 @@ -13,27 +13,26 @@
1.4
1.5 # Get some information.
1.6
1.7 - path_info, path = "", ""
1.8 -
1.9 - try:
1.10 - path_info = trans.get_path_info()
1.11 - path = trans.get_path()
1.12 - except NotImplementedError:
1.13 - pass
1.14 -
1.15 out = trans.get_response_stream()
1.16 out.write("""
1.17 <html>
1.18 <body>
1.19 <h1>Test</h1>
1.20 - <p>
1.21 - Path: %s
1.22 - </p>
1.23 - <p>
1.24 - Path info: %s
1.25 - </p>
1.26 + <ul>
1.27 + <li>Path: %s</li>
1.28 + <li>Path info: %s</li>
1.29 + <li>Request method: %s</li>
1.30 + <li>Content type: %s</li>
1.31 + <li>Charset: %s</li>
1.32 + </ul>
1.33 </body>
1.34 </html>
1.35 -""" % (path, path_info))
1.36 +""" % (
1.37 + trans.get_path(),
1.38 + trans.get_path_info(),
1.39 + trans.get_request_method(),
1.40 + trans.get_content_type().content_type,
1.41 + trans.get_content_type().charset,
1.42 +))
1.43
1.44 # vim: tabstop=4 expandtab shiftwidth=4