You can't get web content with PHP, but you can access Web content in a browser, what's the situation?
This post was last edited by u013067065 on 2014-01-03 13:46:46
Let's just infer from the facts what the problem is.
1. The server can use the browser to access the target Web page normally
2, the same URL with PHP can not access the content of the page.
Test code:
$a = file_get_contents (' destination URL ');
Var_dump ($a);
?>
The results are as follows:
Clearer Picture:/img/2014/01/04/222915183.jpg
No matter what, always get a section of JS. This section of JS seems to be responsible for steering.
And this code seems to be dynamic, each time the function name variable name will change itself dynamically, it should be some kind of software generated automatically.
3, the same program code, other servers can normally get to the destination URL of the page content.
According to the above facts, then you can infer where the problem is?
What are the restrictions on the target site for the server? Or is it a server configuration issue? Ask for answers!
share to: more
------Solution--------------------
JS code is to run after the results will be
You only get the JS code, but not run, how can I get results?