spyce
         
home     documentation     download     Spyce logo


Examples

examples/login-optional.spy
<html><body>

<f:form>
  [[ if request.login_id():{ ]]
    You are logged in with user id [[= request.login_id() ]]
    <spy:logout />
  [[ } else: { ]]
    <spy:login />
    You are not logged in.  (You may login with username/password: spyce/spyce.)
  [[ } ]]
  
  <p>
  (Here is some content that is the same before and after login.)
</f:form>

</body></html>
Run this code

Back to List of Examples


Spyce logo
Python Server Pages
version 2.1.3
Spyce Powered SourceForge Logo