CMS Installation

Quick start guide

1. Download the source package.

2. Edit the configuration files (found in the config folder) for each package you wish to use, at a minimum mainconfig.php, userconfig.php and wsconfig.php.

3. If your /cms folder is anywhere other than /cms be sure to alter the home page redirect at /index.php

4. Upload all the files and folders to your server via FTP.

5. On the web start the page /admin/install.php and follow the remaining instructions from there.

6. If you want to use the user upload feature you will need to make sure that the /docs, /static,/templates and /images folders are writeable by apache.


Advanced setup

The default location of Webspaces Cms is in your webroot folder, as in If you want to run in it a folder or folders, you can do this by (for example)   specifying   $SUBFOLDERS=`/webspaces` which will give you


You can change the names of the module folders with no issues. But it is best to keep the peer relationship of the modules intact. However if you want to alter the fs path relationship of the modules, you can do it, with some extra config. Here is an example: changing the /cms folder to / (to shorten urls):

  • set $WSDIR= ``;
  • edit first line of /cms/init.php to reflect the new relationship ( in this case by changing $PATH2CODE=   `..`; to   $PATH2CODE=   `.`;
  • move /cms folder content to your webroot folder

This way the /cms scripts can still find the config folder. Each module has a init.php file which would need to be similar altered for each module you move out of the default peer folder location.


Auth methods

Most web hosted users will be fine with the default authentication method (sessions). In which case delete the two htaccess files in / , and the ../htpasswords folder, and read no further.



There are two htaccess methods.   The best is if you can setup authmysql on your server. With debian that would be using libapache2-mod-auth-pam libpam-mysql (see Debian Etch Admin Howto for more details).

  • set $AUTHSTYLE =`authmysql`;
  • rename /htaccess - authmysql   to /.htaccess (do this on the server as its an illegal filename under windows)
  • configure pam, and apache (see above link for howto)

This will then make apache auth with htaccess but logging in against the webspaces user database.



Most hosted sites probably wont have the ability to configure authmysql.

But if you still want to use htaccess against the user database, then:

  • set $AUTHSTYLE =`htaccess`;
  • rename /htaccess - passfile to /.htaccess (do this on the server as its an illegal filename under windows)
  • be sure to copy ../htpasswords folder to the folder immediately beneath your webroot so its not publicly accessible.
  • make sure the ../htpasswords is writable by apache.
  • If you need to put the ../htpasswords folder somewhere else, be sure to configure its location in the first line of /users/htamirror.php


Its a hack, and not that pretty. The initial password file contains one temporary user, guest:pawpaw which you should modify as your guestuser afterwards or delete it once you have your own user database. The installer doesnt set this file up, so you will need to do it manually for the root user, and guest user. Use the linux command htpasswd to do this.


Upload folders

The obvious way to do this is:

chown -R   www-data:www-data /docs /images /static /templates

chmod -R 0755   /docs /images /static /templates

However ftp users may be limited to chmod only, in which case you may have to resort to chmod 0777, although this will be a risk in some kinds of shared hosting environments, and definitely not good practice on any server. Neither solution is ideal, and probably the best way is to create   a group with both your ftp user and www-data, so that both may write to those folders.

Admin login