PDA

View Full Version : multiple qoute hack, help me finish it


Zoinks
09-27-2002, 04:02 PM
My users asked me of I could make some changes so that they could quote multiple messages in 1 post.

I made a quote butten in threadreviewbit next to every post
like this:

<a href="$quotepost"><img border="0" src="{imagesfolder}/quote.gif" width="18" height="13"></a>


I also made quote.js like this.

function quote(quote) { //adds the selected quote to the message field
document.vbform.message.value += quote+"\n";
document.vbform.message.focus();
}


then I changed newreply.php next to line 470 or so to this:

$reviewmessage = bbcodeparse($post[pagetext],$threadinfo[forumid],$post[allowsmilie]);
}
$quotepost = 'javascript:quote(\'\n'.$username.' wrote:\n'.$post[pagetext].'\n\')';
eval("\$threadreviewbits .= \"".gettemplate("threadreviewbit")."\";");
} else {
break;
}


Ok, now.. what all this should do is the following. A user clicks on the button and the javascript directly puts the quoted text in the $message field. This kinda works... the only problem is that it does not functions completely right. the text does not contain anymore blank lines or new lines. I also installed the /me tag and it also doesn't work anymore..

can anyone help me?
replacing $post[pagetext] with $message or $reviewmessage does not work well also

Zoinks
09-27-2002, 04:03 PM
humz.. the php is not right... it leaves out the slashes before the n

Xenon
09-27-2002, 04:12 PM
are you using Chens hack?
https://vborg.vbsupport.ru/showthread.php?s=&threadid=36896

Zoinks
09-27-2002, 04:17 PM
Nope. I don't want to use the checkbox hack. The way I try to make it uses javascript to instert the posts directly in the message field. Just like the insertion of smilies.