Skip to content

Commit

Permalink
update 2.18e
Browse files Browse the repository at this point in the history
- แก้ไขปัญหาการกระซิบถึงคนที่ยังไม่แชทไม่ได้
- แก้ไขให้อัปโหลดภาพใช้ได้กับ PHP 5.3+
  • Loading branch information
popiazaza committed Jul 25, 2020
1 parent 63e3e19 commit b374e76
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 17 deletions.
2 changes: 1 addition & 1 deletion th_chat/discuz_plugin_th_chat.xml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
<item id="datatables"><![CDATA[]]></item>
<item id="directory"><![CDATA[th_chat/]]></item>
<item id="copyright"><![CDATA[newz]]></item>
<item id="version"><![CDATA[2.18d]]></item>
<item id="version"><![CDATA[2.18e]]></item>
<item id="__modules">
<item id="0">
<item id="name"><![CDATA[chat]]></item>
Expand Down
5 changes: 0 additions & 5 deletions th_chat/include.php
Original file line number Diff line number Diff line change
Expand Up @@ -86,10 +86,5 @@
if(in_array($_G['adminid'],array(1,2,3))){
$chat['editor'] .= '<a href="javascript:void(0);" onClick="nzCommand(\'clear\',\'\');" title="ล้างห้องแชท" style="width:20px;height:20px;background:url(source/plugin/th_chat/images/clear.png) no-repeat center">Clear</a>';
}
if (version_compare(PHP_VERSION, '7.0.0') >= 0) {
$showimgup = true;
}else{
$showimgup = false;
}
$chat['welcometext'] = $config['welcometext'];
?>
2 changes: 1 addition & 1 deletion th_chat/online.php
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@
$body_onlinein[$r['groupid']] .= '<div class="nzolcon"><div class="nzolname" onMouseOver="nzchatobj(\'#nzchatolc'.$r['uid'].'\').show();nzchatobj(\'#nzchatolr'.$r['uid'].'\').hide();" onMouseOut="nzchatobj(\'#nzchatolc'.$r['uid'].'\').hide();nzchatobj(\'#nzchatolr'.$r['uid'].'\').show();">
<div style="display:inline-block">
<img src="' . avatar($r['uid'], 'small', 1) . '" title="' . $r['username'] . '" onclick="showWindow(\'th_chat_profile\', \'plugin.php?id=th_chat:profile&uid=' . $r['uid'] . '\');return false;" class="nzchatavatar" onerror="this.src=\'uc_server/images/noavatar_small.gif\';" style="cursor:pointer;">
</div><div style="display:inline-block;margin-left:10px;position:relative;top:-4px;height:30px;"><a class="nznametop2 nzat'.$r['uid'].'" id="nzolpro_' . $r['uid'] . '" onclick="showWindow(\'th_chat_profile\', \'plugin.php?id=th_chat:profile&uid='.$r['uid'].'\');return false;" style="cursor:pointer'.($r['color']?';color:'.$r['color']:'').'">' . $r['username'] . '</a><br>
</div><div style="display:inline-block;margin-left:10px;position:relative;top:-4px;height:30px;"><a class="nznametop2 nzat_'.$r['uid'].'" id="nzolpro_' . $r['uid'] . '" onclick="showWindow(\'th_chat_profile\', \'plugin.php?id=th_chat:profile&uid='.$r['uid'].'\');return false;" style="cursor:pointer'.($r['color']?';color:'.$r['color']:'').'">' . $r['username'] . '</a><br>
<span id="nzchatolr'.$r['uid'].'" style="line-height: 15px;">'.$r['grouptitle'].'</span>
<span id="nzchatolc'.$r['uid'].'" style="display:none;line-height: 15px;">
'.($uid==$r['uid']?'<a href="javascript:void(0);" onclick="showWindow(\'th_chat_setting\', \'plugin.php?id=th_chat:setting\');return false;">ตั้งค่าห้องแชท</a>':'<a href="javascript:void(0);" onclick="nzAt(\''.$r['username'].'\')">@</a> <a href="javascript:void(0);" onclick="nzTouid('.$r['uid'].')">กระซิบ</a>').'
Expand Down
10 changes: 5 additions & 5 deletions th_chat/template/big.htm
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
<!--{subtemplate common/header}-->
<!--{if $chat['guest_show']&&!$_G['uid']}-->
{$chat['guest_show']}
<div style="text-align:right;height:20px;"><span id="n_copyright">&copy; <a href="http://2th.me/" target="_blank">2th Chat</a> <strong>2.18d</strong> by <a href="https://www.chaohost.com/client/aff.php?aff=10" target="_blank">ChaoHost</a></span></div>
<div style="text-align:right;height:20px;"><span id="n_copyright">&copy; <a href="http://2th.me/" target="_blank">2th Chat</a> <strong>2.18e</strong> by <a href="https://www.chaohost.com/client/aff.php?aff=10" target="_blank">ChaoHost</a></span></div>
<!--{else}-->
<script src="source/plugin/th_chat/js/jquery-3.5.1.min.js" type="text/javascript"></script>
<script src="source/plugin/th_chat/js/jquery.timeago.js" type="text/javascript"></script>
<script src="source/plugin/th_chat/js/emoji-button-2.12.1.min.js" type="module"></script>
<link rel="stylesheet" type="text/css" href="source/plugin/th_chat/template/th_chat.min.css?v=218d" />
<link rel="stylesheet" type="text/css" href="source/plugin/th_chat/template/th_chat.min.css?v=218e" />
<div style="width:100%;margin:0 auto;">
<style type="text/css">
#nzchatcontent{
Expand All @@ -30,7 +30,7 @@
reload: {$chat['reload']}
};
</script>
<script src="source/plugin/th_chat/js/th_chat.min.js?v=218d" type="text/javascript"></script>
<script src="source/plugin/th_chat/js/th_chat.min.js?v=218e" type="text/javascript"></script>
<div id="nzchat">
<table id="nzchattable">
<tr>
Expand Down Expand Up @@ -74,7 +74,7 @@
<tr>
<td colspan="2">
<div id="nzalertbox"></div>
<div style="margin-bottom: 2px;display: flex;"><!--{if $showimgup}--><div id="nzimgup" title="อัปโหลดรูปภาพ"></div><!--{/if}--><!--{if $_G['config']['db']['1']['dbcharset'] == 'utf8mb4'}--><div id="nzemoji" title="Emoji"></div><!--{/if}--><input name="mtname" type="text" id="nzchatmessage" maxlength="{$chat['chat_strlen']}" placeholder="กรอกข้อความแล้วกดปุ่ม Enter เพื่อส่งข้อความ"/></div>
<div style="margin-bottom: 2px;display: flex;"><div id="nzimgup" title="อัปโหลดรูปภาพ"></div><!--{if $_G['config']['db']['1']['dbcharset'] == 'utf8mb4'}--><div id="nzemoji" title="Emoji"></div><!--{/if}--><input name="mtname" type="text" id="nzchatmessage" maxlength="{$chat['chat_strlen']}" placeholder="กรอกข้อความแล้วกดปุ่ม Enter เพื่อส่งข้อความ"/></div>
<div class="nztoolbar">
<div style="height:25px">
<script src="static/js/seditor.js" type="text/javascript"></script>
Expand All @@ -84,7 +84,7 @@
<script src="data/cache/common_smilies_var.js?{VERHASH}" type="text/javascript" reload="1"></script>
<script type="text/javascript" reload="1">smilies_show('nzchatsmiliesdiv', 9, 'nzchat');</script>
<input id="nzimgupload" type="file" name="nzimgupload" accept="image/*" data-url="https://www.discuz.in.th/plugin.php?id=th_chat:img">
<div id="nzchatcpy"><span id="n_copyright">&copy; <a href="http://2th.me/" target="_blank">2th Chat</a> <strong>2.18d</strong> by <a href="https://www.chaohost.com/client/aff.php?aff=10" target="_blank">ChaoHost</a></span></div>
<div id="nzchatcpy"><span id="n_copyright">&copy; <a href="http://2th.me/" target="_blank">2th Chat</a> <strong>2.18e</strong> by <a href="https://www.chaohost.com/client/aff.php?aff=10" target="_blank">ChaoHost</a></span></div>
</div>
</div>
<div style="padding-left: 5px" id="nztouid"></div>
Expand Down
10 changes: 5 additions & 5 deletions th_chat/template/discuz.htm
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
<!--{block return}-->
<!--{if $chat['guest_show']&&!$_G['uid']}-->
{$chat['guest_show']}
<div style="text-align:right;height:20px;"><span id="n_copyright">&copy; <a href="http://2th.me/" target="_blank">2th Chat</a> <strong>2.18d</strong> by <a href="https://www.chaohost.com/client/aff.php?aff=10" target="_blank">ChaoHost</a></span></div>
<div style="text-align:right;height:20px;"><span id="n_copyright">&copy; <a href="http://2th.me/" target="_blank">2th Chat</a> <strong>2.18e</strong> by <a href="https://www.chaohost.com/client/aff.php?aff=10" target="_blank">ChaoHost</a></span></div>
<!--{else}-->
<script src="source/plugin/th_chat/js/jquery-3.5.1.min.js" type="text/javascript"></script>
<script src="source/plugin/th_chat/js/jquery.timeago.js" type="text/javascript"></script>
<script src="source/plugin/th_chat/js/emoji-button-2.12.1.min.js" type="module"></script>
<link rel="stylesheet" type="text/css" href="source/plugin/th_chat/template/th_chat.min.css?v=218d" />
<link rel="stylesheet" type="text/css" href="source/plugin/th_chat/template/th_chat.min.css?v=218e" />
<div style="width:100%;margin:0 auto;">
<style type="text/css">
#nzchatcontent{
Expand All @@ -30,7 +30,7 @@
reload: {$chat['reload']}
};
</script>
<script src="source/plugin/th_chat/js/th_chat.min.js?v=218d" type="text/javascript"></script>
<script src="source/plugin/th_chat/js/th_chat.min.js?v=218e" type="text/javascript"></script>
<div id="nzchat">
<table id="nzchattable">
<tr>
Expand Down Expand Up @@ -74,7 +74,7 @@
<tr>
<td colspan="2">
<div id="nzalertbox"></div>
<div style="margin-bottom: 2px;display: flex;"><!--{if $showimgup}--><div id="nzimgup" title="อัปโหลดรูปภาพ"></div><!--{/if}--><!--{if $_G['config']['db']['1']['dbcharset'] == 'utf8mb4'}--><div id="nzemoji" title="Emoji"></div><!--{/if}--><input name="mtname" type="text" id="nzchatmessage" maxlength="{$chat['chat_strlen']}" placeholder="กรอกข้อความแล้วกดปุ่ม Enter เพื่อส่งข้อความ"/></div>
<div style="margin-bottom: 2px;display: flex;"><div id="nzimgup" title="อัปโหลดรูปภาพ"></div><!--{if $_G['config']['db']['1']['dbcharset'] == 'utf8mb4'}--><div id="nzemoji" title="Emoji"></div><!--{/if}--><input name="mtname" type="text" id="nzchatmessage" maxlength="{$chat['chat_strlen']}" placeholder="กรอกข้อความแล้วกดปุ่ม Enter เพื่อส่งข้อความ"/></div>
<div class="nztoolbar">
<div style="height:25px">
<script src="static/js/seditor.js" type="text/javascript"></script>
Expand All @@ -84,7 +84,7 @@
<script src="data/cache/common_smilies_var.js?{VERHASH}" type="text/javascript" reload="1"></script>
<script type="text/javascript" reload="1">smilies_show('nzchatsmiliesdiv', 9, 'nzchat');</script>
<input id="nzimgupload" type="file" name="nzimgupload" accept="image/*" data-url="https://www.discuz.in.th/plugin.php?id=th_chat:img">
<div id="nzchatcpy"><span id="n_copyright">&copy; <a href="http://2th.me/" target="_blank">2th Chat</a> <strong>2.18d</strong> by <a href="https://www.chaohost.com/client/aff.php?aff=10" target="_blank">ChaoHost</a></span></div>
<div id="nzchatcpy"><span id="n_copyright">&copy; <a href="http://2th.me/" target="_blank">2th Chat</a> <strong>2.18e</strong> by <a href="https://www.chaohost.com/client/aff.php?aff=10" target="_blank">ChaoHost</a></span></div>
</div>
</div>
<div style="padding-left: 5px" id="nztouid"></div>
Expand Down

0 comments on commit b374e76

Please sign in to comment.