|
@@ -81,6 +81,7 @@ To change this template use File | Settings | File Templates.
|
|
|
<form id="forum" method="post" action="forumedit">
|
|
|
<div class="fb_bg"></div>
|
|
|
<div id="content-publish" class="content-publish fb_tc" style="display: none;">
|
|
|
+ <a class="closebtn">关闭</a>
|
|
|
<div class="title-area">
|
|
|
<span class="text">个字</span><span
|
|
|
class="num">0</span><span
|
|
@@ -168,10 +169,8 @@ To change this template use File | Settings | File Templates.
|
|
|
class="upload-hide" multiple="multiple">
|
|
|
<div class="mdlman-pgrs">
|
|
|
</div>
|
|
|
- <p class="hint" id="hint">
|
|
|
- 可以上传不超过9张的图片
|
|
|
-
|
|
|
- </p>
|
|
|
+ <div class="hint" id="hint">
|
|
|
+ </div>
|
|
|
<div>
|
|
|
<ul class="pic-list clearfix">
|
|
|
</ul>
|
|
@@ -856,11 +855,9 @@ To change this template use File | Settings | File Templates.
|
|
|
}
|
|
|
imgurlhtml = imgurlhtml + '</ul>';
|
|
|
}
|
|
|
- if (x.htype != null && x.htype != '') {
|
|
|
- for (var p = 0; p < x.htype.length; p++) {
|
|
|
- if (x.htype[p] != null && x.htype[p] != '') {
|
|
|
- htypehtml = '<a class="mess-tag select" id=' + x.htype[p].id + ' >#' + x.htype[p].title + '</a>' + htypehtml;
|
|
|
- }
|
|
|
+ for (var p = 0; p < x.htype.length; p++) {
|
|
|
+ if (x.htype[p] != null && x.htype[p] != '') {
|
|
|
+ htypehtml = '<a class="mess-tag select" id=' + x.htype[p].id + ' >#' + x.htype[p].title + '</a>' + htypehtml;
|
|
|
}
|
|
|
}
|
|
|
if (x.fileurl != null && x.fileurl != '') {
|
|
@@ -1159,16 +1156,20 @@ To change this template use File | Settings | File Templates.
|
|
|
$("#imgurl").val(obj.imgurl);
|
|
|
// imgs
|
|
|
var htmls = '';
|
|
|
- if (obj.imgurl.indexOf(",") != -1) {
|
|
|
- var ims = obj.imgurl.split(",");
|
|
|
- for (var i = 0; i < ims.length; i++) {
|
|
|
- var imss = ims[i];
|
|
|
- htmls = "<div><a class='delsimg' id=" + imss + ">删除</a> <img src=" + imss + " id='imgs' width='50px'></div>" + htmls;
|
|
|
+ if (obj.imgurl != '' && obj.imgurl != null) {
|
|
|
+ if (obj.imgurl.indexOf(",") != -1) {
|
|
|
+ var ims = obj.imgurl.split(",");
|
|
|
+ for (var i = 0; i < ims.length; i++) {
|
|
|
+ var imss = ims[i];
|
|
|
+ htmls = "<div class='pic_list'><a class='delsimg' id=" + imss + ">删除</a> <img src=" + imss + " id='imgs' width='50px'></div>" + htmls;
|
|
|
+ }
|
|
|
+ } else {
|
|
|
+ htmls = "<div class='pic_list'><a class='delsimg' id=" + imss + ">删除</a> <img src=" + obj.imgurl + " id='imgs' width='50px'></div>";
|
|
|
}
|
|
|
- } else {
|
|
|
- htmls = "<div><a class='delsimg' id=" + imss + ">删除</a> <img src=" + obj.imgurl + " id='imgs' width='50px'></div>";
|
|
|
+ $("#hint").html(htmls);
|
|
|
+ }else {
|
|
|
+ $("#hint").text("可以上传不超过9张的图片");
|
|
|
}
|
|
|
- $("#hint").append(htmls);
|
|
|
var html = '';
|
|
|
for (var i = 0; i < obj.htype.length; i++) {
|
|
|
var x = obj.htype[i];
|
|
@@ -1179,9 +1180,14 @@ To change this template use File | Settings | File Templates.
|
|
|
}, "json");
|
|
|
$("#content-publish").show();
|
|
|
$(".fb_bg").show();
|
|
|
- $(this).hide();
|
|
|
+
|
|
|
});
|
|
|
|
|
|
+ $(".closebtn").click(function () {
|
|
|
+ $("#content-publish").hide();
|
|
|
+ $(".fb_bg").hide();
|
|
|
+ $('#hint').text("可以上传不超过9张的图片");
|
|
|
+ });
|
|
|
$("body").on('click', ".delsimg", function (e) {
|
|
|
$(this).parent().remove();
|
|
|
var imgs = $(this).attr("id");
|
|
@@ -1301,10 +1307,10 @@ To change this template use File | Settings | File Templates.
|
|
|
var ims = obj.message.split(",");
|
|
|
for (var i = 0; i < ims.length; i++) {
|
|
|
var imss = ims[i];
|
|
|
- htmls = "<div><a class='delsimg' id=" + imss + ">删除</a> <img src=" + imss + " id='imgs' width='50px'></div>" + htmls;
|
|
|
+ htmls = "<div class='pic_list'><a class='delsimg' id=" + imss + ">删除</a> <img src=" + imss + " id='imgs' width='50px'></div>" + htmls;
|
|
|
}
|
|
|
} else {
|
|
|
- htmls = "<div><a class='delsimg' id=" + message + ">删除</a> <img src=" + message + " id='imgs' width='50px'></div>"
|
|
|
+ htmls = "<div class='pic_list'><a class='delsimg' id=" + message + ">删除</a> <img src=" + message + " id='imgs' width='50px'></div>"
|
|
|
}
|
|
|
$("#hint").append(htmls);
|
|
|
} else {
|