category-group: www
layer(s): 3, 4, 10, 07, 12 header file(s): z_www.h synopsis.
The Z Directory provides support for web browsers and web servers, a cluster of subroutines to convert various URL encodings to text and various Z Directory containers for text, and the "XML document" class XMLdoc_o . There are 2 primary encodings handled in this group: "CGI" and "URL encoding":
- CGI: a string such as "my words have spaces?" converts to "my+words+have+spaces%3F";
- URL encoding: "my words have spaces" converts to "my%20words%20have%20spaces".
layer 04 functions group
layer 07 functions group description.
The XMLdoc_o class allows for creating, manipulating, and printing out XML data. However, this class uses another, external C++-based library: Xerces. Xerces is not provided with the Z Directory and must be installed and configured on your machine in order to use this class. It can be downloaded from this URL:
https://xerces.apache.org/xerces-c/download.cgi
The recommended version of Xerces is 3.1.1. Xerces is pre-built and requires no compilation from source. The Z Directory environment variable used to point to the base of the Xerces directory tree is $ZDIR_XERCES. For Visual Studio projects, just add the header file directory to the list of include paths ($ZDIR_XERCES/include) and the library directory to the list of external libraries ($ZDIR_XERCES/lib). Also, add the bin/ subdirectory ($ZDIR_XERCES/bin) into the path environment variable. One potential problem is that when running a program within the Visual Studio debugger, the Xerces DLLs (xerces-c_3_1.dll, xerces-c_3_1D.dll) may fail to be located. One workaround is to copy them into the project’s Debug/ or Release/ subdirectories. As of this writing (2017), there are some experimental items relating to HTML processing that have fallen into disuse and hence have been pulled out of the Z Directory release distribution until further notice. This includes a set of classes in layer 4 for mapping HTML to a databag format. note.
the functions at layer 0 are "primitives", originally created by the people who created the Apache web site server. These functions are a very old part of the Z Directory. There are only 4 functions there. They are still retained here but will probably morph into functions with more consistent Z Directory names and better signitures in the future.