1

result-when type php artisan serve

When I try php artisan serve command at my terminal it gives below error.Can any body help me to fix this issue?

ErrorException The use statement with non-compound name 'App' has no effect

Burgi
  • 421
  • 8
  • 24
Lish
  • 51
  • 1
  • 6
  • Check out this thread - [Stack-overflow Answer](http://stackoverflow.com/questions/9317022/troubleshooting-the-use-statement-with-non-compound-name-has-no-effect) – Terry Oct 21 '16 at 08:40

3 Answers3

3

remove

use App;

from your route.php file, it will work for sure. Thanks.

Y. Joy Ch. Singha
  • 3,056
  • 24
  • 26
0

I hereby post the answer for my own question as I found answer for this and hope this may helpful others in future.

Before : I just used 'use App' only at routes.php Now : When use 'use App\Http\Controllers' problem solved.

Lish
  • 51
  • 1
  • 6
0

Probably you add 'use App;' in some of your Laravel files, and artisan is parsing the line as an error. To know which line/file is the error, go to the log file (storage/logs/) and check it out. Then remove that line from the file.