I made this PHP chatbox which supports some JavaScript code.
I have these 'images' which if you click them make special codes inside the textfield. e.g:
<head>
<script language="javascript">
function addCode(code)
{
document.writeform.bericht.value+=code;
document.writeform.bericht.focus();
}
</head>
<body>
<a
href="#"
onclick="addCode('<a href="http://www.your-link.com">Your-Text</a>');"
><img src="img.gif" /></a>
</body>
Which would put the HTML link code into the textfield so the user can edit this easily.
Now I have this popup which needs to do the same thing as before, but because it's in a new window it needs to talk to the other page (chatbox.php).
How can I do it?