Skip to content

Commit 42bcc88

Browse files
authored
Fixed headers
1 parent b0e6d0b commit 42bcc88

1 file changed

Lines changed: 12 additions & 12 deletions

File tree

README.md

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# LanguageSwitcher
22
Laravel Language Switcher Package
33

4-
##Description
4+
## Description
55
This package provides an easy to work with language switcher that you can use in your projects with a wide variety of config options.
66
It automatically bootstraps to your Laravel project, sets the locale, and switches the languages when needed.
77

@@ -10,7 +10,7 @@ whereas the default provided config will allow you to use the package right afte
1010

1111
I know it may seem very simple and perhaps over-complicated, but you don't have to waste time and thought process on the simple things.
1212

13-
##Installation
13+
## Installation
1414
To install the package, just run composer require ied3vil/language-switcher and follow the instructions.
1515
If you want to add it to your composer.json manually, just open composer.json and search for the "autoload" field and add
1616
```
@@ -50,7 +50,7 @@ Make sure you include the middleware at the end of the array, because it is reli
5050

5151
You are now ready to use the language switcher!
5252

53-
##Usage
53+
## Usage
5454

5555
The default language set in your app.locale config value will be set. You can find it in the `config/app.php` config file.
5656

@@ -67,7 +67,7 @@ For more information on how to do this, please consult [Laravel's Documentation]
6767

6868
Alternatively, you can set this yourself using your own routes, just set the session value `'language'` to the new locale and redirect.
6969

70-
##Configuration
70+
## Configuration
7171
The package ships with quite a few configuration options:
7272
```
7373
return [
@@ -84,33 +84,33 @@ You are free to use any method to configure the package. Remember to use the pub
8484
To set options, you can use any of the following methods:
8585
1. Changing the config file `config/languageswitcher.php`, editing the values of the provided keys (recommended)
8686
2. Using laravel's runtime configuration helper - `Config::set()` | `config()->set()`, with the specification that you use the 'languageswitcher' preffix for the keys (eg. `languageswitcher.switchPath` for changing the switch path).
87-
#####Changing the switcher's route (default: lang/{language_flag})
87+
##### Changing the switcher's route (default: lang/{language_flag})
8888
* Config key: `languageswitcher.switchPath`
8989
* Default Value: `lang`
9090

9191
This config setting dynamically sets the route created in the package for switching the language.
92-
#####Changing store method - session | cookie (default: session)
92+
##### Changing store method - session | cookie (default: session)
9393
* Config key: `languageswitcher.store`
9494
* Default value: `session`
9595
* Accepted values: `session | cookie`
9696

9797
This config setting changes the storage method of the language flag.
9898
Default is session, but cookies with forever as expiry date can be used.
9999
Initially this was set up as a cookie with a configurable expiry date, but for obvious reasons it was set up to never expire.
100-
#####Changing the key where the language flag is stored (default: lang)
100+
##### Changing the key where the language flag is stored (default: lang)
101101
* Config key: `languageswitcher.key`
102102
* Default value: `language`
103103

104104
This config setting decides what key to be used when storing the language flag, to the session or cookie.
105-
#####Changing the redirect type (default: route redirect to '/')
105+
##### Changing the redirect type (default: route redirect to '/')
106106
* Config keys: `languageswitcher.redirect` and `languageswitcher.redirect_route`
107107
* Default value for `languageswitcher.redirect`: `route`
108108
* Accepted values: `route | back`
109109
* Default value for `languageswitcher.redirect_route`: `/`
110110

111111
When the `languageswitcher.redirect` config value is set to route, the user is redirected to the specified `languageswitcher.redirect_route` after the new language flag is set.
112112
Setting the `languageswitcher.redirect` to `back` will redirect the user back to the previous page after the new language flag is set.
113-
##Examples
113+
## Examples
114114
My preffered way to usage is this: I include the library, create my UI for switching the language, and start translating!
115115

116116
Example HTML:
@@ -122,7 +122,7 @@ Example HTML:
122122
</ul>
123123
```
124124
If you want to evidentiate the current selection language, you can use App::getLocale() or LanguageSwitcher::getCurrentLanguage().
125-
##Bugs/Issues/Improvements
125+
## Bugs/Issues/Improvements
126126
Feel free to use github for issues and suggesting improvements.
127-
##Additional Information
128-
You can find more information on regarding this package on my website, [www.ied3vil.com](http://www.ied3vil.com).
127+
## Additional Information
128+
You can find more information on regarding this package on my website, [www.ied3vil.com](http://www.ied3vil.com).

0 commit comments

Comments
 (0)