<meta>正则

网络编程 发布日期:2025/4/27 浏览次数:1

正在浏览:<meta>正则
复制代码 代码如下:
var charResult = this.getAttribute("responseText").match(/<meta.*?\Wcharset\s*=\s*(\S+?)["'>\s]/i);
charResult = charResult ? charResult[1] : "gb2312";