2017 © Pedro Peláez
 

project gaufrette

image

echo511/gaufrette

  • Wednesday, January 21, 2015
  • by echo511
  • Repository
  • 0 Watchers
  • 0 Stars
  • 50 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 3 Versions
  • 0 % Grown

The README.md

Plupload for Nette Framework

Installation

Install using composer:, (*1)

$ composer require echo511/gaufrette:~1.0@dev

Register compiler extension using config.neon, (*2)

extensions:
    gaufrette: Echo511\Gaufrette\DI\GaufretteExtension

Configure in config.neon, (*3)

gaufrette:
    # Folder for asset copies
    assets:
        directory: '.../assets'
        web: '<basePath>/assets'

    # Data directory (uploaded photos/pdfs/etc.)
    data:
        directory: '.../data'
        web: '<basePath>/data'

Make sure your compiler extension class implements Echo511\Gaufrette\DI\IAssetsProvider., (*4)

Usage

To access assets use Echo511\Gaufrette\Assets\ExtensionsAssets or macro Echo511\Gaufrette\Assets\AssetMacro., (*5)

To access data use Echo511\Gaufrette\Data\DataFilesystem., (*6)

Asset macro

In presenter:, (*7)

<?php

use Nette\Application\UI\Presenter;
use Echo511\Plupload\Entity\UploadQueue;

class HomePresenter extends Presenter
{

    /** @var AssetMacro @inject */
    public $assetMacro;


    public function createTemplate()
    {
        $template = parent::createTemplate();
        $this->assetMacro->register($template, 'asset', MyCompilerExtension::class);
        return $template;
    }

}

In templates then use:, (*8)

<link href="{asset 'css/bootstrap.min.css'}" rel="stylesheet">

The Versions

21/01 2015

dev-master

9999999-dev

  Sources   Download

MIT

The Requires

 

The Development Requires

19/09 2014

v1.0.1

1.0.1.0

  Sources   Download

The Requires

 

The Development Requires

30/07 2014

v1.0

1.0.0.0

  Sources   Download

The Requires

 

The Development Requires