modif comtabilite
This commit is contained in:
@@ -6,7 +6,15 @@
|
||||
|
||||
# Installation
|
||||
|
||||
Installing the Language Selector plugin can be done only manually for this moment. GPM installation is not yet available
|
||||
Installing the Language Selector plugin can be done in one of two ways. GPM (Grav Package Manager) installation method enables you to quickly and easily install the plugin with a simple terminal command, while the manual method enables you to do so via a zip file or GIT.
|
||||
|
||||
## GPM Installation (Preferred)
|
||||
|
||||
The simplest way to install this plugin is via the [Grav Package Manager (GPM)](http://learn.getgrav.org/advanced/grav-gpm) through your system's Terminal (also called the command line). From the root of your Grav install type:
|
||||
|
||||
bin/gpm install language-selector
|
||||
|
||||
This will install the Language Selector plugin into your `/user/plugins` directory within Grav. Its files can be found under `/yoursite/user/plugins/language-selector`.
|
||||
|
||||
## Manual Installation (Download)
|
||||
|
||||
@@ -28,7 +36,20 @@ This will clone this repository into the _language-selector_ folder.
|
||||
|
||||
# Usage
|
||||
|
||||
The `Language Selector` plugin doesn't require any configuration. You do however need to add the included Twig partials template into your own theme somewhere you want the available languages to be displayed.
|
||||
## 1. Define the supported languages
|
||||
|
||||
In `system.yaml`, add the supported languages in `languages.supported` parameter.
|
||||
|
||||
Example:
|
||||
|
||||
languages:
|
||||
supported:
|
||||
- fr
|
||||
- en
|
||||
|
||||
## 2. Integration
|
||||
|
||||
You do need to add the included Twig partials template into your own theme somewhere you want the available languages to be displayed.
|
||||
|
||||
```
|
||||
{% include 'partials/language-selector.html.twig' %}
|
||||
@@ -44,7 +65,9 @@ Copy the template file [language-selector.html.twig](templates/partials/language
|
||||
|
||||
You can now edit the override and tweak it however you prefer.
|
||||
|
||||
## Usage of the `hreflang` partial
|
||||
`language-selector` need jQuery (1.8 -> later) to display dropdown language menu.
|
||||
|
||||
## 3. Usage of the `hreflang` partial
|
||||
|
||||
A second template is available for `hreflang` annotations in the header of the page. In order to emit language annotations for the available languages of a page you need to add the corrsponding Twig partial template into the `<head>` section of your page, which can typically be found in `base.html.twig`:
|
||||
|
||||
@@ -95,7 +118,7 @@ pages:
|
||||
|
||||
# Contribute
|
||||
|
||||
# Languages
|
||||
## Languages
|
||||
|
||||
For Administration panel, `Language Selector` is available in English and French. You could contribute for another languages.
|
||||
|
||||
|
||||
Reference in New Issue
Block a user