Commit a878a5ac authored by techird's avatar techird

修正IE下分享链接失败的问题

parent efb8131b
......@@ -60,17 +60,6 @@ $( function () {
// 当前脑图的分享连接
shareId = uuid(),
// 查找 baseUrl
baseUrl = ( function () {
var scripts = document.getElementsByTagName( 'script' );
for ( var i = 0; i < scripts.length; i++ ) {
var index = scripts[ i ].src.indexOf( 'social.js' );
if ( ~index ) {
return scripts[ i ].src.substr( 0, index );
}
}
} )(),
notice = window.alert,
minder = window.km,
......@@ -394,9 +383,9 @@ $( function () {
return;
}
var currentUrl = window.location.origin + window.location.pathname,
var baseUrl = /^(.*?)(\?|\#|$)/.exec(window.location.href)[1];
shareUrl = currentUrl + '?shareId=' + shareId,
var shareUrl = baseUrl + '?shareId=' + shareId,
shareData = new baidu.frontia.Data( {
shareMinder: {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment