what is the difference between those 2??
Announcement
Collapse
No announcement yet.
require once and include
Collapse
X
-
require and include is almost the same. The difference is that if include fails, it throws a warning, if require fails, it shows a fatal error.
require_once and include_once works the same way, but here you can be sure that the file you include will ne included only one time, even if you include/require it twice or more. This make sense including files with functions or classes.
--> www.php.net/include
--> www.php.net/require
--> www.php.net/include_once
--> www.php.net/require_once
Saludo
piz
Comment