How to debug php In ubuntu in a browser?

Source: Internet
Author: User

1. Enter sudo gedit/etc/PhP5/apache2/PHP. ini on the terminal, and then enter the root password. Then, you can open PHP. ini in a text editor.

2. Set display_errors in PHP. ini to on, for example, display_errors = on.

3. Set error_reporting in PHP. ini to e_all | e_strict; for example, error_reporting = e_all | e_strict

4. Restart the Apache server. Enter sudo/etc/init. d/apache2 restart on the terminal to restart the Apache server.

Now, the PHP debugging environment has been set up. When you access the problematic webpage in a browser, a prompt message is displayed on the webpage. After the development is complete, set the corresponding value to the default value.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.