<Database>

The <Database> option is used to configure Gigatrees5 for use with web servers. It will require that your web server supports PHP, SQLite3 and PDO extensions. This is standard for Apache servers and generally enabled by default. Consult your hosting service for help if needed. Gigatrees5 includes several support files in the includes folder ( /includes ) to support using databases. When enabled, all the necessary files will be copied to the output path. These files include the main router ( router.php ), which retrieves the requested web page from the database and sends it to the web browser. It also manages user authentication when enabled; the Apache Web Server access file ( .htaccess ), which redirects all incoming page requests to the main router; the database access file ( pdodriver.php ), which gives the router to access the database; and the includes file ( includes.php ), which is autogenerated by Gigatrees5 and tells the router where the database is located on the server.

Gigatrees:
<EnableServerDatabase> [ false ] To enable this service, this option must be set to true.
<ServerDatabaseName> [ ] Expects a database filename only. A file extension is optional.
<ServerDatabasePath> [ ] Expects a relative web server folder. This is the database path on the web server and will be saved in the includes file. As a general rule, web server databases should not be stored in any folder exposed to the Internet.
<LocalDatabasePath> [ ] Expects an absolute or relative folder path. This is the path found on the local computer where you want your database stored. This is necessary for the application to find and use when building your website.
<CopySupportFiles> [ true ] Gigatrees5 requires 4 support files to use this service. The files will be copied to the output folder each time the applications runs. The files do not change, so once they are copied it is not necessary to copy them repeatedly. If you need to modify any of these file, for instance to extend their capabilities, you may want to disabled this option by setting it to false. The 4 files include ( .htaccess ), an Apache Web Server access file, which will be copied from the includes folder and is needed to redirect all missing page requests to the router. This allows for adding static web pages to the output folder. If you are not using an Apache Web Server, you may need to replace this file. The router ( router.php ) will also be copied from the includes folder and is needed to retrieve the requested web page from the database and post the page to the requesting web browser. The database access file ( pdodriver.php ) will also be copied from the includes folder and provides the necessary PDO database access routines. Lastly, Gigatrees5 will generate an includes file ( includes.php ), which defined the database path.
<SupportFilesPath> [ /includes] Expects an absolute or relative folder path. This is the path found on the local computer where your database support files are stored. This is necessary for the application to find and use when building your website.
<VisitorLogPath> [ ] When set, all page accesses will be logged.
<SigninRequired> [ false ] When enabled, all pages require user authentication to access.
<User> [ ] This tag indicates the start of a new user
<Username> [ ] The user's username
<AccessCode> [ ] The user's access code
Example:
<Database>
<EnableServerDatabase> true </EnableServerDatabase>
<ServerDatabaseName> database.sqlite </ServerDatabaseName>
<ServerDatabasePath> /home/site/dbs/ </ServerDatabasePath>
<LocalDatabasePath> web </LocalDatabasePath>
<CopySupportFiles> true </CopySupportFiles>
<SupportFilesPath> includes </SupportFilesPath>
<VisitorLogPath> /home/site/logs/site.log </VisitorLogPath>
<SigninRequired> true </SigninRequired>
<User>
<Username> guest </Username>
<AccessCode> guest </AccessCode>
</User>
</Database>