WebStack

examples/Twisted/SimpleWithLoginApp.py

383:74ed715c5455
2005-05-01 paulb [project @ 2005-05-01 18:16:52 by paulb] Added missing example for Zope.
     1 #!/usr/bin/env python     2      3 from WebStack.Adapters.Twisted import deploy     4 from WebStack.Resources.LoginRedirect import LoginRedirectResource, LoginRedirectAuthenticator     5 from Simple import SimpleResource     6      7 print "Serving..."     8 deploy(     9     LoginRedirectResource(    10         login_url="http://localhost:8081",    11         app_url="http://localhost:8080",    12         resource=SimpleResource(),    13         authenticator=LoginRedirectAuthenticator(secret_key="horses"),    14         anonymous_parameter_name="anonymous",    15         logout_parameter_name="logout"    16     )    17 )    18     19 # vim: tabstop=4 expandtab shiftwidth=4