WebERP Manual Installation & Configuration
WebERP Manual Installation & Configuration
Preface.............................................................................................................................................................2
Preface
This manual was original created by webERP. As it was a text file with
minimum formatting I have edited it for best understanding and PDF
creation. I have added a table of contents and a quick check list to this
manual so that it might be very useful for the first time implementer.
I hope in some next version I shall provide screen shots too.
2
Getting Started
Prerequisites
• PHP greater than 4.2. The system is therefore operating system
independent since PHP can be configured as a CGI module for
use on MS IIS or as a module for Apache under either Windows
(NT, 2000 or XP) or Unix/Linux. It has been tested under both
Windows (NT and XP) and Linux.
• If the web server is accessible over the Internet and not just
over a LAN then encrypted communications are required. The
openssl and mod-ssl modules for Apache can be easily used to
ensure all data is transmitted in encrypted form.
Using Apache with mod_ssl and openssl secure sockets makes sense
where there is any data transmitted over the Internet and not just
over a LAN. Getting PHP and MySQL installed are well covered
elsewhere - see the following links:
3
http://logidac.com/apache/apache-install-rpm.phtml
http://www.linux-sottises.net/en_apache_install.php
The system could be used with many other database servers but
it is tested and developed on MySQL. A Postgres ConnectDB.inc
is provided and there is a $dbtype setting in config.php that
allows the system administrator to use a Postgres database if
preferred. Postgres database dumps are also available for
building a postgres webERP installation. Independent
benchmarks show that MySQL is one of the fastest databases for
most common database tasks. It is especially fast at initiating a
connection. Due to the stateless nature of the web, a new
connection is required to be established on every page. This
makes MySQL particularly suitable for web based applications.
4
an installation of Wacko Wiki on the same web-server is
required. This is entirely optional but is highly recommended as
a way to share free form information across the business.
http://wackowiki.com/WackoDownload/InEnglish?v=xlv
The ftp library for PHP is only required for sending order files to
a Radio Beacon ftp server for remote warehouse services.
5
Copying the PHP Scripts
All files in the archive except the installation instructions in
INSTALL.txt, weberp-demo.sql and weberp-new.sql should be
copied to a directory under the web server DocumentRoot
directory. This varies by distribution but:
/srv/www/htdocs
Copy the archive to this directory and then extract the archive.
The webERP directory will be created here
(/srv/www/htdocs/webERP) and all scripts and other directories
will be copied to that directory.
6
Creating the Database
The information provided assumes that you are using a MySQL
database server. An sql dump file suitable for Postgres is also
provided. However these instructions refer to the set up
necessary using MySQL.
You need to know the user name and password for the MySQL
server. If you have not set these up the default is
user root
password ""
BUT ... you should NOT use this account. You should set up
another user for your MySQL installation and change the root
password to something other than "".
All instructions for using MySQL refer to the command line client
that comes with MySQL. To run this under Windows a DOS box
must be opened. From XP or 2000 click Start, Run, enter "cmd"
and click Run. The mysql.exe binary is located by default under
C:\mysql\bin\mysql.exe. This would be the command line
statement required to run the mysql client. The options
discussed below should be appended as required.
You can, in MySQL Version 3.22 and above, use the SET
PASSWORD statement:
7
root user.
8
shell > mysql --user=weberp --password='some_pass' <
/path_to_the_sql_script/weberp-demo.sql
or
9
Editing config.php
config.php contains a series of user defined variables that
determine how the system behaves. Critically it contains the
host (computer name), username and password of the database
connection required to connect to the database server. There is
also an option to chose which type of database server is to be
used. Currently there are only options for mysql and postgres.
There is no going forward without this data.
========================================
====
beginning of config.php
========================================
====
<?php
/* $Revision: 1.8 $
config.php
Web-ERP - http://web-erp.sourceforge.net
*/
// webERP version
$Version = '3.04';
10
having
// the web-server on a overseas machine but record local time
// this is not necessary if you have your own server locally
// putenv('TZ=Europe/London');
// putenv('Australia/Melbourne');
// putenv('Australia/Sydney');
// putenv('TZ=Pacific/Auckland');
11
//The maximum time that a script can execute for before the
web-server should terminate it
$MaximumExecutionTime =120;
$rootpath = dirname($_SERVER['PHP_SELF']);
if ($rootpath == "/" OR $rootpath == "\\") {
$rootpath = "";
}
//$rootpath = '/web-erp';
/*Make sure there is nothing - not even spaces after this last ?>
*/ ?>
12
========================================
====
end of config.php
========================================
====
13
Logging In For the First Time
Open a browser connected to the network upon which the web
server is also connected. Enter the URL for the web server
directory where webERP is installed. If the browser is on the
same machine as the web server then perhaps:
http://localhost/webERP/index.php
14
Adding New Companies
At this point having followed all the instructions above you
should be able to log into the single company database you set
up above. However, you may wish to add additional companies.
If you system is set up such that the user account that is
running your web-server is able to write to the webERP directory
then it is possible to enter the URL:
http://yourdomain/webERP/Z_MakeNewCompany.php
This script may not work because it requires that the web-server
has write permission to the scripts directory, in which case you
may need to fall back to the manual method described below.
In the default install above you created a database called weberp
and there is a directory under webERP/companies also called
weberp. To make another company you need to copy the
15
Configuration Parameters
In versions prior to version 3.0, configuration parameters were
stored under the config.php file which required manual editing of
the system parameters. Since version 3.0 a new screen for
System Parameters was developed that allows all the system
wide configuration variables to be set. These are now stored in
the database allowing for upgrades without then having to re-
edit the config.php file. The system parameters screen is at Main
Menu > Setup > Configuration Settings. Each of these settings
should be reviewed in detail. Notes describing the function of
each variable are shown along side it.
16
Themes and GUI Modification
Often what visually appeals to one does not appeal to another.
Whilst accounting software is primarily about function -
appearances do matter! Some flexibility is available with the
colour scheme and font sizes of the GUI using cascading style
sheets (css).
Each user can select their own preference from the user settings
screen. This is revealed by clicking on their user name shown at
the top left of the screen. For example: "webERP Demo:
administrator".
17
Setting Up Users
Having logged in as user 'demo'. A new user should be defined
whom has administrative privileges and the user 'demo' should
be deleted.
From the menu click on the 'Setup' tab and then click 'User
Accounts'. The users defined are displayed. User names must be
5 characters or more. Passwords entered must be 5 characters
or more too. The password cannot also be the user name or
contain the user name. It is not necessary to enter the full name
telephone and other details. The access level selected is
important as this determines the pages that the user can access.
In any business where the employees are not also the owners it
is advisable to split the functions between staff so that no user
can complete an entire transaction. There are occasions in
smaller businesses where this is impractical. However, the
system has great flexibility to allow the user access to be finely
defined. See the security schema section.
18