populate a textarea using javascript
<p>Basically I am using the SCEditor and want a button on forum posts or articles comments called "Quote" where it grabs the text from the message and pastes it into the textarea, i have this code:</p>

<pre><code>&lt;script type="text/javascript"&gt;
jQuery.noConflict(); //disable global $ for jQuery
jQuery(document).ready(function($){
    $(function(){
    $('#quote').click(function() {
        $('textarea').sceditor('instance').insert("[quote=admin]Some text[/quote]");
    });
    });
});
&lt;/script&gt;
</code></pre>

<p>Now that works, it will put "[quote=admin]Some text[/quote]" into the textarea. Problem is I need that to be dynamic somehow so i don't have to copy that code above every comment if that makes sense? So instead of this:</p>

<pre><code>insert("[quote=admin]Some text[/quote]");
</code></pre>

<p>That section would grab all the text from the box below it? Rather than me manually replacing the quoted bit with the text in the post.</p>

<p>So basically replace the quoted bit above with the contents from different divs based on clicking a Quote link?</p>
