diff options
| author | Steve Piercy <web@stevepiercy.com> | 2018-08-21 03:06:45 -0700 |
|---|---|---|
| committer | Steve Piercy <web@stevepiercy.com> | 2018-08-21 03:06:45 -0700 |
| commit | 4b84f6e97b321309544513b0697e8b378a57bafc (patch) | |
| tree | 8e034b1c1c70283d9fbffb4b273c4aecc9ee2547 /docs/narr/helloworld.py | |
| parent | 820a752645b460ea8009b07a75c752ab09c53dec (diff) | |
| download | pyramid-4b84f6e97b321309544513b0697e8b378a57bafc.tar.gz pyramid-4b84f6e97b321309544513b0697e8b378a57bafc.tar.bz2 pyramid-4b84f6e97b321309544513b0697e8b378a57bafc.zip | |
Synch Hello World app with canonical version on trypyramid.com and elsewhere
Diffstat (limited to 'docs/narr/helloworld.py')
| -rw-r--r-- | docs/narr/helloworld.py | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/docs/narr/helloworld.py b/docs/narr/helloworld.py index 29ed8e6f2..d384a0620 100644 --- a/docs/narr/helloworld.py +++ b/docs/narr/helloworld.py @@ -4,12 +4,13 @@ from pyramid.response import Response def hello_world(request): - return Response('Hello %(name)s!' % request.matchdict) + return Response('Hello World!') + if __name__ == '__main__': with Configurator() as config: - config.add_route('hello', '/hello/{name}') + config.add_route('hello', '/') config.add_view(hello_world, route_name='hello') app = config.make_wsgi_app() - server = make_server('0.0.0.0', 8080, app) + server = make_server('0.0.0.0', 6543, app) server.serve_forever() |
