Download the PHP package servergrove/servergrovelocalebundle without Composer

On this page you can find all versions of the php package servergrove/servergrovelocalebundle. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package servergrovelocalebundle

ServerGroveLocaleBundle

This bundle provides a set of Twig functions to display browser culture codes.

Build Status

Installation

You need to follow the steps according to your Symfony version.

Specifics to Symfony 2.0

Deps

First you need to add the bundle to your deps file

and then, run the vendors script to download the bundle source

Autoload

The app must know where to look for our bundle classes. Adding the following line to the autoload file will do it.

Specifics to Symfony 2.1

Enable the bundle

Now, we need to tell our application kernel to enable the bundle. For this we need to add a bundle instance to the kernel bundles.

Configuration

Use the default settings:

Or configure it according to your requirements:

Displaying one flag

There are three helpful functions for displaying a single flag.

The flag function

The flag function displays only the flag image:

The result would be:

You can also use a third param with options.

Attributes

One of the available options is attrs, which allows to add attributes to the image.

If you set an array for a specific attribute, you would have to specify for which locale the attribute is.

The path_flag function

This bundle provides a function to display the flags with a link to a specific route.

The result would be:

The domain_flag function

It also provides a function to link the flag to a configured domain

The result would be:

Displaying multiple configured flags

With this section, you will be able to display multiple flags with just one function.

The flags function

The flags function is the equivalent for the flag function for multiple images.

The result would be:

The path_flags function

The path_flags function is the equivalent for the path_flag function for multiple images. The _locale param for the route is set automatically.

The result would be:

The domains_flags function

The domains_flags function is the equivalent for the domains_flags function for multiple images.

The result would be:


All versions of servergrovelocalebundle with dependencies

PHP Build Version
Package Version
Requires kriswallsmith/assetic Version >=1.0
symfony/config Version ~2.1
symfony/dependency-injection Version ~2.1
symfony/finder Version ~2.1
symfony/http-kernel Version ~2.1
twig/twig Version >=1.4,<2.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package servergrove/servergrovelocalebundle contains the following files

Loading the files please wait ....