The perfect solution for notice: Use of undefined constant during PHP running

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 on line 10

Notice: Use of undefined constant ID-assumed 'id' in E:/Server/vhosts/www.lvtao.net/companyjob.php on 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 line 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

A large number of prompts similar to the following will appear when you enter the website, but they can be displayed and run normally.

Notice: Use of undefined constant ctbtitle-assumed 'ctbtitle' in D:/ctb1.5/CTB/include/config. php on line 23...

B answer: these are PHP prompts rather than errors. php itself can be directly used without declaring the variables in advance, but a prompt will be prompted if the variables are not declared. Generally, when a website is a formal website, it will turn off the prompt and even the error message.

How to disable PHP prompts

Search for PHP. ini:

Error_reporting = e_all

Changed:

Error_reporting = e_all &~ E_notice

There is another way to do this:

Add each file header

Error_reporting (0); the problem can be solved even though it is difficult to solve.

 

 

This is caused by irregular writing. For example, $ row [name] is written as $ row ['name'].

 

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.