marcusamatos/jvslayout

There is no license information available for the latest version (1.0.0) of this package.

JvsLayout provides a suite of classes to layout manager.

Installs: 37

Dependents: 0

Suggesters: 0

Security: 0

Stars: 0

Watchers: 1

Forks: 0

Open Issues: 0

Type:zf-module

pkg:composer/marcusamatos/jvslayout

1.0.0 2015-03-12 02:25 UTC

This package is not auto-updated.

Last update: 2025-10-11 20:06:19 UTC


README

Introduction

JvsLayout change layout by route and uri

Requirements

  • Zend Framework 2

Instalation

Add "marcusamatos/jvslayout": "1.*" to composer.json and update

How to use

By Route Default:

return array(
    'router' => array(
        'routes' => array(
            'home' => array(
                'type' => 'Zend\Mvc\Router\Http\Literal',
                'options' => array(
                'route'    => '/',
                'defaults' => array(
                    'controller' => 'Application\Controller\Index',
                    'action'     => 'index',
                    'layout'     => 'layout/home'
                ),
            ),
        )
    )
);

By Config:

return array(
    'jvs-layout' => array(
        'uri' => array(
            '/news' => 'layout/news',
            '/admin*' => 'layout/admin'
        );
    );
);