Do not display MySQL error prompt

Source: Internet
Author: User
There are 10 checkboxes. 9 when not ticked, the value is NULL, the database is an error


Reply to discussion (solution)

How to hide MySQL on a webpage. Users who access the server do not see the error

Checkboxes that are not selected will not be submitted

But when the test will show the MySQL error, I do not want to access the Web page users see the MySQL error message

Have you ruled out the error, and no error has been shown?

To add these two sentences, it is not recommended to use the error suppressor @.

 
  

But when the test will show the MySQL error, I do not want to access the Web page users see the MySQL error message
Modify PHP.ini
Error_reporting:e_all & ~e_deprecated
Display_errors:off

The curative effect is temporary, but the doctor has to cure root

Because I need to accept that all of the checkboxes are null, if not the corresponding value value is stored, as long as I define the variable and I am in the process of accepting the value of the variable is null will be an error

Quick to seek!!!!!!!!!!!!!!!!!!!!!

Masking error checking is a self-deception practice.
You need to check out the various errors that may occur.
The code for the generic tutorial example is code that does not contain error checking

You can post your code and see

MySQL error should be easy to solve!

Error_reporting

Is the database field a NOT NULL limit? There is of course an error when inserting a null value.

The program should be able to filter out illegal data, and the database design to be consistent with the data submitted.

Thank you, the answer from upstairs, I'll try again.

  • 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.