Questions tagged [laravel-artisan]

For programming questions about the Artisan Console, the command-line interface included with the Laravel PHP framework

Artisan is the name of the command-line interface included with .

It provides a number of helpful commands for your use while developing your application. It is driven by the powerful Console component.

Documentation

1490 questions
313
votes
20 answers

No Application Encryption Key Has Been Specified

I'm new to Laravel and I'm trying to use the Artisan command... php artisan serve It displays... Laravel development server started: http://127.0.0.1:8000 However, it won't automatically launch and when I manually enter http://127.0.0.1:8000 it…
Carlos F
  • 3,651
  • 3
  • 10
  • 19
310
votes
31 answers

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: artisan Script php artisan clear-compiled handling the post-install-cmd event returned with an error I am using the latest version of…
wessodesigner
  • 3,815
  • 3
  • 14
  • 9
304
votes
13 answers

Laravel 5 - artisan seed [ReflectionException] Class SongsTableSeeder does not exist

When I run php artisan db:seed I am getting the following error: [ReflectionException] Class SongsTableSeeder does not exist What is going on? My DatabaseSeeder class:
Sasha
  • 7,725
  • 21
  • 78
  • 154
190
votes
3 answers

What are the Differences Between "php artisan dump-autoload" and "composer dump-autoload"?

I am pretty new to Laravel 4 and Composer. While I do Laravel 4 tutorials, I couldn't understand the difference between those two commands; php artisan dump-autoload and composer dump-autoload What's the difference between them?
Naing Lin Aung
  • 3,232
  • 4
  • 29
  • 48
182
votes
8 answers

Laravel 5 Clear Views Cache

I notice that Laravel cache views are stored in ~/storage/framework/views. Over time, they get to eat up my space. How do I delete them? Is there any command that could? I tried php artisan cache:clear, but it is not clearing the views cache. With…
basagabi
  • 4,248
  • 6
  • 29
  • 62
169
votes
14 answers

Laravel 5.4 create model, controller and migration in single artisan command

I can create a model and resource controller (binded to model) with the following command php artisan make:controller TodoController --resource --model=Todo I want to also create a migration with the above command, is it possible?
arun
  • 3,506
  • 3
  • 16
  • 32
81
votes
17 answers

How to keep Laravel Queue system running on server

I recently setup a Laravel Queue system. The basics are a cronjob calls a command which adds jobs to a queue and calls a second command which sends an email. The system works when I ssh into my server and run php artisan queue:listen, but if I…
zeros-and-ones
  • 3,407
  • 3
  • 30
  • 50
73
votes
7 answers

php artisan migrate:make create_mytable fails: "migrate:make" is not defined

When running the following command at the root of my Laravel 5 application, php artisan migrate:make create_mytable I get the following error: [InvalidArgumentException] Command "migrate:make" is not defined. Did you mean one of…
Jack
  • 1,333
  • 1
  • 9
  • 9
62
votes
22 answers

ReflectionException: Class ClassName does not exist - Laravel

As soon, I am typing php artisan db:seed command. I'm getting Error Like: [ReflectionException] Class UserTableSeeder does not exist root@dd-desktop:/opt/lampp/htdocs/dd/laravel# php artisan db:seed Here, Is my UserTableSeeder.php &…
Nana Partykar
  • 10,175
  • 8
  • 43
  • 73
62
votes
5 answers

Laravel 5 How to switch from Production mode

When I run $ php artisan env I get; Current application environment: production How can I change this to development or something similar? So I can see errors.. I have read a lot of the documentation but it is not at all easy for a newbie to…
mikelovelyuk
  • 3,520
  • 8
  • 39
  • 79
60
votes
12 answers

Fatal error: Class 'Illuminate\Foundation\Application' not found

I am getting following error when I open my site which is made using laravel 5 Fatal error: Class 'Illuminate\Foundation\Application' not found in C:\cms\bootstrap\app.php on line 14 I have tried removing vendor folder and composer.lock file and…
xenish
  • 1,142
  • 3
  • 13
  • 17
58
votes
28 answers

SQLSTATE[HY000] [2002] Connection refused within Laravel homestead

Using Mac OS X and Homestead 2.2.1 with Laravel 5.2. In terminal (within homestead in my project folder) I can do php artisan to see all the available commands. When I try to run php artisan migrate I get a connection error: SQLSTATE[HY000] [2002]…
nclsvh
  • 2,108
  • 4
  • 24
  • 44
52
votes
11 answers

Artisan Error: Failed to listen on localhost:8000

I'm having problem starting my laravel installation. Whenever I type in the terminal 'php artisan serve' it responses me an error: Failed to listen on localhost:8000 (reason:une tentative d'access un α socket de maniere interdite par ses…
byacer
  • 523
  • 1
  • 4
  • 6
50
votes
3 answers

Laravel migrations change default value of column

I have a table with a default value already assigned. For an example we can look at the following: Schema::create('users', function (Blueprint $table) { $table->increments('id')->unsigned(); …
42
votes
3 answers

Artisan, creating tables in database

I am trying to create mysql tables in Laravel 5. I created a file in /project/database/migrations called users.php: [...] public function up() { Schema::create('users', function(Blueprint $table) { $table->increments('id'); …
Streetlamp
  • 1,317
  • 2
  • 13
  • 24
1
2 3
99 100