function index()//首页
{
$data['siteurl'] = base_url();
$this->output->_snoopy("www.neoyum.com",80,"http://www.neoyum.com/index.html");
}
function _snoopy($host,$port,$url){
$this->load->library('Snoopy');//加载自有类库
$snoopy = new Snoopy;
$snoopy->proxy_host = $host;//host
$snoopy->proxy_port = $port;//port
$snoopy->agent = "(compatible; MSIE 4.01; MSN 2.5; AOL 4.0; Windows 98)";
$snoopy->referer = "http://".$host;//来路信息
$snoopy->rawheaders["Pragma"] = "no-cache";//其它头信息
$snoopy->maxredirs = 2;//最大重定向次数
$snoopy->offsiteok = false;
$snoopy->expandlinks = false;
$snoopy->read_timeout = 0;//超时设置
$snoopy->fetch($url); //获取所有内容
echo $snoopy->results; //显示结果
}