Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/rafaelcalleja/phpcrfileattachainline

Download automatic inline file's documents
https://github.com/rafaelcalleja/phpcrfileattachainline

Last synced: 7 days ago
JSON representation

Download automatic inline file's documents

Awesome Lists containing this project

README

        

PHPCRFileAttachaInline
======================

# Installation

## Step 1: Installation

```
php composer.phar install rc/phpcr-fai-bundle
```

## Step 2: Enable the bundle

Enable the bundle in the kernel:

``` php

RewriteEngine On
RewriteCond %{REQUEST_URI} ^/(.*\.(pdf|zip|doc|txt|PDF|ZIP|DOC|TXT))$
RewriteRule .* app.php [QSA,L,E=_ROUTING__route:rcphpcr_file_attach_inline_homepage,E=_ROUTING_file:%1,E=_ROUTING_DEFAULTS__controller:RC\\PHPCR\\FileAttachInlineBundle\\Controller\\DefaultController\:\:FindAction]

RewriteCond %{SCRIPT_FILENAME} !-d
RewriteRule ^(.*)/$ /$1 [L,R=301]

RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^(.*)$ app.php [QSA,L]

```