Forum OpenACS Q&A: Re: Question about html area

Collapse
Posted by Deds Castillo on
Miguel,

Dave asked me to look into this.  It's actually caused by several different things.  Here's a rundown.  Please try to apply it to your codebase and confirm so that necessary changes can be done on CVS as well.

1. htmlarea only copies to the form element when using its own submit button.  Fortunately, it has a method to get its contents -- objectname.getHTML() which should probably replace your document.message.content.value.  Lars used a global variable acs_blank_master__htmlareas which you can probably reference to get the object name.

2. The above will work on straight up integration, you can try it out by modifying /acs-templating/www/resources/htmlarea/example.html file.  But for OpenACS ATS there are some bugs that needs to be fixed to make it work.  This is because the htmlarea variable is passed to acs_initHtmlArea by value and not by reference making the calling page see the object as NULL instead of the actual htmlarea object.

I've fixed #2 on oacs-5-1 branch.