2.11.1releasedPage 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.x2.1.x2.2.x2.3.x2.4.x2.5.x2.6.02.6.12.6.22.6.32.6.42.6.52.6.62.6.72.6.82.6.92.6.102.6.11
NoNo2.22.11.12.11.12.11.12.11.12.11.12.11.12.11.12.11.12.11.12.11.12.11.12.11.12.11.12.11.12.11.1

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 localisation title and handle 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 if Operating mode is set to Relax. 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

  1. Upload the 'page_lhandles' folder found in this archive to your Symphony 'extensions' folder.
  2. Enable it by selecting the "Page LHandles" under System -> Extensions, choose Enable from the with-selected menu, then click Apply.
  3. You can now add localised Titles and Handles to any Symphony Page.

3 Usage

  1. Make sure that Frontend Localisation extension is Enabled. Read it's Readme if you don't know what it represents.
  2. Go to Blueprints -> Pages. Create a new page or edit an existing one.
  3. 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).
  4. 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

  • 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