mirror of
https://github.com/torrentpier/torrentpier
synced 2025-08-22 06:13:58 -07:00
r203
git-svn-id: https://torrentpier2.googlecode.com/svn/trunk@203 a8ac35ab-4ca4-ca47-4c2d-a49a94f06293
This commit is contained in:
parent
2cf6ca2116
commit
5fbac089b9
2 changed files with 5 additions and 3 deletions
|
@ -97,7 +97,7 @@ switch($this->request['type'])
|
||||||
case 'editor':
|
case 'editor':
|
||||||
if(!$post) $this->ajax_die($lang['NOT_POST']);
|
if(!$post) $this->ajax_die($lang['NOT_POST']);
|
||||||
|
|
||||||
if(mb_strlen($post['post_text'], 'UTF-8') > 1000)
|
if((mb_strlen($post['post_text'], 'UTF-8') > 1000) || $post['post_attachment'] || ($post['topic_first_post_id'] == $post_id))
|
||||||
{
|
{
|
||||||
$this->response['redirect'] = make_url('posting.php?mode=editpost&p='. $post_id);
|
$this->response['redirect'] = make_url('posting.php?mode=editpost&p='. $post_id);
|
||||||
}
|
}
|
||||||
|
@ -189,7 +189,7 @@ switch($this->request['type'])
|
||||||
<input type="button" value="'.$lang['LIST'].'" name="codeList" title="'.$lang['LIST_TITLE'].'" style="width: 58px;" />
|
<input type="button" value="'.$lang['LIST'].'" name="codeList" title="'.$lang['LIST_TITLE'].'" style="width: 58px;" />
|
||||||
<input type="button" value="1." name="codeOpt" title="'.$lang['LIST_ITEM'].'" style="width: 30px;" />
|
<input type="button" value="1." name="codeOpt" title="'.$lang['LIST_ITEM'].'" style="width: 30px;" />
|
||||||
<input type="button" value="'.$lang['QUOTE_SEL'].'" name="quoteselected" title="'.$lang['QUOTE_SELECTED'].'" onmouseout="bbcode.refreshSelection(false);" onmouseover="bbcode.refreshSelection(true);" onclick="bbcode.onclickQuoteSel();" />
|
<input type="button" value="'.$lang['QUOTE_SEL'].'" name="quoteselected" title="'.$lang['QUOTE_SELECTED'].'" onmouseout="bbcode.refreshSelection(false);" onmouseover="bbcode.refreshSelection(true);" onclick="bbcode.onclickQuoteSel();" />
|
||||||
|
|
||||||
<input type="button" value="'.$lang['TRANSLIT'].'" name="Translit" title="'.$lang['TRANSLIT_TITLE'].'" style="width: 68px;" onclick="transliterate(document.post.message, this);" />
|
<input type="button" value="'.$lang['TRANSLIT'].'" name="Translit" title="'.$lang['TRANSLIT_TITLE'].'" style="width: 68px;" onclick="transliterate(document.post.message, this);" />
|
||||||
</div>
|
</div>
|
||||||
<textarea id="message-'. $post_id .'" class="editor mrg_4" name="message" rows="18" cols="92">'. $post['post_text'] .'</textarea>
|
<textarea id="message-'. $post_id .'" class="editor mrg_4" name="message" rows="18" cols="92">'. $post['post_text'] .'</textarea>
|
||||||
|
|
|
@ -48,7 +48,9 @@ ajax.callback.posts = function(data) {
if(data.html){
|
||||||
$('#pe_'+ data.post_id).html(data.text);
|
$('#pe_'+ data.post_id).html(data.text);
|
||||||
}
|
}
|
||||||
if(data.redirect) document.location.href = data.redirect;
|
if(data.redirect) document.location.href = data.redirect;
|
||||||
if(data.hide) $('tbody#post_'+ data.post_id).hide();
|
if(data.hide) {
if(ajax.open_edit == data.post_id) ajax.open_edit = false;
|
||||||
|
$('tbody#post_'+ data.post_id).hide();
|
||||||
|
}
|
||||||
if(data.quote) $('textarea#message').attr('value', $('textarea#message').val() + data.message +' ').focus();
|
if(data.quote) $('textarea#message').attr('value', $('textarea#message').val() + data.message +' ').focus();
|
||||||
if(data.message_html){
|
if(data.message_html){
|
||||||
$('#view_message').show();
|
$('#view_message').show();
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue