MyBB Community Forums

Full Version: How I can insert into the textarea ( very important to me )
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hello,

I managed to add a button that popup new window to the codebuttons

but the problem is my popup window contains some pictures and I don't know how I can make them like ( smiles ) when clicked a link or phrase is inserted into the textarea

I used the following code but no luck
onclick="insert();"

<script language="JavaScript">
function insert() {
      window.opener.document.getElementById("message").value='whatever';
      window.close();
 }
</script>
Please assist me in this

Thank you in advance,
Hello,

problem solved by using this code
<script language="JavaScript">
function insert() {
      window.opener.textInput.value+="Whatever";
      window.close();
 }
</script>

Thank you,