What are the differences between include() and include_once
() functions?

Answer Posted / sanjay sharma

The include_once() statement includes and evaluates the
specified file during the execution of the script. This is a
behavior similar to the include() statement, with the only
difference being that if the code from a file has already
been included, it will not be included again. As the name
suggests, it will be included just once. so include_once() is
better than include().

Is This Answer Correct ?    10 Yes 5 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How to return ascii value of character in php?

752


Tell me how can we determine whether a php variable is an instantiated object of a certain class?

756


what is session_set_save_handler in PHP?

763


What is use of preg_replace in php?

751


Which have the fastest execution between mysql_fetch_array() and mysql_fetch_assoc()

2047


How to redirect https to http url through .htaccess?

665


What are the features and advantages of object-oriented programming in php?

668


How can we display information of a variable and readable by human with php?

755


Does php need apache?

672


Is PHP an open source software?

761


Explain converting an object?

788


Tell me what library is used for pdf in php?

702


Are php session secure?

751


How do you end php?

711


How to enable cURL in PHP?

862