To install, simply upload the files in the archive to your webserver, and navigate to http://yoursite.com/install/, then follow the prompts.
Prerequisites:
PHP
Installation prerequisites depend on your host. PHP version 5.3 is strongly recommended, if your host supports it (most do, even if it is not the default). If you must use version 5.2, then you must set the ‘magic_quotes_gpc’ and ‘magic_quotes_runtime’ php.ini settings to ‘off’. This setting is deprecated in version 5.3, and the default behaviour is as if it is turned off. More information here: http://php.net/manual/en/security.magicquotes.disabling.php
Your installation of PHP must have the GD library installed. Most shared hosts will have this. Some development environments (some versions of Ubuntu) may not have it by default. On Ubuntu, it can be installed by issuing the following commands:
sudo apt-get install php5-gd sudo apachectl restart
PHP error logs
Most customers can ignore this section, but it may be useful for developers customizing the php code.
The php error logs can generate a lot of content (and so use up disk space) if the error_reporting setting is set too low. On production settings, we recommend setting this value to E_ALL & ~E_WARNING & ~E_NOTICE, which logs all errors, but not notices or warnings. Most PHP installations default to logging warnings. Some of the older code in Restaurant Biller will generate warnings that are benign, so it is recommended that you run your production system with warnings turned off.
Because changing the error_reporting setting can be difficult on some shared hosts, Restaurant Biller automatically overrides the error_reporting setting near the top of the file app.render.php. You can change the setting there to increase the level of error reporting during development and testing.
We also override the location of the error_log file (and turn on logging) in the file includes/db.inc.php. The location of the error_log file is: templates_c/error_log (which is guaranteed to be readable and writeable by your account by the installation process).
All of this means that in some cases, your server log messages may be distributed across multiple files – the apache error log (which may contain 404 ‘file not found’ messages for missing images, etc), the error_log location defined in your php.ini file (which may contain php parsing errors if you have incorrectly customized some of the root php files such as index.php), and the one we define above. In almost every case, any errors of interest will be in the easily located templates_c/error_log location.
Database
The installation process will attempt to create the mysql database specified during the installation, if one does not already exist. If your host does not allow your code (user account) to create databases, then you must use the tools they provide to create a new (blank) database, and set appropriate (write, create) permissions for the user account provided. If you are having trouble connecting to your database, you can test the your credentials and other connection information by loading up /install/connectionTest.php in your browser, after editing the obvious login information in that file. This file has no dependencies on any other code so any problems that it has connecting with the database must be related to your infrastructure (typically it’s a matter of user permissions).
File/folder permissions:
The installation process will check for file and folder permissions required for successful installation and operation. The install process will display the permissions requirements at the appropriate time, so you can change to appropriate tools to modify the permissions of the appropriate files/folders. This typically is done via ssh command prompt, but can be done with most ftp clients. The process will not proceed until the permissions are correct.
Permissions
The installation process assumes you are installing on a Linux host. If you are installing on a windows host (perhaps your development environment), you will not be able to successfully pass the permissions checks. However, Restaurantbiller runs just fine on windows hosts – it simply requires full write permissions by the web process to the indicated files and folders. Until the installation process can be modified to support windows, you can simply copy the files generated by the installation process on a linux machine to your windows host. Alternatively, you can edit the code in install/install_functions.php. Change the function checkPermissions (approximately line 82 in the file) to return an empty string. This will bypass the permissions checks on windows. Your apache process will still need write permissions to the files/folders indicated, however. This issue will be resolved at some point in the future.
Licensing requirements:
Restaurant Biller is licensed per domain name, which is checked during the installation process, and at other times during the running of the application. In order to successfully install, you must provide us with the fully qualified domain name (including the www. or orders. part), so that we can associate the license key you will be given with the domain name. You will also be provided with a license to ‘localhost’ for development/testing purposes. Some developers like to create a ‘fake’ domain name using their local hosts configuration file for development purposes to help them manage multiple development projects. If you require a development address other than localhost, let us know and we’ll update the license to accomodate this.
Super Administrator:
In the last step of the installation wizard, you will be asked for the name of your restaurant, and the username/password for the administrator user. All of these can be changed from the administration section of the application. However it’s important to understand that the administrator of this first restaurant created is the ‘super administrator’ for the system, who has access to the configuration for all of the other restaurants in the system. If you are setting up a multi-restaurant installation of the system, do not use this first restaurant as one of your third-party restaurants. There is a configuration option in the restaurant settings to not include the restaurant in search results. You can use this setting if this first restaurant will not be a ‘live’ restaurant.
Once the installation process is finished, you can go to http://yoursite.com/admin/ to start configuring your restaurant(s).