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

version» Context lines:

Roxen.git/server/modules/misc/randomtext.pike:53:   // called.   //   // ... any yes, this module was a quick hack for amusement and for   // use in some courses to help provide dummy contents for new sites,   // so don't use this as a model for how to write Roxen modules.      inherit "module";      #include <module.h>    - string version = "$Id: randomtext.pike,v 1.8 2002/06/05 10:13:17 nilsson Exp $"; + string version = "$Id: randomtext.pike,v 1.9 2002/10/22 00:24:20 nilsson Exp $";      constant module_type = MODULE_TAG;   constant module_name = "Random Text";   constant module_doc =    "This module provides a simple way of generating texts on a "    "semi-random basis according to a set of rules. Apart from its "    "amusement value, this can be useful for testing and educational "    "purposes, such as generating small quiz pages or producing "    "many different kinds of input for testing text processing tags.";   
Roxen.git/server/modules/misc/randomtext.pike:476:    recenttagtime = time();       NOCACHE();       if (attr->rules)    { string file = attr->rules;    string cwd = 0;       if (!file || !stringp(file))    file = "default"; -  if (search(file, "/") != -1) +  if (has_value(file, "/"))    return "<b>make-random-text: `/' not allowed in rules name</b>";       if (query("searchcwd") && stringp(id->realfile))    {    if (Stdio.file_size(id->realfile) > 0)    cwd = dirname(id->realfile);    else if (Stdio.file_size(id->realfile) == -2)    cwd = id->realfile;    }