2

I need to show the error on the front page instead of the error report.Please suggest

0

3 Answers 3

5

Try following methods to display error on screen:

1. Set the Magento mode

php bin/magento deploy:mode:set developer

2. Uncomment code

app/bootstrap.php

error_reporting(E_ALL);
ini_set('display_errors', 1);

3. Rename File

From:

pub/errors/local.xml.sample

To:

pub/errors/local.xml

1
2

Hello,

If you want to display PHP error then Go to app/bootstrap.php and uncomment Line No 10 and 11. And if you want to display error instead of error report then Go to pub/error directory and find local.xml.sample file and rename it to local.xml

That's it.

I hope this solution will help you.

0

the two methods can be used

1.Changing mode into the "developer"

2.Rename local.xml.sample in pub/error directory to local.xml

Not the answer you're looking for? Browse other questions tagged or ask your own question.