parameters: ()
return_statement: return MARKMIN(page.body,extra={'widget':(lambda code:''),
                                      'template':(lambda template:'')})
docstring: shows a page
docstring_summary: shows a page
docstring_tokens: shows a page
function: def page():
      """
      shows a page
      """
      slug = request.args(0) or 'index'
      w = db.plugin_wiki_page
      page = w(slug=slug)
      if not auth.user and (not page or not page.is_public or not page.is_active):
          redirect(URL(r=request,c='default',f='user',args='login'))
      elif not plugin_wiki_editor and (not page or not page.is_public or not page.is_active):
          raise HTTP(404)
      elif page and page.role and not auth.has_membership(page.role):    
          raise HTTP(404)
      if request.extension=='load':
          return plugin_wiki.render(page.body)
      if request.extension=='html':         
          return dict(page=page,slug=slug)
      return MARKMIN(page.body,extra={'widget':(lambda code:''),
                                      'template':(lambda template:'')})
function_tokens: def page ( ) : slug = request . args ( 0 ) or 'index' w = db . plugin_wiki_page page = w ( slug = slug ) if not auth . user and ( not page or not page . is_public or not page . is_active ) : redirect ( URL ( r = request , c = 'default' , f = 'user' , args = 'login' ) ) elif not plugin_wiki_editor and ( not page or not page . is_public or not page . is_active ) : raise HTTP ( 404 ) elif page and page . role and not auth . has_membership ( page . role ) : raise HTTP ( 404 ) if request . extension == 'load' : return plugin_wiki . render ( page . body ) if request . extension == 'html' : return dict ( page = page , slug = slug ) return MARKMIN ( page . body , extra = { 'widget' : ( lambda code : '' ) , 'template' : ( lambda template : '' ) } )