Hi.

I'm trying to create some popup windows for some additional information about my site. I've been experimenting on my testbed xampp site using my (very) limited javascript knowledge.

This the code I've been using to go into define_main_page.php via the editor in admin/tools.

<a href="javascript: void(0)"
onclick="window.open('http://localhost/mainwebsite/includes/languages/english/my_template/popup.html',
'windowname1',
'width=100, height=45');
return false;">Click here for simple popup window</a>


The first time I click on the link the popup opens ok. If I then go back into the editor to change something, for instance the window size, and try again the popup no longer works. Returning to the editor I find that the toggle between html and plain text no longer works and the code has "changed" to

<a onclick="function onclick(event) {
window.open("http://localhost/mainwebsite/includes/languages/english/my_template/popup.html", "windowname1", "width=100, height=100");
return false;
}" href="javascript: void(0)">Click here for simple popup window</a>


What is going on here?

Many thanks in advance.

Philip