php - Laravel blade variable default value issue
Get the solution ↓↓↓I have a blade master view in Laravel which contains the code{{$home or ''}}
. My server is using PHP 7.1, Nginx. I migrated the code to another server with cPanel, just copied the whole contents and database and setup everything. The server to which I migrated the code runs Litespeed and Php 7.3. The same code works on server running nginx but not the newly migrated server. When I browse the page, I getUndefined variable: home
. How can it run on nginx and not when using Litespeed. I'm new to litespeed and I haven't configured anything specific to laravel. Can someone please help to get this working.
Edit 1: based on this, this syntax doesn't work on Laravel 5.7 and above but I'm using 5.8 and it works fine at the moment on old server.
Share solution ↓
Additional Information:
Link To Answer People are also looking for solutions of the problem: git was not found in your path, skipping source download
Didn't find the answer?
Our community is visited by hundreds of web development professionals every day. Ask your question and get a quick answer for free.
Similar questions
Find the answer in similar questions on our website.
Write quick answer
Do you know the answer to this question? Write a quick response to it. With your help, we will make our community stronger.