Roxen.git / server / modules / misc / demo.pike

version» Context lines:

Roxen.git/server/modules/misc/demo.pike:1:   // This is a roxen module. Copyright © 1998 - 2009, Roxen IS.      #include <module.h>   inherit "module";    - constant cvs_version = "$Id: demo.pike,v 1.22 2009/05/07 14:15:55 mast Exp $"; + constant cvs_version = "$Id$";      void create()   {    defvar("location", "/demo/", "Mount point", TYPE_LOCATION,    "This is where the module will be inserted in the "+    "namespace of your server.");       defvar("dbpath", "../var/demomodule-bookmarks", "Database path",    TYPE_STRING, "This is the path to the module's Yabu database.",    0, 1); // Don't show this variable
Roxen.git/server/modules/misc/demo.pike:54:   "</td><td>"\   "<form action='%d'>" \   "<input type='submit' value=' next --> ' />" \   "</form>" \   "</td></tr></table>" \   "</body>"      object mdb;   array(string) stack=({ });    + // NB: Yabu is deprecated. + #pragma no_deprecation_warnings +    mapping find_file( string f, RequestID id )   {    if(id->variables->go)    return Roxen.http_redirect(query("location")+id->variables->pos,id);    if (!mdb) {    mdb = Yabu.db(query("dbpath"), "wcCr")["demo"];    if(!mdb[42])    mdb[42]=   #"<for variable=var.i from=99 to=1 step=-1>    <if not variable=\"var.i is 1\">
Roxen.git/server/modules/misc/demo.pike:111:    if (!stringp( data ))    data = "";    return Roxen.http_string_answer( Roxen.parse_rxml    ( sprintf( FOO, (int)f,    data,    replace(data, ({ "<", ">", "&" }),    ({"&lt;","&gt;","&amp;"})),    ((int)f)-1,    ((int)f)+1), id));   } +  + #pragma deprecation_warnings