Re: virtual documents

Tony Sanders (
Wed, 07 Jul 1993 12:37:17 -0500

> Ron D. Appel ( writes:
> > In several papers, I have read about virtual and real documents.
> > How does one build (and send back to the client) a VIRTUAL DOCUMENT, for
> > example as a result of an index search?
> That can be done in quite a simple way.. the easiest way is to modify the
> HTTP server so that it creates a temporary file, then calls up a routine
> which handles the request and writes to that file, then sends and afterwards

Even better you can just:

fprintf(ns, "<TITLE>Search Results</TITLE>\n");
fprintf(ns, "...\n");

In Plexus I do this all the time. Calling it a "virtual document" is
really just a fancy way of saying you generate the data on the fly
instead of just returning a fixed file. You can also pass existing
data through a filter (like the man page filter) or you can do anything
else you can think of (run a macro preprocessor like m4 over it etc).