Jump to content

Is it possible...


Deivas

Recommended Posts

Yeh, it can include local php files.

 

You can include and run remote php files by using eval:

 

eval(file_get_contents('http://host.com/remotefile.php'));

 

Of course I wouldn't suggest you do this unless you have absolute control over the remote file and it is the only way to reference the code.

 

Also, you might want to try cURL, that can do some pretty incredible stuff.

Link to comment
https://forums.phpfreaks.com/topic/194441-is-it-possible/#findComment-1022797
Share on other sites

Yeh, it can include local php files.

 

You can include and run remote php files by using eval:

 

eval(file_get_contents('http://host.com/remotefile.php'));

 

That will not work. When file_get_contents() calls an external php file the web server will parse that php file and return the processed results (i.e. the rendered html code), it will not return the PHP code.

Link to comment
https://forums.phpfreaks.com/topic/194441-is-it-possible/#findComment-1022870
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.