Can PHP call dynamic files across domain names? Can PHP call dynamic files across domain names? For example, if there are websites www.a.com and www. B .com, can the php file in website A contain the php file in website B? ------ Solution ------------------ use file_get_contents to try ------ solution -------------------- B interface for A call is better. can PHP call dynamic files across domain names?
Can PHP call dynamic files across domain names?
For example, if there are websites www.a.com and www. B .com, can the php file in website A contain the php file in website B?
------ Solution --------------------
Try file_get_contents
------ Solution --------------------
B provides an interface for A to call.
In terms of function, you can also enable allow_url_include on A, and directly include the corresponding file on B. The target file must directly output the required php code.