The CMS.ini file
WCMS looks for a file in the project folder called
cms.ini
. Here is an example of what the file should look like:
#cms.py # Used by WCMS.py. Customize the values to your own needs inpath = input outpath = output sourcepath = parsers imagepath = images stylepath =style menupath = jremenu.xml parserDict = codedoc:CodeDocParser;devdoc:DevDocParser;jrepage:JREParser;mathlesson:LessonParser scriptpath = scripts remotesite = www.spiritone.com remotedir = public_html/ remoteuser =english remotepass =
Being a Macintosh user, I don’t have a lot of experience with INI files, so this may run against convention but it fits what POV-Ray does. Lines that begin with a # sign are comments, and all of the other lines follow the key=value profile. In this case, I set the
inpath
variable to ‹input’, which is the name of a directory inside my project directory. All of the other paths are likewise relative to the project directory path name.
The
menupath
line names the file where I’ve coded my menu structure as a WebMenu
item. It is not necessary to use WebMenu, but I’ve included it here for my ease of use.
The
parserDict
line is written out in an analogous fashion to Python’s native Dictionary structure. The data here tells WCMS that when it reads a page that has the
codedoc
DOCTYPE, use the file called
CodeDocParser
which should be in whatever directory is indicated in the
sourcepath
line.
The last four lines will become useful as I manage to write a WebContentManager subclass that will upload the processed files to my personal web space.