xref: /webtrees/README.md (revision ba2c9f9f088a1c89c82281b39da317c39a2ba5df)
16b5264c5SGreg Roach[![Latest Stable Version](https://poser.pugx.org/fisharebest/webtrees/v/stable.svg)](https://packagist.org/packages/fisharebest/webtrees)
279043d8fSGreg Roach[![Latest Unstable Version](https://poser.pugx.org/fisharebest/webtrees/v/unstable.svg)](https://packagist.org/packages/fisharebest/webtrees)
3329f5281SGreg Roach[![License](https://poser.pugx.org/fisharebest/webtrees/license)](https://packagist.org/packages/fisharebest/webtrees)
4a592e1c1SGreg Roach[![Build Status](https://travis-ci.org/fisharebest/webtrees.svg?branch=master)](https://travis-ci.org/fisharebest/webtrees)
5ad92d32aSGreg Roach[![Coverage Status](https://coveralls.io/repos/github/fisharebest/webtrees/badge.svg?branch=master)](https://coveralls.io/github/fisharebest/webtrees?branch=master)
6*ba2c9f9fSGreg Roach[![Translation status](https://weblate.iet.open.ac.uk/widgets/webtrees/-/svg-badge.svg)](https://weblate.iet.open.ac.uk/projects/webtrees/webtrees/)
7e48069ebSGreg Roach[![SensioLabsInsight](https://insight.sensiolabs.com/projects/78a5ba19-7ddf-4a58-8262-1c8a149f38de/mini.png)](https://insight.sensiolabs.com/projects/78a5ba19-7ddf-4a58-8262-1c8a149f38de)
8c9b50c59SGreg Roach[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/fisharebest/webtrees/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/fisharebest/webtrees/?branch=master)
982f63a0eSGreg Roach[![Code Climate](https://codeclimate.com/github/fisharebest/webtrees/badges/gpa.svg)](https://codeclimate.com/github/fisharebest/webtrees)
10a4eb115aSGreg Roach[![StyleCI](https://github.styleci.io/repos/11836349/shield?branch=master)](https://github.styleci.io/repos/11836349)
113344c7f9SGreg Roach
126ccdf4f0SGreg Roach# webtrees - online collaborative genealogy
13fac25c68SRico Sonntag
14e00de034SGreg RoachThe project’s website is [www.webtrees.net](https://www.webtrees.net).
1587f36d93SGreg RoachFurther documentation is available at [wiki.webtrees.net](https://wiki.webtrees.net) and [webtrees.github.io](https://webtrees.github.io).
16b4ef7f82SRico Sonntag
17fac25c68SRico Sonntag## Contents
18fac25c68SRico Sonntag
19fac25c68SRico Sonntag* [License](#license)
206ccdf4f0SGreg Roach* [Coding styles and standards](#coding-styles-and-standards)
21fac25c68SRico Sonntag* [Introduction](#introduction)
2226a22ad2SJustCarmen* [System requirements](#system-requirements)
23bd82e704SDavid Drury* [Internet browser compatibility](#internet-browser-compatibility)
24fac25c68SRico Sonntag* [Installation](#installation)
25fac25c68SRico Sonntag* [Upgrading](#upgrading)
26bd82e704SDavid Drury* [Building and developing](#building-and-developing)
2726a22ad2SJustCarmen* [Gedcom (family tree) files](#gedcom-family-tree-files)
28fac25c68SRico Sonntag* [Security](#security)
29fac25c68SRico Sonntag* [Backup](#backup)
30fac25c68SRico Sonntag
31b4ef7f82SRico Sonntag
326ccdf4f0SGreg Roach## License
33fac25c68SRico Sonntag
34a25f0a04SGreg Roach* **webtrees: online genealogy**
356ccdf4f0SGreg Roach* Copyright 2019 webtrees development team
36fac25c68SRico Sonntag
37a25f0a04SGreg RoachThis program is free software: you can redistribute it and/or modify
38a25f0a04SGreg Roachit under the terms of the GNU General Public License as published by
39a25f0a04SGreg Roachthe Free Software Foundation, either version 3 of the License, or
40a25f0a04SGreg Roach(at your option) any later version.
41fac25c68SRico Sonntag
42a25f0a04SGreg RoachThis program is distributed in the hope that it will be useful,
43a25f0a04SGreg Roachbut WITHOUT ANY WARRANTY; without even the implied warranty of
44a25f0a04SGreg RoachMERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
45a25f0a04SGreg RoachGNU General Public License for more details.
46fac25c68SRico Sonntag
47a25f0a04SGreg RoachYou should have received a copy of the GNU General Public License
48a25f0a04SGreg Roachalong with this program. If not, see <http://www.gnu.org/licenses/>.
49fac25c68SRico Sonntag
506ccdf4f0SGreg Roach## Coding styles and standards
51fac25c68SRico Sonntag
526ccdf4f0SGreg Roachwebtrees follows the [PHP Standards Recommendations](https://www.php-fig.org/psr).
536ccdf4f0SGreg Roach
546ccdf4f0SGreg Roach* [PSR-1](https://www.php-fig.org/psr/psr-1) - Basic Coding Standard
556ccdf4f0SGreg Roach* [PSR-2](https://www.php-fig.org/psr/psr-2) - Coding Style Guide
566ccdf4f0SGreg Roach* [PSR-4](https://www.php-fig.org/psr/psr-4) - Autoloading Stardard
576ccdf4f0SGreg Roach* [PSR-7](https://www.php-fig.org/psr/psr-7) - HTTP Message Interface
586ccdf4f0SGreg Roach* [PSR-11](https://www.php-fig.org/psr/psr-11) - Container Interface
59cb55cd99SGreg Roach* [PSR-12](https://www.php-fig.org/psr/psr-12) - Extended Coding Style Guide
606ccdf4f0SGreg Roach* [PSR-15](https://www.php-fig.org/psr/psr-15) - HTTP Handlers
61cb55cd99SGreg Roach* [PSR-16](https://www.php-fig.org/psr/psr-16) - Simple Cache
626ccdf4f0SGreg Roach* [PSR-17](https://www.php-fig.org/psr/psr-17) - HTTP Factories
636ccdf4f0SGreg Roach
64cb55cd99SGreg RoachWe do not currently use [PSR-3 (logging)](https://www.php-fig.org/psr/psr-3) - but we plan to do so in the future.
656ccdf4f0SGreg Roach
666ccdf4f0SGreg Roach## Introduction
67fac25c68SRico Sonntag
68fac25c68SRico Sonntag**webtrees** is the web's leading online collaborative genealogy application.
69fac25c68SRico Sonntag
70fac25c68SRico Sonntag* It works from standard GEDCOM files, and is therefore compatible with every
71fac25c68SRico Sonntagmajor desktop application.
72fac25c68SRico Sonntag* It aims to to be efficient and effective by using the right combination of
73fac25c68SRico Sonntagthird-party tools, design techniques and open standards.
74fac25c68SRico Sonntag
75fac25c68SRico Sonntag**webtrees** allows you to view and edit your genealogy on your website. It has
76e667f3d4SGreg Roachfull editing capabilities, full privacy functions, and supports imedia such as
77fac25c68SRico Sonntagphotos and document images. As an online program, it fosters extended family
78fac25c68SRico Sonntagparticipation and good ancestral recording habits, as it simplifies the process
79fac25c68SRico Sonntagof collaborating with others working on your family lines. Your latest information
80fac25c68SRico Sonntagis always on your web site and available for others to see, defined by viewing
81fac25c68SRico Sonntagrules you set. For more information and to see working demos, visit
82cdc90107SGreg Roach[webtrees.net](https://webtrees.net/).
83fac25c68SRico Sonntag
84fac25c68SRico Sonntag**webtrees** is Open Source software that has been produced by people from many
85fac25c68SRico Sonntagcountries freely donating their time and talents to the project. All service,
86fac25c68SRico Sonntagsupport, and future development is dependent on the time developers are willing
87fac25c68SRico Sonntagto donate to the project, often at the expense of work, recreation, and family.
88fac25c68SRico SonntagBeyond the few donations received from users, developers receive no compensation
89fac25c68SRico Sonntagfor the time they spend working on the project. There is also no outside source
90fac25c68SRico Sonntagof revenue to support the project. Please consider these circumstances when
91fac25c68SRico Sonntagmaking support requests and consider volunteering your own time and skills to make
92fac25c68SRico Sonntagthe project even stronger and better.
93fac25c68SRico Sonntag
94fac25c68SRico Sonntag
956ccdf4f0SGreg Roach## System requirements
96fac25c68SRico Sonntag
97fac25c68SRico SonntagTo install **webtrees**, you need:
98fac25c68SRico Sonntag
993606202eSDavid Drury* A webserver. Apache, NGINX and IIS are the most common types. There are no
1003606202eSDavid Drury requirements to use a specific type or version.
101fac25c68SRico Sonntag* Approximately 65MB of disk space for the application files, plus whatever is
102e667f3d4SGreg Roach  needed for your media files, GEDCOM files and database.
1033606202eSDavid Drury* PHP 7.0 or later.  Servers with PHP 5.3 - 5.6 should use **webtrees** 1.7.
1043606202eSDavid Drury  Servers with PHP 5.2 should use **webtrees** 1.4.
1053606202eSDavid Drury   * PHP should be configured with the following libraries:
106f0195b90SDavid Drury     * PDO and pdo_mysql to enable access to MySQL. These are enabled by default
107f0195b90SDavid Drury     on most hosts. See [http://php.net/pdo](http://php.net/pdo),
108f0195b90SDavid Drury     * php\_gd(2) for images
109f0195b90SDavid Drury     * PHP_XML for reports.
110fac25c68SRico Sonntag   * PHP should be configured to allow sufficient server resources (memory and
111fac25c68SRico Sonntag     execution time) for the size of your system. Typical requirements are:
112e667f3d4SGreg Roach      * Small systems (500 individuals): 16–32 MB, 10–20 seconds
113e667f3d4SGreg Roach      * Medium systems (5,000 individuals): 32–64 MB, 20–40 seconds
114e667f3d4SGreg Roach      * Large systems (50,000 individuals): 64–128 MB, 40–80 seconds
115f0195b90SDavid Drury* MySQL or MariaDB. Note that **webtrees** can share a single database
1163606202eSDavid Drury  with other applications, by choosing a unique table prefix during setup.
117fac25c68SRico Sonntag  If the number of databases is not restricted, you can set up a database purely
118fac25c68SRico Sonntag  for use by **webtrees** and create a separate user and password for only
119fac25c68SRico Sonntag  your genealogy.
1203606202eSDavid Drury
1213606202eSDavid Drury
1226ccdf4f0SGreg Roach  ## Internet browser compatibility
1233606202eSDavid Drury
1243606202eSDavid Drury  **webtrees** supports the use of most current browsers such as Edge, Firefox,
1253606202eSDavid Drury  Chrome, and Safari. We will do our best to support the current versions of others
126f0195b90SDavid Drury  such as Opera and Internet Explorer, however note that versions of Internet Explorer
127f0195b90SDavid Drury  prior to IE11 do not work with **webtrees**. We strongly recommend anyone using an
1283606202eSDavid Drury  obsolete browser to upgrade as soon as possible. We are also aware that Internet
1293606202eSDavid Drury  Explorer provides poor RTL language support generally, so cannot recommend it for
130da644f9cSMatthew Noorenberghe  sites requiring RTL languages.
131fac25c68SRico Sonntag* To view sites that contain both left-to-right and right-to-left text (e.g.
132fac25c68SRico Sonntag  English data on Hebrew pages), you will need to use a browser that provides
1333606202eSDavid Drury  support for the HTML5 **dir="auto"** attribute. At present, neither Edge
134823e27edSEric Wolf  nor Internet Explorer support this.
135fac25c68SRico Sonntag
136fac25c68SRico Sonntag
1376ccdf4f0SGreg Roach## Installation
138fac25c68SRico Sonntag
1393606202eSDavid DruryOnce the system requirements are met, perform the following steps
140fac25c68SRico Sonntag
14136745faeSGreg Roach1. Download the latest stable version from [github.com](https://github.com/fisharebest/webtrees/releases/latest)
1423606202eSDavid Drury2. Unzip the files and upload them to an empty folder on your web server.
143fac25c68SRico Sonntag3. Open your web browser and type the URL for your **webtrees** site (for example,
144f0195b90SDavid Drury   ``http://www.yourserver.com/webtrees`` into the address bar.
145fac25c68SRico Sonntag4. The **webtrees** setup wizard will start automatically. Simply follow the steps,
146f0195b90SDavid Drury   answering each question as you proceed.
147fac25c68SRico Sonntag
148fac25c68SRico SonntagThat's it!
149fac25c68SRico Sonntag
1503606202eSDavid DruryHowever, before you can use **webtrees**, you need at least one GEDCOM
1513606202eSDavid Drury(family tree) file. If you have been doing your research using a desktop program
152243bf6b4SGreg Roachsuch as Family Tree Maker, you can use it's “save as GEDCOM” function to create
153fac25c68SRico Sonntaga GEDCOM file. If you are starting from scratch, then **webtrees** can create a
1542b70c904SGreg RoachGEDCOM file for you.
155fac25c68SRico Sonntag
156f0195b90SDavid DruryOn successful installation you will be taken to the
1573606202eSDavid Drury ``Control panel`` -> ``Manage family trees``  page where you can:
158fac25c68SRico Sonntag * UPLOAD a GEDCOM file from your local machine
159fac25c68SRico Sonntag * ADD a GEDCOM file from your server, (if your GEDCOM file is too large to upload,
160fac25c68SRico Sonntag   you can copy it to the webtrees/data folder, and load it from there)
161fac25c68SRico Sonntag * CREATE a new, empty GEDCOM file
162fac25c68SRico Sonntag
163fac25c68SRico SonntagThere are *lots* of configuration options. You'll probably want to review the
164fac25c68SRico Sonntagprivacy settings first. Don't worry too much about all the other options - the
165fac25c68SRico Sonntagdefaults are good for most people. If you get stuck, there's lots of built-in
166cdc90107SGreg Roachhelp and you can get friendly advice from the [help](https://webtrees.net/forums)
167fac25c68SRico Sonntagforum.
168fac25c68SRico Sonntag
169fac25c68SRico Sonntag
1706ccdf4f0SGreg Roach## Upgrading
171b4ef7f82SRico Sonntag
172fac25c68SRico SonntagUpgrading **webtrees** is quick and easy. It is strongly recommended that you
173fac25c68SRico Sonntagupgrade your installation whenever a new version is made available. Even minor
174fac25c68SRico Sonntag**webtrees** version updates usually contain a significant number of bug fixes
1753606202eSDavid Druryas well as interface improvements and program enhancements.
176fac25c68SRico Sonntag
177f0195b90SDavid Drury* **Automatic upgrade**
178f0195b90SDavid Drury
1793606202eSDavid Drury  **webtrees** has an automatic upgrade facility. An administrator upon logging in
1803606202eSDavid Drurywill receive notification when a new version is available and an option to start
1813606202eSDavid Drurythe automatic upgrade. If for some reason the automatic upgrade should fail
1823606202eSDavid Drurythen a manual upgrade should be performed.
1833606202eSDavid Drury
184f0195b90SDavid Drury* **Manual upgrade**
185f0195b90SDavid Drury
186fac25c68SRico Sonntag  1. Now would be a good time to make a [backup](#backup).
187fac25c68SRico Sonntag  2. Download the latest version of **webtrees** available from
188cdc90107SGreg Roach   [webtrees.net](https://webtrees.net/)
189243bf6b4SGreg Roach  3. While you are in the middle of uploading the new files,
190fac25c68SRico Sonntag   a visitor to your site would encounter a mixture of new and old files.  This
191b3a775f6SGreg Roach   could cause unpredictable behavior or errors.  To prevent this, create the
192fac25c68SRico Sonntag   file **data/offline.txt**.  While this file exists, visitors will see a
193243bf6b4SGreg Roach   “site unavailable - come back later” message.
194fac25c68SRico Sonntag  4. Unzip the .ZIP file, and upload the files to your web server, overwriting the existing files.
195fac25c68SRico Sonntag  5. Delete the file **data/offline.txt**
196fac25c68SRico Sonntag
1973606202eSDavid Drury
1986ccdf4f0SGreg Roach### Note for Macintosh users
199b4ef7f82SRico Sonntag
200fac25c68SRico SonntagStep 4 assumes you are using a copy tool that **merges** directories rather than
201b3a775f6SGreg Roachreplaces them. (**Merge** is standard behavior on Windows and Linux.) If you use
202fac25c68SRico Sonntagthe Macintosh Finder or other similar tool to perform step 3, it will **replace**
203fac25c68SRico Sonntagyour configuration, media and other directories with the empty/default ones from
204fac25c68SRico Sonntagthe installation. This would be very bad (but you did take a backup in step 1,
205fac25c68SRico Sonntagdidn't you!). Further details and recommendations for suitable tools can be found
206fac25c68SRico Sonntagby searching [google.com](http://google.com).
207fac25c68SRico Sonntag
208fac25c68SRico Sonntag
2096ccdf4f0SGreg Roach### Note for anyone using custom code (modules, themes, etc.).
210b4ef7f82SRico Sonntag
211fac25c68SRico SonntagIt is **very likely** that your custom code will not work when you upgrade
212fac25c68SRico Sonntag**webtrees**.
213fac25c68SRico Sonntag
214fac25c68SRico Sonntag**We recommend that you disable all custom code before you apply the upgrade.**
215fac25c68SRico Sonntag
2163606202eSDavid DruryDisable custom modules, switch over to a standard theme, and remove any code “hacks”.
2173606202eSDavid DruryOnce the upgrade is complete and you are satisfied that your site is fully operational contact
2183606202eSDavid Drurythe source of those modules or themes for a new version.
219fac25c68SRico Sonntag
220fac25c68SRico Sonntag
2216ccdf4f0SGreg Roach### General note
222b4ef7f82SRico Sonntag
223fac25c68SRico SonntagDepending on the changes in the new files, your browser configuration
224fac25c68SRico Sonntagand possibly other factors, it is always wise to clear both the **webtrees** cache
225fac25c68SRico Sonntagand your browser cache immediately after the upgrade is completed. The **webtrees**
2263606202eSDavid Drurycache can be cleared simply by going to ``Control Panel`` -> ``Family Trees`` ->
2273606202eSDavid Drury``Clean-up data folder`` and deleting the cache.
228fac25c68SRico Sonntag
229fac25c68SRico SonntagIf you have any problems or questions, help is available on the
2304e53541cSKirill Uksusov[webtrees forum](https://www.webtrees.net/index.php/en/forum).
231fac25c68SRico Sonntag
2326ccdf4f0SGreg Roach## Building and developing
233bd82e704SDavid Drury
234bd82e704SDavid DruryIf you want to build webtrees from source, or modify the code, you'll need to install
235bd82e704SDavid Drurya couple of tools first.
236bd82e704SDavid Drury
237bd82e704SDavid DruryYou will need [composer](https://getcomposer.org/) to install the PHP dependencies.
238bd82e704SDavid DruryThen run this command::
239bd82e704SDavid Drury
240bd82e704SDavid Drury* php composer.phar install
241bd82e704SDavid Drury
242bd82e704SDavid DruryYou will need [npm](https://www.npmjs.com/get-npm) to install the Javascript dependencies.
243bd82e704SDavid DruryThen run the commands:
244bd82e704SDavid Drury
245bd82e704SDavid Drury* npm install
2469845ccc6SRico Sonntag* npm run production
247bd82e704SDavid Drury
248bd82e704SDavid DruryYou will need to re-run the second of these any time you modify the file `webtrees.js`.
249fac25c68SRico Sonntag
2506ccdf4f0SGreg Roach## Gedcom (family tree) files
251fac25c68SRico Sonntag
2523606202eSDavid DruryWhen you ADD or IMPORT a family tree (GEDCOM) file in **webtrees** the
2533606202eSDavid Drurydata from the file is transferred to the database tables. The file itself
254f0195b90SDavid Druryremains in the **webtrees/data** folder and is no longer used or required
255f0195b90SDavid Druryby **webtrees**. Any subsequent editing of the **webtrees** data
2563606202eSDavid Drurywill not change this file
257fac25c68SRico Sonntag
258fac25c68SRico SonntagWhen or if you change your genealogy data outside of **webtrees**, it is not
259fac25c68SRico Sonntagnecessary to delete your GEDCOM file or database from **webtrees** and start
260fac25c68SRico Sonntagover. Follow these steps to update a GEDCOM that has already been imported:
261fac25c68SRico Sonntag
2623606202eSDavid Drury* Go to ``Control panel`` -> ``Manage family trees`` On the line relating to this particular family tree (GEDCOM)
2633606202eSDavid Drury  file (or a new one) select IMPORT.
264243bf6b4SGreg Roach* Take careful note of the media items option (_“If you have created media objects
265ed1bbedbSGreg Roach  in **webtrees**, and have edited your data off-line using software that
266fac25c68SRico Sonntag  deletes media objects, then tick this box to merge the current media objects
267243bf6b4SGreg Roach  with the new GEDCOM.”_) In most cases you should leave this box **UNCHECKED**.
268243bf6b4SGreg Roach* Click “SAVE”. **webtrees** will validate the GEDCOM again before importing.
269fac25c68SRico Sonntag  During this process, **webtrees** copies your entire family tree (GEDCOM file)
270fac25c68SRico Sonntag  to a 'chunk' table within your database. Depending on the coding of your file,
271fac25c68SRico Sonntag  its file size and the capabilities of your server and the supporting software,
272fac25c68SRico Sonntag  this may take some time. **No progress bar will show while the data is being
273fac25c68SRico Sonntag  copied** and should you navigate away from this page, the process is suspended.
274fac25c68SRico Sonntag  It will start again when you return to the Family Tree management page.
275fac25c68SRico Sonntag
276fac25c68SRico Sonntag
2776ccdf4f0SGreg Roach### Gedcom file Formats
278fac25c68SRico Sonntag
279fac25c68SRico SonntagEvery Family History program has its own method of creating GEDCOM files, and
280fac25c68SRico Sonntagdiffering output format options to select from. **webtrees'** import routines
281fac25c68SRico Sonntagcan read many different formats, but not necessarily all. If your software has
282243bf6b4SGreg Roacha “UTF8” option you should always use that. However, **webtrees** has been
283fac25c68SRico Sonntagtested with these alternative formats:
284fac25c68SRico Sonntag
285fac25c68SRico Sonntag* ANSI
286fac25c68SRico Sonntag   * imports OK, but is slow due to the translation into UTF8 as part
287fac25c68SRico Sonntag     of the import process.
288fac25c68SRico Sonntag* MAC
289fac25c68SRico Sonntag   * imports OK, but is slow due to the translation into UTF8 as part
290fac25c68SRico Sonntag     of the import process.
291fac25c68SRico Sonntag* DOS
292fac25c68SRico Sonntag   * imports OK, but is slow due to the translation into UTF8 as part
293fac25c68SRico Sonntag     of the import process.
294fac25c68SRico Sonntag* ANSEL
295243bf6b4SGreg Roach   * currently will not import. Gives warning *Error: cannot convert
296243bf6b4SGreg Roach     GEDCOM file from ANSEL encoding to UTF-8 encoding*. Later releases
2973606202eSDavid Drury     of **webtrees** may include the facility to translate from ANSEL to UTF8,
2983606202eSDavid Drury     but for now a standalone utility [is available here](https://dev.webtrees.net/ansel/)
2993606202eSDavid Drury     and should be used to convert the format to UTF-8 prior to importing.
300fac25c68SRico Sonntag
301fac25c68SRico Sonntag
3026ccdf4f0SGreg Roach## Security
303fac25c68SRico Sonntag
304fac25c68SRico Sonntag**Security** in _webtrees_ means ensuring your site is safe from unwanted
305fac25c68SRico Sonntagintrusions, hacking, or access to data and configuration files. The developers
306fac25c68SRico Sonntagof _webtrees_ regard security as an extremely important part of its development
307fac25c68SRico Sonntagand have made every attempt to ensure your data is safe.
308fac25c68SRico Sonntag
3093606202eSDavid DruryThe area most at risk of intrusion would be the **/data** folder that contains your
310fac25c68SRico Sonntagconfig.ini.php file, and various temporary files. If you are concerned there
311bd82e704SDavid Drurymay be a risk there is a very simple test you can do: try to fetch the file
312bd82e704SDavid Druryconfig.ini.php by typing **``url_to_your_server/data/config.ini.php``** in your web
313fac25c68SRico Sonntagbrowser.
314fac25c68SRico Sonntag
315243bf6b4SGreg RoachThe most likely result is an “access denied” message like this:
316fac25c68SRico Sonntag
317fac25c68SRico Sonntag    Forbidden
318fac25c68SRico Sonntag
319f0195b90SDavid Drury    You don't have permission to access /data/config.ini.php on this server.
320fac25c68SRico Sonntag
321fac25c68SRico SonntagThis indicates that the protection built into **webtrees** is working, and no
322fac25c68SRico Sonntagfurther action is required.
323fac25c68SRico Sonntag
324fac25c68SRico SonntagIn the unlikely event you do fetch the file (you will just see a semicolon),
325fac25c68SRico Sonntagthen that protection is not working on your site and you should take some further
326fac25c68SRico Sonntagaction.
327fac25c68SRico Sonntag
3283606202eSDavid DruryIf your server runs PHP in CGI mode, then change the permission of the **/data**
3293606202eSDavid Druryfolder to 700 instead of 777. This will block access to the httpd process,
330fac25c68SRico Sonntagwhile still allowing access to PHP scripts.
331fac25c68SRico Sonntag
332fac25c68SRico SonntagThis will work for perhaps 99% of all users. Only the remaining 1% should consider
3333606202eSDavid Drurythe most complex solution, moving the **/data** folder out of accessible web
334fac25c68SRico Sonntagspace. (**_Note:_** In many shared hosting environments this is not an option anyway.)
335fac25c68SRico Sonntag
336fac25c68SRico SonntagIf you do find it necessary, following is an example of the process required:
337fac25c68SRico Sonntag
3383606202eSDavid DruryIf your home folder is something like **/home/username**,
3393606202eSDavid Druryand the root folder for your web site is **/home/username/public_html**,
3403606202eSDavid Druryand you have installed **webtrees** in the **public_html/webtrees** folder,
3413606202eSDavid Drurythen you would create a new **data** folder in your home folder at the same
3423606202eSDavid Drurylevel as your public_html folder, such as **/home/username/private/data**,
343fac25c68SRico Sonntagand place your GEDCOM (family tree) file there.
344fac25c68SRico Sonntag
3453606202eSDavid DruryThen change the **Data folder** setting on the ``Control panel`` ->
3463606202eSDavid Drury``Website`` -> ``Website preferences`` page from the default **data/** to the new
347fac25c68SRico Sonntaglocation **/home/username/private/data**
348fac25c68SRico Sonntag
349fac25c68SRico SonntagYou will have **two** data directories:
350fac25c68SRico Sonntag
351fac25c68SRico Sonntag* [path to webtrees]/data - just needs to contain config.ini.php
352fac25c68SRico Sonntag* /home/username/private/data - contains everything else
353fac25c68SRico Sonntag
354fac25c68SRico Sonntag
3556ccdf4f0SGreg Roach## Backup
356fac25c68SRico Sonntag
357fac25c68SRico SonntagBackups are good. Whatever problem you have, it can always be fixed from a good
358fac25c68SRico Sonntagbackup.
359fac25c68SRico Sonntag
3603606202eSDavid DruryTo make a backup of **webtrees**, you need to make a copy of the following
361fac25c68SRico Sonntag
3623606202eSDavid Drury1. The files in the *webtrees/data* folder.
3633606202eSDavid Drury2. The files in the *webtrees/media* folder.
364fac25c68SRico Sonntag3. The tables in the database. Freely available tools such as
365fac25c68SRico Sonntag   [phpMyAdmin](http://www.phpmyadmin.net) allow you to do this in one click.
366fac25c68SRico Sonntag
367fac25c68SRico SonntagRemember that most web hosting services do NOT backup your data, and this is
368fac25c68SRico Sonntagyour responsibility.
369