All Questions

100
votes
14answers
87071 views

Laravel 5 - Remove public from URL

I know this is a very popular question but I haven't been able to find a working solution for Laravel 5. I've been trying to migrate from Codeigniter for a long time, but this convoluted installation ...
146
votes
25answers
220870 views

PDOException SQLSTATE[HY000] [2002] No such file or directory

I believe that I've successfully deployed my (very basic) site to fortrabbit, but as soon as I connect to SSH to run some commands (such as php artisan migrate or php artisan db:seed) I get an error m...
123
votes
3answers
50004 views

Can anyone explain Laravel 5.2 Multi Auth with example

What I have done so far. I am trying to authenticate users and admin form user table and admin table respectively. I am using the User model as provided by laravel out of the box and created exactly s...
236
votes
15answers
96656 views

Best practices for custom helpers on Laravel 5

I would like to create some helpers (functions) to avoid repeating code between some views, in L5 style: view.blade.php <p>Foo Formated text: {{ fooFormatText($text) }}</p> They are ba...
99
votes
7answers
61702 views

Laravel 5: Display HTML with Blade

I have a string returned to one of my views, like this: $text = '<p><strong>Lorem</strong> ipsum dolor <img src="images/test.jpg"></p>' I'm trying to display it with B...
49
votes
11answers
64628 views

File permissions for Laravel 5 (and others)

I'm using Apache Web Server that has the owner set to _www:_www. I never know what is the best practice with file permissions, for example when I create new Laravel 5 project. Laravel 5 requires /sto...
109
votes
10answers
120161 views

How to get the query executed in Laravel 5 ? DB::getQueryLog returning empty array

DB::getQueryLog returning empty array $user = User::find(5); print_r(DB::getQueryLog()); result is empty array Array ( )
48
votes
8answers
41707 views

How to pass data to all views in Laravel 5?

I want to have some default data accessible in all views in my Laravel 5 application. I have tried to search for it but only find results for Laravel 4. I have read the documentation 'Sharing Data Wi...
219
votes
20answers
225713 views

Laravel 5 Failed opening required bootstrap/../vendor/autoload.php

I have recently installed Laravel 5 via composer. I tried creating a new controller using artisan and I get the following error: bootstrap/../vendor/autoload.php. Failed to open stream: No such fi...
41
votes
8answers
46698 views

Laravel 5 - redirect to HTTPS

Working on my first Laravel 5 project and not sure where or how to place logic to force HTTPS on my app. The clincher here is that there are many domains pointing to the app and only two out of three ...

Previous Next