这是一个创建于 3434 天前的主题,其中的信息可能已经有所发展或是发生改变。
AMH配置的lnmp环境架设虚拟机,假设网址为www.example.com,现在我要用这台虚拟机上www.example.com/a.php自己来抓取自己的www.example.com/target.php这个文件,如果按常理只需在a.php中写:echo file_get_contents('www.example.com/target.php'),但这样是否会影响速度?我能否写成:echo file_get_contents('127.0.0.1/target.php'),试了下不行,求问V神们有没有好的解决办法?
3 条回复 • 2015-01-30 20:37:21 +08:00
![loveyu](https://cdn.v2ex.com/avatar/7072/a5c2/42316_normal.png?m=1414205224) |
|
2
loveyu 2015-01-30 20:35:15 +08:00 1
服务器没配DNS吧
|
![webjin](https://cdn.v2ex.com/gravatar/dfc5de672417b893e532c98f0cfbca6d?s=48&d=retro) |
|
3
webjin 2015-01-30 20:37:21 +08:00 1
|