Skip to content
This repository has been archived by the owner on Jul 21, 2021. It is now read-only.

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
Martimiz committed May 19, 2016
1 parent 40e0d5e commit e2bdf81
Showing 1 changed file with 8 additions and 5 deletions.
13 changes: 8 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,5 @@
# LanguagePrefix module for SilverStripe CMS #

Rewrite of version 2.0. The Prefix is no longer a separate url param, but is extracted from the URLSegment instead.
This allows for greater flexibility - you can now optionally use urls without prefix for the default language.

*Note: this version should be backwards compatible with version 2.0. Please create an issue if you find any problems*

* Supports SilverStripe 3.1.x +
* For SilverStripe 3.0.x use version 1.0

Expand All @@ -17,12 +12,20 @@ Example:
www.mydomain.com/en/
www.mydomain.com/nl/

You can easily define your own prefix format. By default the locale (en_US, nl_NL, ...) is used.
Optionally you can leave out the prefix for the default language

## Changes in this version

This is a rewrite of version 2.0. The Prefix is no longer a separate url param, but is extracted from the URLSegment instead.
This allows for greater flexibility - you can now optionally use urls without prefix for the default language.

* $Prefix segment is stripped from the url rule (routes.yml)
* PrefixModelAsController::handleRequest() now handles extracting the prefix from the url, and shifts the url and other params if need be
* Optionally set `disable_prefix_for_default_lang` to remove the prefix from the default language

*Note: this version should be backwards compatible with version 2.0. Please create an issue if you find any problems*

## Usage

Setup and usage documentation: [docs/en/index.md](docs/en/index.md)
Expand Down

0 comments on commit e2bdf81

Please sign in to comment.