What is the exact Diff. between include_once() and
require_once() in PHP?
Answer Posted / vineet kumar saini
1.include() includes a file in memory no matter if it has
already been loaded
2.include_once() includes a file in memory only if it has
not been loaded already
3.require() includes a file in memory no matter if it has
already been loaded. if the file cannot be loaded, the
script is aborted
4.require_once() does the same as require(), but only if the
file hasn't been included yet. if the file's already in
memory, it has no effect.
| Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
How do you count numbers in php?
What is difference between post and put in rest?
Tell me how to set a page as a home page in a php based site?
When a conditional statement is ended with an endif?
Are parent constructors called implicitly inside a class constructor?
What is 'float' property in css?
Tell me what is the default session time in php?
How to connect to a url in php?
What is smarty?
What is data type in php?
How can we enable error reporting in php?
Why does sql injection happen?
What is the different between count() and sizeof() in php?
Tell me how can I display text with a php script?
How do sessions work in php?