php访问其他网站接口

使用函数:  file_get_contents($url);

传入接口url及其参数:如

$url="http://192.168.1.1/test.jsp?id=1&type=2";

$ret=file_get_contents($url);

posted @ 2017-09-12 15:21  carlo-jie  阅读(1237)  评论(0编辑  收藏  举报