2017 © Pedro Peláez
 

library fol

PHP framework

image

fol/fol

PHP framework

  • Sunday, November 20, 2016
  • by oscarotero
  • Repository
  • 1 Watchers
  • 6 Stars
  • 152 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 1 Forks
  • 0 Open issues
  • 50 Versions
  • 0 % Grown

The README.md

Aqui tes o FOL

(o resto da gaita xa é cousa túa), (*1)

Build Status PPM Compatible, (*2)

FOL é un (micro)framework escrito en PHP por Oscar Otero. Como é algo persoal que non pretende ter moita repercusión (hai miles de frameworks en PHP), escribo a documentación en galego por comodidade e por se alguen máis de aquí lle interesa., (*3)

Requerimentos:, (*4)

  • PHP 5.5+
  • Composer
  • Node 4+

Instalación

composer create-project fol/fol o-meu-proxecto
cd o-meu-proxecto
npm install
cp .env.example .env
mkdir -m 0777 data
mkdir -m 0777 data/logs

App

A clase App\App (aloxada en app/App.php) é a que xestiona a páxina web. Mira fol-core para máis información., (*5)

Liña de comandos

Fol usa Robo como xestor de tarefas. Polo que edita o arquivo RoboFile.php para meter aí os comandos que queiras., (*6)

Só hai un comando definido por defecto que é robo run, que o que fai é lanzar un servidor de php, executa gulp e usa BrowserSync para sincronizar os cambios., (*7)

Deploy

Podes usar Deployer para facer deploy ao servidor que queiras. Xa inclúe un arquivo deploy.php con toda a configuración que podes personalizar., (*8)

Gulp

Tamén trae un arquivo gulp preparado para xestionar os css/js/imgs. Os arquivos orixinais gárdanse no directorio "assets" e gulp procésaos e pásaos ao directorio "public"., (*9)

PHP-PM

Se queres, tamén podes usar php-pm para lanzar a web. Tes que instalar o Psr-7 bridge:, (*10)

# change minimum-stability to dev in your composer.json (until we have a version tagged): "minimum-stability": "dev"

composer require php-pm/php-pm:dev-master
composer require php-pm/psr7-adapter
php vendor/bin/ppm config --bootstrap=App\\PPM
php vendor/bin/ppm start

Configuración do servidor

En Apache

Xa hai un arquivo .htaccess preparado, simplemente tes que permitir usalo:, (*11)

<Directory "/var/www/fol/public">
    AllowOverride All
</Directory>

Se queres meter o teu proxecto nun subdirectorio (por exemplo http://localhost/blog) podes poñer o proxecto fora do documentRoot e crear un alias:, (*12)

<IfModule alias_module>
    Alias /blog /var/www/blog/public
</IfModule>

<Directory "/var/www/blog/public">
    Options +FollowSymLinks
    AllowOverride All
</Directory>

Para que alias funcione, necesitas usar a directiva RewriteBase no .htaccess:, (*13)

<IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /blog/

    # Handle front controller
    RewriteCond %{REQUEST_FILENAME}/index.html !-f
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteRule ^ index.php [L]
</IfModule>

En Nginx

Tes que editar o arquivo de configuración (nginx/sites-enabled/default):, (*14)

server {
    root /var/www/fol/public;

    charset utf-8;

    location ~* \.php$ {
        fastcgi_split_path_info ^(.+\.php)(/.+)$;
        fastcgi_pass unix:/var/run/php5-fpm.sock;
        fastcgi_index index.php;
        include fastcgi_params;
    }

    # Deny access for hidden
    location ~ /\. {
        deny all;
    }

    # Manage all request
    location / {
        try_files $uri @public;
    }

    # Headers for assets
    location ~* .*\.(css|js|jpg|jpeg|gif|png|ico|cur|gz|svg|svgz|mp4|ogg|ogv|webm|htc|woff|eot|ttf)$ {
        expires 1M;
        access_log off;
        add_header Cache-Control "public";
        try_files $uri @public;
    }

    # This is the public location, called in each request
    location @public {
        if (!-f $request_filename) {
            rewrite ^(.*)$ /index.php last;
        }
    }
}

The Versions

11/03 2015

v6.0

6.0.0.0 https://github.com/fol-project/fol

PHP framework

  Sources   Download

AGPL-3.0

The Requires

 

framework

09/03 2015

v5.1

5.1.0.0 https://github.com/fol-project/fol

PHP framework

  Sources   Download

AGPL-3.0

The Requires

 

framework

02/03 2015

v5.0

5.0.0.0 https://github.com/fol-project/fol

PHP framework

  Sources   Download

AGPL-3.0

The Requires

 

framework

18/02 2015

v4.0

4.0.0.0 https://github.com/fol-project/fol

PHP framework

  Sources   Download

AGPL-3.0

The Requires

 

framework

03/09 2014

v3.3.2

3.3.2.0 https://github.com/fol-project/fol

PHP framework

  Sources   Download

AGPL-3.0

The Requires

 

framework

02/09 2014

v3.3.1

3.3.1.0 https://github.com/fol-project/fol

PHP framework

  Sources   Download

AGPL-3.0

The Requires

 

framework

02/09 2014

v3.3.0

3.3.0.0 https://github.com/fol-project/fol

PHP framework

  Sources   Download

AGPL-3.0

The Requires

 

framework

25/08 2014

v3.2.0

3.2.0.0 https://github.com/fol-project/fol

PHP framework

  Sources   Download

AGPL-3.0

The Requires

 

framework

30/07 2014

v3.1.0

3.1.0.0 https://github.com/oscarotero/fol

PHP framework

  Sources   Download

AGPL-3.0

The Requires

 

framework

18/07 2014

v3.0.0

3.0.0.0 https://github.com/oscarotero/fol

PHP framework

  Sources   Download

AGPL-3.0

The Requires

 

framework

13/05 2014

v2.3.1

2.3.1.0 https://github.com/oscarotero/fol

PHP framework

  Sources   Download

AGPL-3.0

The Requires

 

framework

02/05 2014

v2.3.0

2.3.0.0 https://github.com/oscarotero/fol

PHP framework

  Sources   Download

AGPL-3.0

The Requires

 

framework

14/04 2014

v2.2.0

2.2.0.0 https://github.com/oscarotero/fol

PHP framework

  Sources   Download

AGPL-3.0

The Requires

 

framework

30/03 2014

v2.1.0

2.1.0.0 https://github.com/oscarotero/fol

PHP framework

  Sources   Download

AGPL-3.0

The Requires

 

framework

25/03 2014

v2.0.1

2.0.1.0 https://github.com/oscarotero/fol

PHP framework

  Sources   Download

AGPL-3.0

The Requires

 

framework

25/03 2014

v2.0.0

2.0.0.0 https://github.com/oscarotero/fol

PHP framework

  Sources   Download

AGPL-3.0

The Requires

 

framework

13/03 2014

v1.7.0

1.7.0.0 https://github.com/oscarotero/fol

PHP framework

  Sources   Download

AGPL-3.0

The Requires

 

framework

07/03 2014

v1.4.2

1.4.2.0 https://github.com/oscarotero/fol

PHP framework

  Sources   Download

AGPL-3.0

The Requires

 

framework

07/03 2014

v1.4.1

1.4.1.0 https://github.com/oscarotero/fol

PHP framework

  Sources   Download

AGPL-3.0

The Requires

 

framework

06/03 2014

v1.4.0

1.4.0.0 https://github.com/oscarotero/fol

PHP framework

  Sources   Download

AGPL-3.0

The Requires

 

framework

05/03 2014

v1.3.0

1.3.0.0 https://github.com/oscarotero/fol

PHP framework

  Sources   Download

AGPL-3.0

The Requires

 

framework

01/03 2014

v1.2.2

1.2.2.0 https://github.com/oscarotero/fol

PHP framework

  Sources   Download

AGPL-3.0

The Requires

 

framework

20/02 2014

v1.2.1

1.2.1.0 https://github.com/oscarotero/fol

PHP framework

  Sources   Download

AGPL-3.0

The Requires

 

framework

13/02 2014

v1.2.0

1.2.0.0 https://github.com/oscarotero/fol

PHP framework

  Sources   Download

AGPL-3.0

The Requires

 

framework

13/02 2014

v1.1.0

1.1.0.0 https://github.com/oscarotero/fol

PHP framework

  Sources   Download

AGPL-3.0

The Requires

 

framework

09/02 2014

v1.0.0

1.0.0.0 https://github.com/oscarotero/fol

PHP framework

  Sources   Download

AGPL-3.0

The Requires

 

framework

02/01 2014

v0.15.0

0.15.0.0 https://github.com/oscarotero/fol

PHP framework

  Sources   Download

AGPL-3.0

The Requires

 

framework

22/12 2013

v0.14.3

0.14.3.0 https://github.com/oscarotero/fol

PHP framework

  Sources   Download

AGPL-3.0

The Requires

 

framework

20/12 2013

v0.14.2

0.14.2.0 https://github.com/oscarotero/fol

PHP framework

  Sources   Download

AGPL-3.0

The Requires

 

framework

17/12 2013

v0.14.1

0.14.1.0 https://github.com/oscarotero/fol

PHP framework

  Sources   Download

AGPL-3.0

The Requires

 

framework

10/12 2013

v0.14.0

0.14.0.0 https://github.com/oscarotero/fol

PHP framework

  Sources   Download

AGPL-3.0

The Requires

 

framework

07/12 2013

v0.13.2

0.13.2.0 https://github.com/oscarotero/fol

PHP framework

  Sources   Download

AGPL-3.0

The Requires

 

framework

03/12 2013

v0.13.1

0.13.1.0 https://github.com/oscarotero/fol

PHP framework

  Sources   Download

AGPL-3.0

The Requires

 

framework

03/12 2013

v0.13.0

0.13.0.0 https://github.com/oscarotero/fol

PHP framework

  Sources   Download

AGPL-3.0

The Requires

 

framework

12/11 2013

v0.12.1

0.12.1.0 https://github.com/oscarotero/fol

PHP framework

  Sources   Download

AGPL-3.0

The Requires

 

framework

25/10 2013

v0.12.0

0.12.0.0 https://github.com/oscarotero/fol

PHP framework

  Sources   Download

AGPL-3.0

The Requires

 

framework