1. Добавить в editor.js:di-pil писал(а):как сделать так, чтобы при нажатии на кнопку "Цитата", не выбирая текст, весь текст вставлялся в БО
Код: Выделить всё
function addquote_topic(post_id, username) {
var theSelection = '';
var divarea = document.getElementById('pc' + post_id);
if (document.all)
theSelection = divarea.innerText;
else
theSelection = divarea.textContent;
if (theSelection)
insert_text('[quote="' + username + '"]' + theSelection + '[/quote]');
return;
}Код: Выделить всё
<a href="{postrow.U_QUOTE}" title="{L_REPLY_WITH_QUOTE}">Код: Выделить всё
<a href="{postrow.U_QUOTE}" onclick="show_qr(true); addquote_topic({postrow.POST_ID}, '{postrow.POST_AUTHOR}'); return false;" title="{L_REPLY_WITH_QUOTE}">Код: Выделить всё
<div class="content"Код: Выделить всё
<div id="pc{postrow.POST_ID}" class="content"

