« HS-CMS documentation home


Note this document is not necessarily 100% up to date. I'm trying, though. Yell at me if it isn't.

See also: Requirements

  1. Download & unzip HS-CMS. All its folders (like hs_core, hs_sites, hs_logs, and hs_public) should be in your site root.

  2. For smooth sailing, sudo chmod -R 777 . in the directory

  3. Rename:

    • Directory "hs_sites-example" to "hs_sites"
    • File "config_installation-example.php" to "config_installation.php".
    • File "example.htaccess" to ".htaccess" (note, this is now a hidden file)
  4. You should then see a welcome page at the root of your website or wherever you have HS-CMS installed. This is the default site, "welcome." It lives in hs_sites/welcome.

Adding a website / domain (including your first)

HS-CMS supports multiple, separate websites in just one installation, unlike Wordpress and other systems. This means upgrading your HS-CMS installation is a one-shot deal across your sites. (Of course, you could have a 1:1 relationship between HS-CMS installations and sites, but that seems like a waste of space for typical usages.)

  1. In the "sites" folder, add a new sub-folder with your site's name (next to "welcome" if you haven't deleted it (you shouldn't) or existing sites if you already made one). It should be a folder-friendly string with no spaces or special characters. For example, for a website at https://alanhogan.com, I would call my site folder "alanhogan" or "alanhogancom". It doesn't matter too much what you call it; "ahcom" would work well, or "zebra". It should just make sense to you.

  2. It may be a good idea to chmod -R 777 this new folder.

  3. Take a look at config_installation.php in the root of your HS-CMS installation and edit it appropriately. You will want to copy an entry for the "example" site, change it to map your domain to your site's folder name, and uncomment the line.

    • Note that you should not include 'www.' or 'http://' as HS-CMS considers www.example.com and example.com to be the same site.
    • If, however you actually want www.example.com and example.com to be different sites, that should work. (No promises.)
  4. Copy sites/welcome/config_site.php to sites/your-new-site/config_site.php

  5. Edit config_site.php

    • Important Set your email address so HS-CMS can inform you of serious errors as they happen
    • Set up your database information
    • Set your site domain, site name, and site description.
    • Optionally detect the domain and set different options (like cache lifetime or database connection) based on whether it is a live server or a staging / development / test server

    Some settings, like render engine, you might not yet know what to do with yet. That's fine. Don't worry about it yet.

  6. Head to http://your-new-domain.tld/admin/add-site.php where your-new-domain.tld is the one you just created a sites folder for and mapped in the config_installation.php file.

    This will attempt to:

    • Flesh out the directory structure under your new sites folder
    • Create database tables (but not the database, you should do that manually first)
    • Automatically edit your mod_rewrite rules
  7. Congratulations! Your site should be live. Now add some pages!

Troubleshooting your installation

See installation troubleshooting