dedecms不能下载远程图片和资源解决办法【转】

可能是因为服务器上禁用了fsockopen() 函数造成的,在用fsockopen()的地方用 stream_socket_client()代替就可以了。

具体修改地方是 /include/dedehttpdown.class.php 第507行

$this->m_fp = @fsockopen($this->m_host, $this->m_port, $errno, $errstr,10);
替换为
$this->m_fp = @stream_socket_client($this->m_host . ‘:’ . $this->m_port, $errno, $errstr,10);

为您推荐