PHP run appears notice:use of undefined constant perfect solution sharing _php tips

Source: Internet
Author: User
Notice:use of undefined constant all_ps-assumed ' all_ps ' in E:\Server\vhosts\www.lvtao.net\global.php on line 50

notice:undefined Index:easetemplatever in E:\Server\vhosts\www.lvtao.net\libs\template.core.php on line 51

Notice:use of undefined constant uid-assumed ' uid ' in E:\Server\vhosts\www.lvtao.net\global.php on line 54

notice:undefined Index:uid in E:\Server\vhosts\www.lvtao.net\global.php on line 54

Notice:use of undefined constant cuid-assumed ' cuid ' in E:\Server\vhosts\www.lvtao.net\global.php on line 55

notice:undefined Index:cuid in E:\Server\vhosts\www.lvtao.net\global.php on line 55

Notice:use of undefined constant shell-assumed ' shell ' in E:\Server\vhosts\www.lvtao.net\global.php on line 56

notice:undefined Index:shell in E:\Server\vhosts\www.lvtao.net\global.php on line 56

Notice:use of undefined constant cshell-assumed ' Cshell ' in E:\Server\vhosts\www.lvtao.net\global.php on line 57

notice:undefined Index:cshell in E:\Server\vhosts\www.lvtao.net\global.php on line 57

Notice:use of undefined constant username-assumed ' username ' in E:\Server\vhosts\www.lvtao.net\global.php on line 58

notice:undefined Index:username in E:\Server\vhosts\www.lvtao.net\global.php on line 58

Notice:use of undefined constant cusername-assumed ' cusername ' in E:\Server\vhosts\www.lvtao.net\global.php on line 59

notice:undefined Index:cusername in E:\Server\vhosts\www.lvtao.net\global.php on line 59

Notice:use of undefined constant id-assumed ' id ' in E:\Server\vhosts\www.lvtao.net\companyjob.php to line 10

Notice:use of undefined constant id-assumed ' id ' in E:\Server\vhosts\www.lvtao.net\companyjob.php to line 14

Notice:use of undefined constant content-assumed ' content ' in E:\Server\vhosts\www.lvtao.net\companyjob.php on line 16

Notice:use of undefined constant content-assumed ' content ' in E:\Server\vhosts\www.lvtao.net\companyjob.php on line 16

Notice:use of undefined constant description-assumed ' description ' in E:\Server\vhosts\www.lvtao.net\companyjob.php on Line 17

Notice:use of undefined constant description-assumed ' description ' in E:\Server\vhosts\www.lvtao.net\companyjob.php on Line 17

Notice:use of undefined constant provinceid-assumed ' Provinceid ' in E:\Server\vhosts\www.lvtao.net\companyjob.php on Li NE 18

Notice:use of undefined constant cityid-assumed ' Cityid ' in E:\Server\vhosts\www.lvtao.net\companyjob.php on line 19

Notice:use of undefined constant hy-assumed ' hy ' in E:\Server\vhosts\www.lvtao.net\companyjob.php on line 20

notice:undefined variable:content in E:\Server\vhosts\www.lvtao.net\libs\template.core.php on line 557

Access to the site will appear a number of similar prompts, but can be displayed and run normally

Notice:use of undefined constant ctbtitle-assumed ' ctbtitle ' in d:\ctb1.5\ctb\include\config.php to line 23 ...

B Answer: These are PHP prompts rather than the error, PHP itself does not need to declare variables can be used directly, but not declared variables will be prompted. Generally as a formal website will turn off the prompts, and even the error message is turned off

Ways to turn off PHP hints

Search PHP.ini:

error_reporting = E_all

To

error_reporting = E_all & ~e_notice

There's another way to do it.

Add to the header of each file

error_reporting (0); It's hard to fix, but it solves the problem!!!!!! This is better.

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.