2017 © Pedro Peláez
 

library galleries

image

angel/galleries

  • Tuesday, August 26, 2014
  • by CharlesAV
  • Repository
  • 1 Watchers
  • 0 Stars
  • 8 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 1 Forks
  • 0 Open issues
  • 1 Versions
  • 0 % Grown

The README.md

Angel Galleries

This is a galleries module for the Angel CMS., (*1)

This module allows you to create multiple 'galleries', each with their own collection of images., (*2)

Installation

Add the following requirements to your composer.json file:, (*3)

"require": {
    "angel/galleries": "dev-master"
},

Issue a composer update to install the package., (*4)

Add the following service provider to your providers array in app/config/app.php:, (*5)

'Angel\Galleries\GalleriesServiceProvider',
'Intervention\Image\ImageServiceProvider'

Add the following alias to your aliases array in app/config/app.php:, (*6)

'Image'           => 'Intervention\Image\Facades\Image'

Issue the following commands:, (*7)

php artisan migrate --package="angel/galleries"  # Run the migrations
php artisan asset:publish                        # Publish the assets
php artisan config:publish angel/galleries       # Publish the config

Open up your app/config/packages/angel/core/config.php and add the galleries routes to the menu array:, (*8)

'menu' => array(
    'Pages'     => 'pages',
    'Menus'     => 'menus',
    'Galleries' => 'galleries', // <--- Add this line
    'Users'     => 'users',
    'Settings'  => 'settings'
),

...and the menu-linkable models to the linkable_models array:, (*9)

'linkable_models' => array(
    'Page'             => 'pages',
    'Gallery'          => 'galleries', // <--- Add this line
)

Open up your app/config/packages/angel/galleries/config.php and define your desired thumbnail settings. The default is:, (*10)

array(
    'thumbs' => array(
        't' => array(
            'width' => 75,
            'height' => 75,
            'crop' => 1,
            'enlarge' => 1,
            'path' => '/uploads/images/t/'
        ),
        's' => array(
            'width' => 150,
            'height' => 150,
            'crop' => 1,
            'enlarge' => 1,
            'path' => '/uploads/images/s/'
        ),
        'm' => array(
            'width' => 300,
            'height' => 300,
            'crop' => 0,
            'enlarge' => 1,
            'path' => '/uploads/images/m/'
        ),
        'l' => array(
            'width' => 600,
            'height' => 600,
            'crop' => 0,
            'enlarge' => 0,
            'path' => '/uploads/images/l/'
        )
    )
)

Finally, make sure you actually create the directories where the thumbnail images will be saved. These paths are relative to the /public/ folder (ex: /public/uploads/images/t/)., (*11)

The Versions

26/08 2014

dev-master

9999999-dev

  Sources   Download

The Requires

 

by Charles Konsor