2017 © Pedro Peláez
 

symfony-bundle locale-bundle

Symfony RKLocaleBundle

image

rk/locale-bundle

Symfony RKLocaleBundle

  • Saturday, September 17, 2016
  • by Yoann
  • Repository
  • 1 Watchers
  • 0 Stars
  • 418 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 1 Versions
  • 0 % Grown

The README.md

RkLocaleBundle

In construction.., (*1)

Installation

Add RkLocaleBundle by Composer, (*2)

# composer.json
require : {
    "rk/locale-bundle": "dev-master",
}

Register the bundle in app/AppKernel.php:, (*3)

public function registerBundles()
{
    return array(
        // ...
        new Rk\LocaleBundle\RkLocaleBundle(),
    );
}

Add Route at the start routing file, (*4)

# app/config/routing.yml
mon_annonce_locale:
    resource: "@MonAnnonceLocaleBundle/Resources/config/routing.yml"
    prefix:   /

Configuration

# app/config/parameter.yml
rk_locale:
    langs: [en,fr]
    default_target_path: rk_webmail_public_index
    domain: example.com

And in routing file add each route, (*5)

# app/config/parameter.yml
prefix:   /{_locale}/
requirements:
    _locale: en|fr

Example in twig ------- ```twig {{ render(controller('RkLocaleBundle:Render:listFlag', { 'route' : app.request.attributes.get('_route') })) }}

The Versions

17/09 2016

dev-master

9999999-dev

Symfony RKLocaleBundle

  Sources   Download

The Requires

 

The Development Requires

by Yoann Reversat

locale management translate