Christian Scholz  committed 8884bf7

added Ajax command examples

  • Participants
  • Parent commits c9e6b85
  • Branches default

Comments (0)

Files changed (1)

File docs/ajaxprotocol.txt

 The helper functions on the server side
+On the server side you can use commands like follows::
+    from commands import replace_inner, call, Commands
+    html = "somehow generate HTML"
+    cmds = Commands()
+    cmds.append(replace_inner('users',html))
+    cmds.append(call('myfunction',{'param' : 'value'}))
+    return cmds.render_wsgi(environ, start_response)
+Basically ``Commands`` is a list which has additional render methods like ``render_wsgi()`` for returning a term:`WSGI` response.