Fixes#216Fixes#197
The exchange between browser and server transmits information about the client and its capabilities in headers - user agent, what it accepts, and (what interests us) language. The browser sends the language information in a header.
These values indicate that the browser accepts, for example, US English (en-us) or German (de-de).
We make use of this. The setup of FlatPress now starts automatically in the language of the user. The determined language will also be used as default language for the FlatPressblog and the administration area until the user defines a language himself.
For the setup the language files 'el-gr','es-es','fr-fr' are still missing.
Therefore I limited the automatic determination of the language to 'cs-cz', 'de-de', 'en-us', 'it-it', 'ja-jp', 'nl-nl', 'pt-br'. See #239
This closes issue #197
Please check if it works with php8.1. Tested with php 7.4
Update main.php
'el-gr','es-es','fr-fr' removed as browser language, because the FlatPress setup currently has no language files for it
Update lang.de-de.php
Update main.php
some code formatting