【发布时间】:2011-07-14 10:14:06
【问题描述】:
如何从外部网页获取 html 源代码?
类似:getHtml('http://google.com');。
我尝试使用:$("#frame").contents().find("html"); 获取 iframe 的内容,但如果在我的情况下网页没有 html 标签,则只有 1 行文本。我不能用 php file_get_contents() 来做,因为它不保留会话数据。
【问题讨论】:
标签: javascript jquery