What is difference between include,require,include_once and require_once() ?
- Sharad Jaiswal
- 22nd Feb, 2018
2 answer(s) :
-
Reply
"
- Include and require both uses to include a PHP page within another PHP page in a project to initialize some predefined functions or programs. But the only difference between both is that if you have
used include(test.php) and test.php does not exist then you would receive a warning error but
execution would not interrupt while, if you have used require(test.php) and test.php does not
exist then you would receive a fatal error and execution would be interrupted. - Same thing happens with include_once and require_once except that in that case file is required
only once.
- Include and require both uses to include a PHP page within another PHP page in a project to initialize some predefined functions or programs. But the only difference between both is that if you have
-
Reply
Kimpichindimngel@gmail.com
02nd Sep, 2022"I have been searching this type of web site finally I found it....it's so helpful and I do hope that one day i can crack the interview confidently thanks you so much ??
Post your Answer :
Valid name is required.
Valid name is required.
Valid email id is required.
Ajay
17th Dec, 2018