fourlabs/world-universities-bundle

Symfony ChoiceType listing the world's universities

0.2.0 2017-04-20 10:11 UTC

This package is auto-updated.

Last update: 2024-11-22 07:39:01 UTC


README

Symfony ChoiceType listing the world's universities

StyleCI GitHub license

Installation

Download the Bundle

Open a command console, enter your project directory and execute the following command to download the latest version of this bundle:

$ composer require fourlabs/world-universities-bundle

This command requires you to have Composer installed globally, as explained in the installation chapter of the Composer documentation.

Enable the Bundle

Then, enable the bundle by adding the following line in the app/AppKernel.php file of your project:

<?php
// app/AppKernel.php

public function registerBundles()
{
    $bundles = array(
        // ...
        new FL\WorldUniversitiesBundle\FlWorldUniversitiesBundle(),
    );
}

Usage

Example
$builder->add('university', WorldUniversitiesType::class, [
    'required' => true,
]);

Configuration

Example of configuration in app/config.yml:

fl_world_universities:
    path: "%kernel.root_dir%/Resources/WorldUniversities"
    source: "https://raw.githubusercontent.com/endSly/world-universities-csv/master/world-universities.csv"

Download / update list of universities

php bin/console fl:world-universities:update

License

MIT