Chapter 8. WACS API: Core Module

Table of Contents

Core Module: Summary
Core Module: Reference

Core Module: Summary

Table 8.1. Function Summary: Core Module

functiondescription
read_conflocate and read the XML based configuration file
check_authcheck that this is an authorised access
auth_errorreport an authentication error and suggest remedies
auth_userreturn the registered username for this IP
add_authadd a new authentication token to access control system
update_authupdate the external content cache .htaccess files
find_config_locationtry to locate the specified XML config file
conf_get_attrget the requested configuration attribute
conf_dosubsdo substitutions for the standard wacs configuration variables
auth_get_attrget the requested access control list attribute
dberrorproduce a more helpful error page when db connections fail
gettodayget today's date as a string suitable for the current DB
timecompsbreak a date down into component parts
cachelocprovide expected location of the cache files for specified set
vendlinkprovide a link to the vendors site
loadattrvaluesload attribute values from the database
getvaluenametakes a single character flag and converts to string
geticonlistgets the icon array for the specified object type
gettypecolourget the prevailing colour scheme for the set type
divideupmake a directory name more readable
checkexcludecheck for this file name being one to ignore/hide
checkindexcheck for what might be an index file
makedbsafetry to make the returned string safe for use in the database
addheadercssadd standard preamble to enable javascript menus
setgrouppermsset the appropriate group permissions for co-operative updating
treemkdircreate a tree of directories (mkdir -p equiv)