Thanks a lot for replying to my question! I actually could insert images into the integrated gallery; but when it came to inserting an image from the gallery to post body, nothing happened except for an "Error on page" indicated by IE browser. The error looks like this:
Error: 'dnn_ctr375_Forum_PostEdit_teContent_teContent_designEditor' is null or not an object
I decided to trace the error down. This is what I found:
An image on the window which is popped up by clicking on the "Insert Image" button is a link that looks like this:
<a id="dlStrip_ctl00_lnkFullSize" title="Insert full zise image into post body..." class="Forum_AltHeaderText" href=" window.opener.SetParentValue('Form','','rockpray.jpg','<IMG src=\"http:\/\/www.makeaband.com\/thanglong\/Portals\/0\/ForumImage\/rockpray.jpg\" \/>','body');">rockpray</a>
So it called a javaScript function SetParentValue in the originating page which contains this codes:
<script src="/thanglong/js/dnncore.js" type="text/javascript"></script><script language="JavaScript">
var popUp;
function OpenNewWindow(url, params, postBack)
{
popUp = open(url + "&formname=" + document.forms[0].name, 'forum', params);
}
function SetParentValue(formName, targetID, image, mediaURL, type)
{
if(type == "header")
{
var media = document.getElementById(targetID);
var mediaHolder = media.parentElement.parentElement;
var mediaFile = mediaHolder.firstChild.firstChild.firstChild;
media.innerHTML = mediaURL;
mediaFile.value = image
}
else
{
this.dnn_ctr375_Forum_PostEdit_teContent_teContent_designEditor.focus();
sel = this.dnn_ctr375_Forum_PostEdit_teContent_teContent_designEditor.document.selection.createRange();
sel.pasteHTML(mediaURL);
}
popUp.close();
}
</script>
There I found the line of code that causes the "null or not an object" error.
As a side note, "Insert Image" button is available when we choose a specific item in the Gallery Image drop down list under Forum Administrations>> Gallery & Emoticons.
Hope this would help for future version of the Forum module. Thank you for reading up to this line!