Magento Expert Forum - Improve your Magento experience

Results 1 to 2 of 2

Solve the problem from Magento error page

  1. #1
    Junior Member jaredovi's Avatar
    Join Date
    Mar 2013
    Posts
    68
    Thanks
    2
    Thanked 14 Times in 11 Posts

    Default Solve the problem from Magento error page

    Standard Error Page



    This is how the default standard error page in magento looks like


    Magento Error Page

    As we can see due to security reasons, magento doesn’t display the error message directly, instead it save the error stack trace to the file. This is a good thing, since you won’t want outside people to know about your file name and paths, which usually shows up in error track. So anyway, to view the error message you need to go to /var/report/ folder in magento. Here you would see a file with the error number as the filename, in our case the filename would be 567330089. This is a standard text file, open it in any text editor to view the error message.
    But, if you want to view directly the error message in magento you need to make changes to your configuration file. Go to /errors/local.sample.xml and rename this file to /errors/local.xml. Now you would be able to view the error message in your web browser itself.


    This is usually required when your developing your website, since you would like to view your error message faster. But in the a live site, it better for security feature to have the default magento page

    Error Page Configuration



    Another great feature, if in your production site you want your users not to see a report number etc, rather a nice error page with email options like shown here .
    You need to open the /errors/local.xml file and change the

    HTML Code:
    <action>print</action>
    to

    HTML Code:
    <action>email</action>
    This show a nice form on front end, where user can email you back when they view the error message. Also if you want to change the text/styles of this page the html file is located at /errors/default/report.html

    Logging



    Another important aspect of troubleshooting magento is error logs. To enable error logs to go Admin -> System -> Configuration. Open the “Developer” section, this is the last section on left navigation. There is a box for Tab Settings there, you need enable logging from there. Once logging is enabled, you will get error messages in /var/log folder.

    PHP Error Messages



    Sometime, there might be some php error’s but instead your would end up seeing a blank page. The reason is, by default all php error message are turned off in magento. To turn error message open the index.php of magento, located in based folder. There change this line

    PHP Code:
    error_reporting(E_ALL E_STRICT); 
    to

    PHP Code:
    error_reporting(E_ALL); 

    and change

    PHP Code:
    #ini_set('display_errors', 1); 
    to

    PHP Code:
    ini_set('display_errors'1); 
    I think, this is all that magento provides for debugging and troubleshooting error message. If your still not able to find your error, you need to contact an expert.

    View more threads in the same category:


  2. The Following User Says Thank You to jaredovi For This Useful Post:

    Cms_ideas (07-01-2015)

  3. #2
    Junior Member Cms_ideas's Avatar
    Join Date
    Jun 2014
    Location
    https://cmsideas.net
    Posts
    385
    Thanks
    1
    Thanked 7 Times in 7 Posts

    Default

    That good for me <3

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •