TokenMismatchException in VerifyCsrfToken.php line 67:

Back to homepage

TokenMismatchException in VerifyCsrfToken.php line 67:

I have a form and when i click the submit button I get the error: TokenMismatchException in VerifyCsrfToken.php line 67:   The fix is to add in the form the input token ring: <input type=”hidden” name=”_token” value=”{{ csrf_token() }}”>

Read More

FatalErrorException in Str.php line 395: Call to undefined function Illuminate\Support\ctype_lower()

the fix is to enable the extension ctype from php.ini before after   and restart the apache serve.

Read More

Used terminal commands laravel

Create a new project in laravel: #laravel new your-project-name Another way to create a new project: #composer create-project laravel/laravel your-project-name Scaffold basic login and registration views and routes – it’s a good idea to do it at the beginning of

Read More

php artisan tinker

This terminal command provides a REPL (Read-Eval-Print Loop) for PHP with your application’s settings already loaded: php artisan tinker You can insert rows in a table: DB::table(‘cards’)->insert([‘title’=>’My First Card’,’created_at’=>DateTime,’updated_at’=>new DateTime]) You can display rows from a table: DB::table(‘cards’)->get(); Get me

Read More

php artisan migrate – error [PDOException] SQLSTATE[HY000] [2002] No such file or directory

/Applications/AMPPS/www/blog/config/database.php I changed the host from localhost into 127.0.0.1 and it worked: ‘host’ => env(‘DB_HOST’, ‘127.0.0.1’),

Read More

SQLSTATE[HY000] [1045] Access denied for user ‘homestead’@’localhost’ (using password: YES)

When I run the command “php artisan migrate” I get the following error message: [PDOException]  SQLSTATE[HY000] [1045] Access denied for user ‘homestead’@’localhost’ (usin g password: YES)        Solution: make sure that you have changed the configs from /Applications/AMPPS/www/blog/config/database.php make sure

Read More

gulp: command not found

After some hours of searching I found the fix and explanation here: http://blog.dwaynecrooks.com/post/110903139442/why-do-we-need-to-install-gulp-globally-and   # Step 1 npm install -g gulp # Step 2 npm install –save-dev gulp # …

Read More

Vhost and Laravel

To be able to access the new project(blog) from the localhost by accessing http://blog.local  you must find and edit the file httpd-vhost.php (try Applications/AMPPS/apache/conf/extra/httpd-vhost.php): <VirtualHost 127.0.0.1:80> ServerName blog.local DocumentRoot “/Applications/AMPPS/www/blog/public” <Directory “/Applications/AMPPS/www/blog/public”> Allow From All RewriteEngine On RewriteCond %{REQUEST_FILENAME} !-f

Read More

Add PATH so the laravel executable can be located by your system

A first problem for me was thatI didn;t know where to add ~/.composer/vendor/bin . I searched on the internet and I read all kind of answers like edit ~/.basrc or ~/.bash-profile or ~/.z something. The quick answer is to give the

Read More