Jump to content

Get data from a different domain...


clonetrooper9494

Recommended Posts

depending on your server, it is possible to get it with the file() function. Don't know about the include function, but i don't believe so. the file() thing will only work(i believe) if the PHP fsock option is enabled.

Link to comment
Share on other sites

Yes, you can, include does work if allow_url_fopen is set to true - but it comes with a serious security risk since with include whatever you get back will be interpreted as PHP and run on your server. Thus, if they can modify the URL, or can change the contents of the remote file to include PHP they can execute arbitrary code on your server.So, file(), file_get_contents() and similar are better choices, since they do not carry this risk.

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...