HTML Logo by World Wide Web Consortium (www.w3.org). Click to learn more about our commitment to accessibility and standards.

Moving forward with Composr

ocPortal has been relaunched as Composr CMS, which is now in beta. ocPortal 9 will be superseded by Composr 10.

Head over to compo.sr for our new site, and to our migration roadmap. Existing ocPortal member accounts have been mirrored.


ocPortal Tutorial: Installing ocPortal on a Windows desktop

Written by Chris Graham, ocProducts
This tutorial will explain how to get an ocPortal installation running on your own Windows computer. Linux is easier as it usually comes with everything ocPortal requires pre-installed.

This tutorial will give basic instructions for installation of the various pieces of system software that ocPortal requires, instructing to read the products' own documentation when necessary. It is well worth pointing out that there are a number of 'all in one' packages that may be used to install AMP (Apache , mySQL and PHP ) without any special configuration for them to appropriately bind to each other. This may be preferable, but by doing so you inevitably will not know as much about the environment that was created for you. See WAMP-Server link under 'See Also' for this.

It is important to remember that if you are transferring files such as themes between one ocPortal installation and another, you need to set file permissions appropriately after copying.


Microsoft Web Platform

This tutorial is primarily about how to install an Apache set up on Windows. However, we actually have a Microsoft Web Platform installer for ocPortal. If you download the Microsoft Web Platform, you'll find ocPortal is in there.

This should work well, however we aren't able to regularly test it as it is very different from our normal development environment and workflow. Microsoft test the integration each time we publish an update.

If you'd like to use Microsoft Web Platform, proceed to the Web Platform website.

You may want to set full permissions on the install directory, at least initially, as this will be required for addon management (which the Setup Wizard does). Assign full write permissions to 'IIS_IUSRS' and 'IUSR'.

One small note – if you are developing locally, then choose to use WebMatrix to push a local site live, make sure you adjust the base URL setting in your info.php file to reflect your live URL.

Web server

The first thing you will need is a web server. Depending on your version of Windows, you may have the Windows web server available to you (Internet Information Server, or the cut down Personal Web Server).

If not, the best course of action is to install Apache. Go to Welcome! - The Apache HTTP Server Project and download and install whichever Windows release you are comfortable with. The PHP folk recommend to avoid version 2, but if you are only running ocPortal locally for yourself, it doesn't matter. You may wish to enable 'mod_rewrite' in Apache.

PHP

Next you will need a copy of PHP installed. Go to PHP: Hypertext Preprocessor and download and install the latest stable Windows release. Follow the instructions to get it integrated with your web server: these may be rather complex, but it would be self-defeating for us to try and re-write them for you.

mySQL

Go to MySQL :: The world's most popular open source database and download and install the latest stable Windows release. mySQL comes with a powerful Windows installer, so configuring mySQL itself should be a walk in the park.

Depending on your PHP installation, you may need to enable the 'mysql' PHP extension in the php.ini file, and then to restart your web server. Also enable GD2 if it is not already enabled.

You will need to create a database for ocPortal. To do this you may either:

(open a command prompt in the mysql bin directory)

Code

mysql -Uroot -p<password>
CREATE DATABASE <your-database name>;

ocPortal

Thumbnail: Setting permissions (1)

Setting permissions (1)

Assuming you want to use our own forum, you now install ocPortal. If you want to install a third-party forum on your computer, follow their documentation.

Because you are unlikely to have an account based FTP/HTTP set-up like web-hosts provide, using the quick installer is probably not the truly quickest option. Fortunately due to the (wonderful!) inheritable Windows permissions system, and the fact you are at your own computer, you can just extract the manual installer files and run through the installation without having to set any file permissions or do any uploading.

Before you extract the files, you must make sure that the web directory, or sub-directory thereof, has been configured to have the right file permissions.

If you are running IIS : Give 'Full control' to 'IIS_WPG' and 'IUSR_<computer-name>', as demonstrated in the screen-shot.
On Windows Server 2008+ these may be called 'IIS_IUSRS' and 'IUSR'.

If you are running Apache: Apache is probably running with the credentials of your own user account, and hence special permissions are not required.

Thumbnail: Setting permissions (2)

Setting permissions (2)

Thumbnail: Setting permission inheriting for a file (perhaps one copied into the web directory from somewhere that did not have it)

Setting permission inheriting for a file (perhaps one copied into the web directory from somewhere that did not have it)

By default when you extract files, they are set to inherit permissions of the parent directory: hence by setting the permissions of this directory you have allowed the files extracted into it to all have web server write permission. This would be a potential security risk on a shared hosting environment, and it is advisable to make sure that your web server is not accessible from outside your computer/local-network.

If you find that some files underneath your install directory, often ones moved in, have the wrong permissions, you can manually set them to inherit permissions (from the security tab of the file, click the advanced button, and set inheriting). Or you can tell Windows to reset permissions on all the files underneath the install directory (from the security tab of the install directory, click the advanced button, and select as demonstrated in the screen-shot).

Once the permissions are set, just run through the installer, and you should have a working ocPortal installation.

Concepts

IIS
Internet Information Server: Microsoft's web server software for Windows servers
Apache
The web server software used for the vast majority of websites on the Internet

See also