Whats the difference between include() and require()?

Answer Posted / shanawar

Both used for connecting to the database. but the main
difference b/w them if we r using include()and the file is
not found then a warring will be occure and script will be
execute.. But in the case of require() a error will occure
and script will be helt........................ Shanawar

Is This Answer Correct ?    1 Yes 12 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What's the difference between accessing a class method via -> and via ::?

792


What is the difference between $var and $$var?

781


Define urlencode() and urldecode() used in php?

829


What are new features in php 7?

774


What is sorting php?

719


What is the advantage of runtime polymorphism?

712


What is the use of stripslashes in php?

764


How can we encrypt the password using php?

780


where do we use htaccess?

750


How to increase the execution time of a PHP script?

750


Differences between get, post and request methods ?

754


What is the purpose of break and continue statement?

751


How is it possible to remove escape characters from a string?

824


What is compact function php?

757


What is difference between mysqli and mysql?

782