摘要: 经常会使用php中的file_get_contents()函数去抓取远程页面, 对方页面文件过大、对方页面反应时间太久或网络传输慢等原因都可能会导致file_get_contents()执行时间超过php的最大执行时间。而一 旦file_get_contents出错即会终止整个程序。测试用例<?phpini_set("max_execution_time", 2);$url = "http:... 阅读全文
posted @ 2010-10-31 00:00 IT鸟 阅读(1937) 评论(0) 推荐(0) 编辑