Skip to content

Laravel lockforupdate (Pessimistic Locking)

i’m trying to figure out how to use/test the lockforupdate correctly, but i found is not function like what i expected this is just testing public function index() { return dd(DB::…

Php artisan make:auth command is not defined

I’m trying to run this command in Laravel 5.2 but it’s not working: php artisan make:auth And prompts with these statements: [InvalidArgumentException] Command “make:auth” is not defined …

PHP wrong foreach code

What I have done wrong, foreach code written below, but it seems not working: What I have to change in this foreach code? Thanks Answer first line, custom is not a variable (could be copy and paste error) Then you are splitting a string using can array operator, you need to split that string first using: Then…

WordPress Woocommerce Redirect Argument

When I enable my site automatically show argument ?v= like this How can I fix this? Answer String to all urls ?v=XXXXXXXXXXXX. That URL is coming from standard base address setting in Woocommerce. When you choose geolocation with caching support for page, it will add that ?v=xxxx string because it’s cap…

Change Faker Locale in Laravel 5.2

Is there a way to specify the Faker locale in the database/factories/ModelFactory.php file ? Here is my non functioning attempt at doing so >,< Thanks for reading! Answer Faker locale can be configured in the config/app.php configuration file. Just add the key faker_locale. e.g.: ‘faker_locale&#82…

filesize(): stat failed for specific path – php

i am coding a simple doc managing script and need to get the file size and file type /file or folder/ in a table. somehow it doesn’t work into the mention directory. please help if possible: it does actually has 2 errors – one the file size doesn’t work for the location, if i change it to pa…