Еще и его проблемы со спектрумом решаю, ага.deathsoft wrote:Ты скрипты разреши. И чтобы сделать квоту, надо текст выделить вышью, а потом нажать кнопку Quote.
ShadowMaker wrote:Да, чет я забыл, что в phpbb всё не как у других.
function get_selection()
{
    if (window.getSelection)
    {
        sel_txt = window.getSelection().toString();
    }
    else if (document.getSelection)
    {
        sel_txt = document.getSelection();
    }
    else
    {
        sel_txt = document.selection.createRange().text;
    }
}
function Insert(qname,text)
{
    if (text!="")
    {
        qname=qname.replace(/[\[\]]/g, "|");
        paste("[quote=\""+qname+"\"]"+text+"[/quote]\n", 0);
    }
}
function paste(text,flag)
{
    if ((document.selection)&&(flag))
    {
        document.forms['postform'].message.focus();
        document.forms['postform'].document.selection.createRange().text = text;
    }
    else
        document.forms['postform'].message.value += text;
}
<!-- IF postrow.U_QUOTE --><li class="quote-icon"><a href="javascript:Insert('{postrow.POST_AUTHOR}',sel_txt);" onmouseover="get_selection();" title="{L_REPLY_WITH_QUOTE}"><span>{L_REPLY_WITH_QUOTE}</span></a></li><!-- ENDIF -->
Users browsing this forum: No registered users and 10 guests