vendredi 4 septembre 2015

PhantomJs cannot execute binary file

I am trying to use PhantomJs in my laravel 5 project. I have downloaded via composer. I have added into my providers section and aliases section within config/app.php

Okay so i have now created my controller as seen below:

<?php namespace App\Http\Controllers;

use App\Http\Requests;
use PDF;
use View;

class PdfController extends Controller {

    public function index()
    {
        $view = View::make('home');

        return PDF::createFromView($view, 'home.pdf');
    }
}

I have also created my route for this method. However when i try this in my browser it throws the following error:

PhantomJS: sh: /Users/matts/sites/ManagementApp/vendor/antking/phantom-pdf/src/../bin/phantomjs: cannot execute binary file

Has anyone come across this before?

Thanks



from Newest questions tagged laravel-5 - Stack Overflow http://ift.tt/1N7bzyb
via IFTTT

Aucun commentaire:

Enregistrer un commentaire