Browse Source

fix

tags/6.1.7
tianya 2 years ago
parent
commit
8990d872e6
2 changed files with 7 additions and 7 deletions
  1. +1
    -1
      src/admin/dialog/select_images.php
  2. +6
    -6
      src/admin/dialog/select_soft.php

+ 1
- 1
src/admin/dialog/select_images.php View File

@@ -118,7 +118,7 @@ a{text-decoration:none!important}
window.opener.document.getElementById('litPic').src = reimg;
}
if (document.all) window.opener = true;
} else if (window.opener.CKEDITOR.instances.<?php echo $f ?>) {
} else if (typeof window.opener.CKEDITOR.instances["<?php echo $f ?>"] !== "undefined") {
let addonHTML = `<img src='${reimg}'>`;
window.opener.CKEDITOR.instances["<?php echo $f ?>"].insertHtml(addonHTML);
}


+ 6
- 6
src/admin/dialog/select_soft.php View File

@@ -60,19 +60,19 @@ a{text-decoration:none!important}
return;
}
function ReturnValue(reimg) {
if (window.opener.document.<?php echo $f ?> != null) {
window.opener.document.<?php echo $f ?>.value = reimg;
window.close();
return
}
var funcNum = <?php echo isset($CKEditorFuncNum) ? $CKEditorFuncNum : 1; ?>;
if (window.opener.CKEDITOR != null && funcNum != 1) {
window.opener.CKEDITOR.tools.callFunction(funcNum, reimg);
}
if (window.opener.CKEDITOR.instances.<?php echo $f ?>) {
if (typeof window.opener.CKEDITOR.instances["<?php echo $f ?>"] !== "undefined") {
let addonHTML = `<a href='${reimg}' target='_blank'><img src='<?php echo $cfg_cmspath ?>/static/web/img/addon.gif'>附件:${reimg}</a>`;
window.opener.CKEDITOR.instances["<?php echo $f ?>"].insertHtml(addonHTML);
}
if (window.opener.document.<?php echo $f ?> != null) {
window.opener.document.<?php echo $f ?>.value = reimg;
window.close();
return
}
window.close();
}
</script>


Loading…
Cancel
Save