Setting up User Accounts

fCMSPro allows you to set up multiple accounts with different usernames, passwords and permissions for each user. These instructions will show you how.

 

Changing the admin username and password

The default username and password for logging in to the fCMSPro are 'admin' and 'admin'. To change these values open the users.xml file which is located inside the config folder, which is in your fCMSBackend folder, using a plain text editor (for example Notepad on Windows or TextEdit on Mac). The default file looks like this:

<?xml version="1.0" encoding="utf-8"?>
<groups version="1.0">
<group name="admin">
<users>
<user name="admin" password="admin"/>
</users>

</group>
</groups>

 


Modify the name and password attributes of the 'user' node like so:
<?xml version="1.0" encoding="utf-8"?>

<groups version="1.0">
<group name="admin">
<users>
<user name="new_username" password="new_password"/>
</users>

</group>
</groups>

 

This will set the admin username to 'new_username' and the password to 'new_password'.

 

Adding new user groups

You can add new user groups to allow different people to log in. You do this by adding a new group element, containing a user's element which in turn contains user nodes the name and password attributes of which will be the username and password that these new users use to log in. To add a new group you would add the following code to your users.xml file:

<?xml version="1.0" encoding="utf-8"?>
<groups version="1.0">
<group name="admin">
<users>
<user name="new_username" password="new_password"/>
</users>

</group>
<group name="news_team">
<users>
<user name="Jennifer" password="Smith"/>
</users>
</group>
</groups>

 


This will create the new group with a new user. It is also possible to add new users to existing groups. To add a new user to a group you simply add a new user node with name and password attributes:

<?xml version="1.0" encoding="utf-8"?>

<groups version="1.0">
<group name="admin">
<users>
<user name="new_username" password="new_password"/>
</users>
</group>

<group name="news_team">
<users>
<user name="Jennifer" password="Smith"/>
<user name="Johnny" password="Smith"/> </users> </group> </groups>

 

 

Controlling File Uploads

To control the size and type of file uploads open the config.xml file which is located inside the config folder, which is inside the fCMSBackend folder, using a plain text editor. Locate the following lines:

<extensions>jpg,gif,png,swf</extensions>
<maxsize>1048576</maxsize>

You can edit these lines to adjust the types of file that can be uploaded and the size of the files that can be uploaded. The following code would add the file extension jpeg to allowed types of upload:

<extensions>jpg,gif,png,swf,jpeg</extensions>
<maxsize>1048576</maxsize>

 


To adjust the size of the files that can be uploaded alter the value of the maxsize node (in bytes). Note that your php.ini file may be set to allow a maximum file upload of 2MB (2097152 bytes). We recommend setting the maximum file upload size to around 100kb (102400 bytes):
<extensions>jpg,gif,png,swf,jpeg</extensions>
<maxsize>102400</maxsize>

Editing User Permissions

You can control the amount of editing a particular group can do by setting their permissions on the config.xml file (inside the config folder which is in your fCMSBackend folder). Locate the default group settings which look like this:

<group name="admin">
<filebrowser>
<root>/</root>
<upload>true</upload>
<delete>true</delete>

<preview>true</preview>
</filebrowser>
<fcms>
<edit>true</edit>
</fcms>

</group>

 


To add settings for the 'news_team' group added to the 'users.xml' file above add the code that is highlighted bold in the following code:

<group name="admin">
<filebrowser>
<root>/</root>
<upload>true</upload>

<delete>true</delete>
<preview>true</preview>
</filebrowser>
<fcms>
<edit>true</edit>

</fcms>
</group>
<group name="news_team">
<filebrowser>
<root>/</root>
<upload>true</upload>

<delete>true</delete>
<preview>true</preview>
</filebrowser>
<fcms>
<edit>true</edit>

</fcms>
</group>

 

This will set the permissions for the news_team group to match the admin group.

 

To specify a different folder for file uploads edit the root node like so:

<root>myFolder/</root>

 

To prevent a group from uploading at all set the value of the 'upload' node to false:
<upload>false</upload>

 

To prevent a group from deleting file and directories set the value of the 'delete' node to false:
<delete>false</delete>

 

To prevent a group from previewing files set the value of the 'preview' node to false:
<preview>false</preview>

 

Setting the value of the edit node to false will remove the group's editing privileges.