我正在使用jQuery的 load 功能。
但当我打开网页时,谷歌的广告并没有出现,即使它们出现了。
我该怎么办?
编辑:
一些代码:
函数加载php页面:
function get_fb(g) { $("#hhs").load("hhs.php?rid="+g); }
php包含google广告代码。。。
广告通常通过脚本标签和 $(...).load() 删除任何脚本标记:
$(...).load()
// inject the contents of the document in, removing the scripts // to avoid any 'Permission Denied' errors in IE .append(res.responseText.replace(rscript, ""))
rscript 是与脚本标记匹配的正则表达式: /<script(.|\s)*?\/script>/gi
rscript
/<script(.|\s)*?\/script>/gi
然而, AdSense for Ajax 可能是你需要的。