Why does function_exists always return faulse?

Source: Internet
Author: User
Why does function_exists always return faulse? As the question. The function is written in another php file and included with include before calling function_exists. However, false is returned and cannot be understood. & Nbsp; thank you. are the php file names consistent? Is the function name consistent? Why does function_exists always return faulse?
As the question. The function is written in another php file and included with include before calling function_exists.
However, false is returned and cannot be understood.

Thank you!

------ Solution --------------------
Are php file names consistent?
Is the function name consistent?
Are the cases the same?
------ Solution --------------------
You put that function on the page of your judgment.
As follows:
Function aa (){
Return 'BB ';
}
If (function_exists (aa ))
{
Echo 'yes ';
} Else {
Echo 'no ';
}
In this case, I tested yes. No problem,
In addition, you can call the function directly on your page to see if there will be any error. if there is no error, but it is not correct when you use function_exists, it may be your PHP version or environment. Generally, there will be no problems ..
------ Solution --------------------
Post a sample file

An error occurred while embedding the file.
------ Solution --------------------
Let's take a look at what I said on the first floor, or there is a problem with your inclusion. I use include and require for testing.

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.