Div won't close and text is not placed in textarea
<pre><code>function EditorDivOpen(a){
    $('#'+a).show();
}

function EditorDivClose(a){
    $('#'+a).close();
}

function EditorDivFill(a,b){
    var init;
    if(a == 'smileys'){
        init = '&lt;img src="data/img/smileys/sad.png" onclick="EditorTextFill(\':(\');" class="point" alt="smiley"&gt; \
                &lt;img src="data/img/smileys/happy.gif" onclick="EditorTextFill(\':)\');" class="point" alt="smiley"&gt; \
                &lt;img src="data/img/smileys/angelnot.gif" onclick="EditorTextFill(\'0:=)\');" class="point" alt="smiley"&gt; \
                &lt;img src="data/img/smileys/angry.gif" onclick="EditorTextFill(\'=(\');" class="point" alt="smiley"&gt; \
                &lt;img src="data/img/smileys/blush.gif" onclick="EditorTextFill(\':@\');" class="point" alt="smiley"&gt; \
                &lt;img src="data/img/smileys/cencored.png" onclick="EditorTextFill(\':*\');" class="point" alt="smiley"&gt; \
                &lt;img src="data/img/smileys/confused.gif" onclick="EditorTextFill(\':?\');" class="point" alt="smiley"&gt; \
                &lt;img src="data/img/smileys/cry.png" onclick="EditorTextFill(\';(\');" class="point" alt="smiley"&gt; \
                &lt;img src="data/img/smileys/grin.gif" onclick="EditorTextFill(\':D\');" class="point" alt="smiley"&gt; \
                &lt;img src="data/img/smileys/hmm.png" onclick="EditorTextFill(\':|\');" class="point" alt="smiley"&gt; \
                &lt;img src="data/img/smileys/hypocrite.gif" onclick="EditorTextFill(\'0=)\');" class="point" alt="smiley"&gt; \
                &lt;img src="data/img/smileys/lock.gif" onclick="EditorTextFill(\':x:\');" class="point" alt="smiley"&gt; \
                &lt;img src="data/img/smileys/love.gif" onclick="EditorTextFill(\':3\');" class="point" alt="smiley"&gt; \
                &lt;img src="data/img/smileys/sunglasses.gif" onclick="EditorTextFill(\'8)\');" class="point" alt="smiley"&gt; \
                &lt;img src="data/img/smileys/shifty.gif" onclick="EditorTextFill(\'|)\');" class="point" alt="smiley"&gt; \
                &lt;img src="data/img/smileys/shock.gif" onclick="EditorTextFill(\'O_o\');" class="point" alt="smiley"&gt; \
                &lt;img src="data/img/smileys/shock.gif" onclick="EditorTextFill(\':o\');" class="point" alt="smiley"&gt; \
                &lt;img src="data/img/smileys/sweatingbullets.gif" onclick="EditorTextFill(\'^_^\');" class="point" alt="smiley"&gt; \
                &lt;img src="data/img/smileys/tongue.gif" onclick="EditorTextFill(\':p\');" class="point" alt="smiley"&gt; \
                &lt;img src="data/img/smileys/tongue.gif" onclick="EditorTextFill(\':P\');" class="point" alt="smiley"&gt; \
                &lt;img src="data/img/smileys/wink.gif" onclick="EditorTextFill(\';)\');" class="point" alt="smiley"&gt; \
                &lt;img src="data/img/smileys/wry.gif" onclick="EditorTextFill(\'xo\');" class="point" alt="smiley"&gt; \
                &lt;img src="data/img/smileys/wry.gif" onclick="EditorTextFill(\'XD\');" class="point" alt="smiley"&gt; \
                &lt;img src="data/img/smileys/wry.gif" onclick="EditorTextFill(\'xD\');" class="point" alt="smiley"&gt;';
    }
    else
    {
        init = '&lt;img src="data/img/buttons/bold.png" onclick="EditorTextFill(\'[b][/b]\');" class="point" alt="bold"&gt; \
                &lt;img src="data/img/buttons/italic.png" onclick="EditorTextFill(\'[i][/i]\');" class="point" alt="italic"&gt; \
                &lt;img src="data/img/buttons/underline.png" onclick="EditorTextFill(\'[u][/u]\');" class="point" alt="underline"&gt; \
                &lt;img src="data/img/buttons/strike.png" onclick="EditorTextFill(\'[s][/s]\');" class="point" alt="strike"&gt; \
                &lt;img src="data/img/buttons/link.png" onclick="EditorTextFill(\'[url][/url]\');" class="point" alt="Link"&gt; \
                &lt;img src="data/img/buttons/image.png" onclick="EditorTextFill(\'[img][/img]\');" class="point" alt="Image"&gt;';
    }

    init = '&lt;img src="data/img/buttons/remove.png" alt="remove" class="closebutton point" onclick="EditorDivClose(\'edit-content\');"&gt;'+ init;

    $('#'+b).html(init);
}

function EditorTextFill(msg){
    $('#editor-textarea').html() = $('#editor-textarea').html() + msg;
}

            &lt;img src="data/img/smileys/happy.gif" alt="smileys" onclick="EditorDivOpen('edit-content'); EditorDivFill('smileys', 'edit-content');" class="point"&gt;
            &lt;img src="data/img/buttons/bold.png" alt="tags" onclick="EditorDivOpen('edit-content'); EditorDivFill('tags', 'edit-content');" class="point"&gt;
            &lt;div id="edit-content"&gt;
            &lt;/div&gt;

            &lt;textarea cols="60" rows="6" name="message" id="editor-textarea"&gt;&lt;/textarea&gt;&lt;br&gt;
            &lt;input type="submit" value="  submit  "&gt;
</code></pre>

<p>Some of my functions on the code above won't work, those are <code>EditorDivClose()</code> and <code>EditorTextFill()</code>. At both I get the error: </p>

<blockquote>
  <p>this property or method is not supported by this object</p>
</blockquote>

<p>by both at the first $ character.</p>
