织梦(Dedecms)图集和软件模型编辑器不完整的解决方法

发布时间: 2020-09-11 15 人阅读
  • 图集和软件里的编辑器
  • 其他模型编辑器
  • 图集模型编辑器功能不完整的解决方法
打开
/dede(后台目录)/templets/album_add.htm 和
/dede(后台目录)/templets/album_edit.htm 找到
“Diy”
改成
“Basic”
注意:图集模型的编辑器多图上传不可以用,跟图片集冲突,
如果一定要图集模型的编辑器有多图上传,请更换kindeditor编辑器或者ueditor编辑器
  • 软件模型编辑器功能不完整的解决方法
1、打开 /dede(后台目录)/templets/soft_add.htm 找到
<script language=”javascript” src=”js/main.js”></script>
在它下面加入
<script type=”text/javascript”src=”js/handlers.js”></script>
<script type=”text/javascript” src=”../images/swfupload/swfupload.js”></script>
<script language=”javascript” src=”../include/js/jquery/jquery.js”></script>
<script language=”javascript” src=”../include/js/jquery/ui.core.js”></script>
<script language=”javascript” src=”../include/js/jquery/ui.draggable.js”></script>
<script lang=’javascript’ src=’js/tb-box.js’></script>
<script language=”javascript”>
<!–
var swfu = null;
var arctype = ‘article’;
window.onload = function ()
{
swfu = new SWFUpload(
{
// Backend Settings
upload_url: “swfupload.php”,
post_params: {“PHPSESSID”: “<?php echo session_id(); ?>”, “dopost” : “”, “arctype” : arctype},
 
// File Upload Settings
file_size_limit : “2 MB”, // 2MB
file_types : “*.jpg; *.gif; *.png”,
file_types_description : “选择 JPEG/GIF/PNG 格式图片”,
file_upload_limit : “0”,
 
file_queue_error_handler : fileQueueError,
file_dialog_complete_handler : fileDialogComplete,
upload_progress_handler : uploadProgress,
upload_error_handler : uploadError,
upload_success_handler : uploadSuccess,
upload_complete_handler : uploadComplete,
 
button_image_url : “../images/SmallSpyGlassWithTransperancy_17x18.png”,
button_placeholder_id : “spanButtonPlaceholder”,
button_width: ‘100%’,
button_height: 26,
button_text : ‘<div class=”button” style=”background-color:#E5F1CF; height:26px; text-align:center; line-height:26px”>上传图片(可多选)</div>’,
button_text_style : ”,
button_text_top_padding: 0,
button_text_left_padding: 10,
button_window_mode: SWFUpload.WINDOW_MODE.TRANSPARENT,
button_cursor: SWFUpload.CURSOR.HAND,
 
// Flash Settings
flash_url : “../images/swfupload/swfupload.swf”,
 
custom_settings : {
upload_target : “divFileProgressContainer”
},
 
// Debug Settings
debug: false
});
};
 
function addtoEdit(pid)
{
jQuery.get(‘swfupload.php?dopost=addtoedit&id=’ + pid, function(data)
{
var picTitle = jQuery(‘input[name=”picinfook’+pid+'”]’).val();
var picHTML = ‘<img src=”‘+data+'” alt=”‘+picTitle+'”/>’;
CKEDITOR.instances.body.insertHtml(picHTML);
});
}
 
//删除已经上传的图片
function delAlbPic(pid){
// 同步删除编辑器中插入的图片
jQuery(“#__tmpbody”).html();
jQuery.get(‘swfupload.php?dopost=addtoedit&id=’ + pid, function(data)
{
var iptbody = CKEDITOR.instances.body.getData();
jQuery(“#__tmpbody”).html(iptbody);
jQuery(“#__tmpbody”).find(‘img’).each(function()
{
if(jQuery(this).attr(‘src’) == data)
{
//alert(data);
jQuery(this).remove();
}
});
CKEDITOR.instances.body.setData(jQuery(“#__tmpbody”).html()); 
jQuery(“#__tmpbody”).html();
var tgobj = $Obj(‘albCtok’+pid);
var myajax = new DedeAjax(tgobj);
myajax.SendGet2(‘swfupload.php?dopost=del&id=’+pid);
$Obj(‘thumbnails’).removeChild(tgobj);
});
}
 
//删除已经上传的图片(编辑时用)
function delAlbPicOld(picfile, pid){
var tgobj = $Obj(‘albold’+pid);
var myajax = new DedeAjax(tgobj);
myajax.SendGet2(‘swfupload.php?dopost=delold&picfile=’+picfile);
$Obj(‘thumbnailsEdit’).removeChild(tgobj);
}
–>
</script>
继续找到
 <tr>
      <td height=”100″>
      <?php
        GetEditor(‘body’, ”, 250, ‘Small’);
    ?>
    </td>
    </tr>
改成
<tr>
<td height=”100″>
<?php
GetEditor(‘body’, ”, 250, ‘Basic’);
?>
</td>
<td width=”255″ align=”center” valign=”top” bgcolor=”#FFFFCC” id=”mPic” style=”display:none”>
<div class=”multipic”>
<div style=”display: block;background-color:#E5F1CF; height:26px”>
<span id=”spanButtonPlaceholder”></span>
</div>
<div id=”divFileProgressContainer”></div>
<div id=”thumbnails” style=”width: 254px; height: 535px; background-color: rgb(255, 255, 255); overflow-y: scroll;”></div>
</div>
</td>
</tr>
修改后变成这样
2、打开 /dede(后台目录)/templets/soft_edit.htm 找到
<script language=”javascript” src=”js/main.js”></script>
在它下面加入
<script type=”text/javascript”src=”js/handlers.js”></script>
<script type=”text/javascript” src=”../images/swfupload/swfupload.js”></script>
<script language=”javascript” src=”../include/js/jquery/jquery.js”></script>
<script language=”javascript” src=”../include/js/jquery/ui.core.js”></script>
<script language=”javascript” src=”../include/js/jquery/ui.draggable.js”></script>
<script language=’javascript’ src=’js/tb-box.js’></script>
<script language=”javascript”>
<!–
var swfu = null;
var arctype = ‘article’;
window.onload = function ()
{
swfu = new SWFUpload(
{
// Backend Settings
upload_url: “swfupload.php”,
post_params: {“PHPSESSID”: “<?php echo session_id(); ?>”, “dopost” : “”, “arctype” : arctype,
“arcid”:<?php echo $arcRow[‘id’]?>},
 
// File Upload Settings
file_size_limit : “2 MB”, // 2MB
file_types : “*.jpg; *.gif; *.png”,
file_types_description : “选择 JPEG/GIF/PNG 格式图片”,
file_upload_limit : “0”,
 
file_queue_error_handler : fileQueueError,
file_dialog_complete_handler : fileDialogComplete,
upload_progress_handler : uploadProgress,
upload_error_handler : uploadError,
upload_success_handler : uploadSuccess,
upload_complete_handler : uploadComplete,
 
button_image_url : “../images/SmallSpyGlassWithTransperancy_17x18.png”,
button_placeholder_id : “spanButtonPlaceholder”,
button_width: ‘100%’,
button_height: 26,
button_text : ‘<div class=”button” style=”background-color:#E5F1CF; height:26px; text-align:center; line-height:26px”>上传图片(可多选)</div>’,
button_text_style : ”,
button_text_top_padding: 0,
button_text_left_padding: 10,
button_window_mode: SWFUpload.WINDOW_MODE.TRANSPARENT,
button_cursor: SWFUpload.CURSOR.HAND,
 
// Flash Settings
flash_url : “../images/swfupload/swfupload.swf”,
 
custom_settings : {
upload_target : “divFileProgressContainer”
},
 
// Debug Settings
debug: false
});
};
 
function addtoEditOld(picurl,pid)
{
var picTitle = jQuery(‘input[name=”picinfook’+pid+'”]’).val();
var picHTML = ‘<img src=”‘+picurl+'” alt=”‘+picTitle+'”/>’;
CKEDITOR.instances.body.insertHtml(picHTML);
}
 
//删除已经上传的图片
function delAlbPic(pid){
// 同步删除编辑器中插入的图片
jQuery(“#__tmpbody”).html();
jQuery.get(‘swfupload.php?dopost=addtoedit&id=’ + pid, function(data)
{
var iptbody = CKEDITOR.instances.body.getData();
jQuery(“#__tmpbody”).html(iptbody);
jQuery(“#__tmpbody”).find(‘img’).each(function()
{
if(jQuery(this).attr(‘src’) == data)
{
//alert(data);
jQuery(this).remove();
}
});
CKEDITOR.instances.body.setData(jQuery(“#__tmpbody”).html()); 
jQuery(“#__tmpbody”).html();
var tgobj = $Obj(‘albCtok’+pid);
var myajax = new DedeAjax(tgobj);
myajax.SendGet2(‘swfupload.php?dopost=del&id=’+pid);
$Obj(‘thumbnails’).removeChild(tgobj);
});
}
 
function addtoEdit(pid)
{
jQuery.get(‘swfupload.php?dopost=addtoedit&id=’ + pid, function(data)
{
var picTitle = jQuery(‘input[name=”picinfook’+pid+'”]’).val();
var picHTML = ‘<img src=”‘+data+'” alt=”‘+picTitle+'”/>’;
CKEDITOR.instances.body.insertHtml(picHTML);
});
}
 
//删除已经上传的图片(编辑时用)
function delAlbPicOld(picfile, pid){
var iptbody = CKEDITOR.instances.body.getData();
jQuery(“#__tmpbody”).html(iptbody);
jQuery(“#__tmpbody”).find(‘img’).each(function()
{
if(jQuery(this).attr(‘src’) == picfile)
{
//alert(data);
jQuery(this).remove();
}
});
CKEDITOR.instances.body.setData(jQuery(“#__tmpbody”).html()); 
jQuery(“#__tmpbody”).html();
 
var tgobj = $Obj(‘albold’+pid);
var myajax = new DedeAjax(tgobj);
myajax.SendGet2(‘swfupload.php?dopost=delold&picfile=’+picfile);
$Obj(‘thumbnailsEdit’).removeChild(tgobj);
}
–>
</script>
继续找到
 <tr>
      <td height=”100″ colspan=”4″>
        <?php
        GetEditor(“body”,$addRow[“introduce”],250,”Small”);
?>      </td>
    </tr>
改成
<tr>
<td height=”100″ colspan=”4″>
<?php
GetEditor(“body”,$addRow[“introduce”],250,”Basic”);
?>
</td>
<td width=”255″ align=”center” valign=”top” bgcolor=”#FFFFCC” id=”mPic” style=”display:none”>
<div class=”multipic”>
<div style=”display: block;background-color:#E5F1CF; height:26px”> <span id=”spanButtonPlaceholder”></span> </div>
<div id=”divFileProgressContainer”></div>
<div id=”thumbnailsEdit” style=”width: 254px; height: 535px; background-color: rgb(255, 255, 255); overflow-y: scroll;”>
<?php
//var_dump(“SELECT * FROM `dede_uploads` WHERE arcid = {$addRow[‘aid’]}”);
$dsql->SetQuery(“SELECT * FROM `dede_uploads` WHERE arcid = {$addRow[‘aid’]}”);
$dsql->Execute();
while($trow = $dsql->GetArray())
{
?>
<div class=”albCt” id=”albold<?php echo $trow[‘aid’];?>”>
<img width=”120″ onclick=”addtoEditOld(‘<?php echo $trow[‘url’];?>’,<?php echo $trow[‘aid’];?>)” src=”<?php echo $trow[‘url’];?>” style=”cursor:pointer”><a href=”javascript:delAlbPicOld(‘<?php echo $trow[‘url’];?>’, <?php echo $trow[‘aid’];?>)”>[删除]</a>
<div style=”margin-top:10px”>注释:<input type=”text” style=”width:100px;” value=”<?php echo $trow[‘title’];?>” name=”picinfook<?php echo $trow[‘aid’];?>”></div>
</div>
<?php
}
?>
<div id=”thumbnails”></div>
</div>
</div>
</td>
</tr>
修改后变成这样
1. 本站所有资源来源于用户上传和网络,如有侵权请邮件联系站长!vip@mobanstar.com
2. 您必须在下载后的24个小时之内,从您的电脑中彻底删除上述内容资源!
3. 如果你也有好源码或者教程,可以到审核区发布,分享有金币奖励和额外收入!
4. 本站提供的源码、模板、插件等等其他资源,都不包含技术服务请大家谅解!
5. 如有链接无法下载、失效或广告,请联系管理员处理!
6. 本站资源售价只是赞助,收取费用仅维持本站的日常运营所需!
7. 本站不保证所提供下载的资源的准确性、安全性和完整性,源码仅供下载学习之用!
8. 如用于商业或者非法用途,与本站无关,一切后果请用户自负!
9. 如遇到加密压缩包,默认解压密码为"www.mobanstar.com",如遇到无法解压的请联系管理员!

模板星 » 织梦(Dedecms)图集和软件模型编辑器不完整的解决方法

常见问题FAQ

购买的模板是永久使用的嘛?需要授权码嘛?
凡是在模板星购买的模板/主题都是支持永久使用的,无需购买授权码,请用户放心购买使用。
VIP模板提供安装服务嘛?需要收费嘛?
凡在模板星购买的模板/主题均可提供一次免费安装服务(需提供空间及数据库账号),请用户放心购买。

发表评论

售后服务:

  • 售后服务范围 1、商业模板使用范围内问题免费咨询
    2、源码安装、模板安装(一般 ¥50-300)服务答疑仅限SVIP用户
    3、单价超过200元的模板免费一次安装,需提供服务器信息。
    付费增值服务 1、提供dedecms模板、WordPress主题模板优化等服务请详询在线客服
    2、承接DedeCMS、 WordPress等系统建站、仿站、开发、定制等服务
    3、服务器环境配置(一般 ¥50-300)
    4、网站中毒处理(需额外付费,500元/次/质保三个月)
    售后服务时间 周一至周日(法定节假日除外) 9:00-23:00
    免责声明 本站所提供的模板(主题/插件)等资源仅供学习交流,若使用商业用途,请购买正版授权,否则产生的一切后果将由下载用户自行承担,有部分资源为网上收集或仿制而来,若模板侵犯了您的合法权益,请来信通知我们(Email:vip@mobanstar.com),我们会及时删除,给您带来的不便,我们深表歉意!

目前已经有 106 位会员加入