- <?php
- /**
- * 茉莉机器人网站:http://www.itpk.cn
- * 茉莉机器人在线体验:http://www.itpk.cn/experience.php
- */
- header("Content-type:text/plain; charset=utf-8");
- //不使用ApiKey调用
- $result = file_get_contents("http://i.itpk.cn/api.php?question=123");
- //使用ApiKey调用
- //$result = file_get_contents("http://i.itpk.cn/api.php?question=123&api_key=你的ApiKey&api_secret=你的ApiSecret");
- echo $result;
- ?>
- //该片段来自于http://www.codesnippet.cn/detail/0912201411210.html
来源: http://www.codesnippet.cn/detail/0912201411210.html