PHP5 - Using an external URL with the include function

October 2017






Normally the option to include external URL (e.g absolute, shape http://site.tld/url) via

the function include is disabled by default in php5 versions, to activate this option on your server put these two lines in your php.ini :


allow_url_include = 1 
allow_url_fopen = 1 


For more information, see: http://www.php.net/ ... # ini.allow-url-fopen

Note that:it can be very dangerous to activate the option allow_url_include.
Indeed it may, in some cases, pose serious security vulnerabilities.
Published by jak58. Latest update on July 29, 2009 at 10:51 AM by jak58.
This document, titled "PHP5 - Using an external URL with the include function," is available under the Creative Commons license. Any copy, reuse, or modification of the content should be sufficiently credited to CCM (ccm.net).