realpvz

ErrorException: Array to string conversion

laravel Icon

ErrorException

Array to string conversion

An unhandled exception occurred on line 494
491
        $result = array_shift($segments);
492
493
        foreach ($segments as $segment) {
494
            $result .= (array_shift($replace) ?? $search).$segment;
495
        }

Solution

Umm , I used json_encode function for it and I succeeded.
This can help but is not always the answer.            
Apr 07, 2021 Anyone

0 replies


Install the browser extension

Found this solution helpful? Try our extension for quick solutions to your Laravel errors.

Chrome logo Add to Chrome - It's free