选项卡支持跨域名

This commit is contained in:
shuzheng 2017-03-07 23:12:15 +08:00
parent edc0534b5f
commit ecda5e48ee
1 changed files with 1 additions and 1 deletions

View File

@ -188,7 +188,7 @@ $(function() {
// 选项卡对象
var Tab = {
addTab: function(title, url) {
var index = url.replace('.', '_').replace(/\//g, '__');
var index = url.replace(/\./g, '_').replace(/\//g, '_').replace(/:/g, '_').replace(/\?/g, '_').replace(/,/g, '_').replace(/=/g, '_').replace(/&/g, '_');
// 如果存在选项卡,则激活,否则创建新选项卡
if ($('#tab_' + index).length == 0) {
// 添加选项卡