Top "Laravel" questions

Laravel is a free, open-source PHP web framework, created by Taylor Otwell and intended for the development of web applications following the model–view–controller (MVC) architectural pattern and based on Symfony.

How Do I Get the Query Builder to Output Its Raw SQL Query as a String?

Given the following code: DB::table('users')->get(); I want to get the raw SQL query string that …

php sql laravel laravel-4 laravel-query-builder
How to Create Multiple Where Clause Query Using Laravel Eloquent?

I'm using the Laravel Eloquent query builder and I have a query where I want a WHERE clause on multiple …

php laravel eloquent laravel-query-builder
How to remove a package from Laravel using composer?

What is the correct way to remove a package from Laravel using composer? So far I've tried: Remove declaration from …

laravel laravel-4 package composer-php uninstallation
Get the Last Inserted Id Using Laravel Eloquent

I'm currently using the below code to insert data in a table: <?php public function saveDetailsCompany() { $post = Input::All(); $…

php database laravel eloquent
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 …

php mysql laravel pdo
Laravel Checking If a Record Exists

I am new to Laravel. Please excuse the newbie question but how do I find if a record exists? $user = …

php laravel laravel-5 eloquent conditional
Laravel: Get base url

Simple question, but the answer seems quite hard to come by. In Codeigniter, I could load the url helper and …

php laravel base-url
Laravel Redirect Back with() Message

I am trying to redirect to the previous page with a message when there is a fatal error. App::fatal(…

laravel laravel-5 laravel-4
Could not open input file: artisan

When trying to create a new laravel project, The following error appears on the CLI: Could not open input file: …

php laravel laravel-4 laravel-artisan
Add a new column to existing table in a migration

I can't figure out how to add a new column to my existing database table using the Laravel framework. I …

php laravel laravel-4 laravel-migrations