2.11.3releasedPage LHandles
Offers multilingual support for localised page handles in browser URL.
Clone URLhttps://github.com/DeuxHuitHuit/page_lhandles.git
Add as a submodulegit submodule add https://github.com/DeuxHuitHuit/page_lhandles.git extensions/page_lhandles --recursive
Compatibility
2.x.x | 2.1.x | 2.2.x | 2.3.x | 2.4.x | 2.5.x | 2.6.x | 2.7.0 | 2.7.1 | 2.7.2 | 2.7.3 | 2.7.4 | 2.7.5 | 2.7.6 | 2.7.7 | 2.7.8 | 2.7.9 | 2.7.10 |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
No | No | 2.2 | 2.11.3 | 2.11.3 | 2.11.3 | 2.11.3 | 2.11.3 | 2.11.3 | 2.11.3 | 2.11.3 | 2.11.3 | 2.11.3 | 2.11.3 | 2.11.3 | 2.11.3 | 2.11.3 | 2.11.3 |
Readme
Page LHandles
Offers support to localise Page titles and Handles.
1 Features
- Offers support for translating Page handles in current supported languages (from Frontend Localisation).
- Adds a button in
System -> Preferences
to automatically fill empty localisationtitle
andhandle
inputs for Pages. - Offers a DS which outputs the current-page handle and title in all supported languages.
- Overrides the navigation template Datasources to output the extra information.
- URL Router compatible. URLs like
www.site.com/clients/_param1_/projects/_param2_/
are possible ifOperating mode
is set toRelax
. See Preferences page.
Old XML for a navigation Datasource:
<page handle="_HandleHere_" id="_IDhere_">
<name>_TitleHere_</name>
...
</page>
New XML supplies handle and title for the current page according to current-language:
<page handle="_SymphonyHandleHere_" id="_IDhere_">
<name>_TitleHere_</name>
<item lang="_CurrentLanguageHere_" handle="_LocalisedHandleHere_">_LocalisedTitleHere_</item>
...
</page>
Note
- On enabling / installing the extension, any Datasource with source set to 'navigation' will be edited to include the new localised template.
- On disabling / uninstalling the extension, any Datasource with source set to 'navigation' will be edited to include the original Symphony template.
2 Installation
- Upload the 'page_lhandles' folder found in this archive to your Symphony 'extensions' folder.
- Enable it by selecting the "Page LHandles" under System -> Extensions, choose Enable from the with-selected menu, then click Apply.
- You can now add localised Titles and Handles to any Symphony Page.
3 Usage
- Make sure that Frontend Localisation extension is Enabled. Read it's Readme if you don't know what it represents.
- Go to Blueprints -> Pages. Create a new page or edit an existing one.
- Fill the available localisation fields. Every Localised URL Handle filled will become accessible from the browser. The empty ones will redirect to 404 (Page Not Found).
- Add the "PLH Page" Datasource to your page. Go to
?debug
and feel the difference.
3.1 Example
Take 2 pages and 3 languages: Romanian (RO), English (EN) and French (FR).
No. | Parent | Sym Title | Sym Handle | RO Title | RO Handle | EN Title | EN Handle | FR Title | FR Handle | Parameters ----|------------|------------|------------|------------|------------|----------|-----------|------------|------------|----------- 1. | - | Sym Events | sym-events | Evenimente | evenimente | Events | events | Evenements | evenements | - 2. | sym-events | Sym Single | sym-single | Single | single | Single | single | Single | single | event-single
All these 3 URLs will request "Sym Single" Page:
- www.example.com/ro/evenimente/single/primul-titlu ---> sym-events/sym-single/primul-titlu
- www.example.com/en/events/single/first-title --------> sym-events/sym-single/first-title
- www.example.com/fr/evenements/single/premier-titre --> sym-events/sym-single/premier-titre
Version history
Symphony 2.3 to 2.x.x
- Wrap constants in string
Symphony 2.3 to 2.x.x
- Fix SQL clause for proper soriting in MySQL 5.7
Symphony 2.3 to 2.x.x
- Fix regression where localized url did not worked any more
Symphony 2.3 to 2.x.x
- Properly upgrade Nav data sources
Symphony 2.3 to 2.x.x
- Fix for PHP 7 support
Symphony 2.3 to 2.x.x
- Adds PHP 7 support
Symphony 2.3.4 to 2.x.x
- Updated compatibility info
Symphony 2.3.4 to 2.5.x
- Symphony 2.5 compatibility.
- Multilingual Data Source: Output every page handles in every languages. Keep current first.
- Automatically create handles when field is empty
- UI: Remove white space between title and handle
Symphony 2.3.4 to 2.5.x
- Fixed
PLH : Page
datasource output.
Requires Symphony 2.3.4
- Updated for Frontend Localisation 2.5 compatibility.
Requires Symphony 2.3
- Improved Datasource editing.
- Safer queries in driver.
Requires Symphony 2.3
- Frontend Localisation 1.6 compatibility
Requires Symphony 2.3
- Symphony 2.3 compatibility.
- Added compatibility for URL Router.
- Introduces $op_mode:
Strict
= Recommended & Default.Relax
= URL Router compatibility.
- Added more safety check to URL parsing.
- Improved
plh-utility.xsl
internals.
Requires Symphony 2.2.x
- Compatibility release for Frontend Localisation 1.0