Chapter 3. Folder permissions

Let me write, right?

We'll begin the process taking a look to the points mentioned in bullet four. Remember? It's the one that talked about making certain folders and a file writable. Let's take a look at what happens if you don't take care.

The first directory that needs writing permissions is uploads/. This is because in this directory is where you'll put the images you upload to your site. And to make a great site, you need to upload a lot of images. If this folder has no writing permissions, this is what you'll get:

The screen you get if the folder uploads/ is read only.

Figure 3.1. The screen you get if the folder uploads/ is read only.

So how do you make this folder writable? In Windows environments, you clear the “read only” attribute from the directory, either using Windows own commands (using the DOS command attrib) or some utility. In Linux environments, you need to set the permission on the folder to 777, using the command chmod. If the site is to be installed in a remote server, you can probably do this using your FTP client. If, for instance, you're using WS_FTP (a quite common FTP client), you position your cursor on the desired directory, click on its name using the right mouse button, and there you'll see a chmod command to apply to the directory. It will open a window with nine check boxes: all of them need to be checked.

Let's proceed. The next directory that need writing permissions is cache/. Why? Because this folder will contain none less than the whole structure of the administrative menu of your site. So if you want any control over your site, you need to be able to write here. When cache/ is not writable, you get a green screen warning you it's the first time you reach the admin section, even if you've been there zillions of times, so please be sure the folder is writable.

This is what you see if the folder is read only:

The screen you see if the folder cache/ is read only.

Figure 3.2. The screen you see if the folder cache/ is read only.

Ok. The third directory that needs writing permissions is templates_c/. In this directory you'll have the cached templates of your site. This means that for your site to run at full speed, you better can write here. When the folder is not writable, you'll see something like this:

This is what you see if the folder templates_c is not writable.

Figure 3.3. This is what you see if the folder templates_c is not writable.

Last, the bullet list of the writing permissions mentioned something about the file mainfile.php being writable. This is also crucial, as the file will contain, after the installation, a lot of the general system parameters, as you'll see after we install XOOPS. No wonder it's got this name. The file is essential for your XOOPS site to work. Mess with it and you'll risk losing your site. If you keep this file read-only, the wizard will warn you with a screen like this:

When mainfile.php is not writable, you see this screen.

Figure 3.4. When mainfile.php is not writable, you see this screen.

[Warning]Warning
I must warn you. You can proceed with the installation even if you see one of these red warning lights. The wizard will continue. However, some steps ahead you'll bump into an obstacle, as XOOPS finds out it can't do something that needs to be done. So if you see any of these red signs, correct the situation and refresh the screen.

What you need to see in order to proceed with peace of mind is something like:

The screen you want to see, filled with green go ahead lights.

Figure 3.5. The screen you want to see, filled with green “go ahead” lights.

If you see this screen while installing, congratulations! You have the writing permits okay, and you're set to continue installing XOOPS. To do so, click again in the button labeled Next. And to continue with this guide, see Chapter 4, General configuration.