| Loading htmlarea.js and language.js failure ¶ | |
| I have a very suspecious problem, that only happens under IE (Netscape v7.1 is quit ok!): Thanks! Zhu Fei | |
| last |
| Re: Loading htmlarea.js and language.js failure ¶ | |
| This problem is a little odd, but I'm guessing that it is a known bug. I have noticed that the generate method in the examples is frequently called like this: //Generate the HTMLArea control Instead of just calling the generate directly as one might expect: editor.generate() //Generate the HTMLArea control I wondered what the purpose of this was, but I am guessing it is related to the problem you are having. | |
| last |
| Work with moving textareas ¶ | |
| Hi, I've started to bind my CMS with htmlArea to be one available RTE. Now I've started to implement a page editor, that manages several "cells" per page, each having textual content. This editor uses JS to perform basic operations like adding cell or changing order of cells to prevent reload-cycles. Now I came to a point where the whole editor is working without your RTE, but as soon as I'm integrating it the editor gets out of sync with related textarea after moving that one in page. I found your htmlarea div being inserted as preceeding sibling to the related textarea. I think I can exclude any trouble caused by not moving that div as well, here, since I'm always moving divs containing divs which in turn contain either text, inputs or textareas. So your HTMLarea div should be moved as well automatically. After moving, the htmlarea is still rendered at new position of related textarea, but it neither contains the text found in underlying textarea, nor does it accept any other input or command than "wysiwyg on/off" without exception arising. Caret is missing. I've tried to take a look into your sources at htmlarea.js and found the things you do in HTMLArea.prototype.generate. Nevertheless I can't find any short solution on how to get both elements back into sync. Any help from you is highly appreciated ... Thanks in advance, PS: I prefer to provide both MSIE and FF, but currently I'm testing with FF, only! | |
| last |
| Re: Work with moving textareas ¶ | |
| Thomas, I believe I understand your problem. I am actually planning on using HTMLArea for something similar in the near future, so I have a vested interest in figuring this out. ;-) So you have the HTMLArea control being correctly relocated on the page (visually), but it is losing its content and generating exceptions. First question: Have you downloaded the latest version from the Sourceforge CVS? (If not, I posted instructions on how to do this just a few threads back.) If you have not yet done this, give it a try. Several small "quirks" have been fixed in the latest update. If this doesn't work, is there any way you can show me a portion of your JS to move the textarea/htmlarea around on the page? It would be easier to help figure out how to solve the problem if I can see exactly what is happening. -Michael | |
| last |
| Upgrade not working ¶ | |
| I just upgraded my sites setup from HTMLarea v2.03 and can't get v3 rc-1 working. I want to use the new version so Firefox works on my page. I replaced all the content of my htmlarea directory and made the small javascript changes as documented to my page. I have copied the core.html page into the same dir as my page adjusted the path directives and it works so the directives should be OK. Any suggestions? I can post the full code of my page if it will help. | |
| last |
| Re: Upgrade not working ¶ | |
| First of all, let me point you to an earlier post where I provide directions for downloading the latest version of the HTMLArea 3.0 source: http://www.dynarch.com/forums/776. There are some major improvements to this version compared to the latest release version available for download from this site. (Please note that this latest version requires you to call HTMLArea.init() before attempting any textarea replacements.) Next, are you receiving any error message, or is it simply that nothing is happening? Here is some example code that should work. Note that I have htmlarea installed into an "htmlarea" directory in the root of my site.
<html> If you need more help with this, if you can provide either specific error messages or some code samples I would be able to be more helpful. :-) -Michael | |
| last |
| Cannot pass changed content in form ¶ | |
| Hi I'm trying to get HTMLArea working in my PHP site. The user is presented with existing content, which they will change, and it's that changed material which I need to pass through to my PHP. Here's what my script looks like right now: <html><head><title>Test</title> function submitform() { </script> <?php <form id="editform" name="editform" action="testsite.php?commit=TRUE" method="post"> However, $_POST['mytext'] only recovers the <i>original</i> content, not any changes. I've tried adding each of the following lines to my submitform() function to try to collect the new content and move it to a hidden form value, but nothing works. Here's what I've tried (using FF 1.0.4 on Mac OS X 10.4) newcontent = editor.getHTML(); Each of those tries is followed by alert(newcontent) to show me the content before it gets submitted. I get errrors such as "editor has no properties" and "getHTML is not a function". Does anyone have any ideas how I can get my content passed through successfully? Many thanks. Matt | |
| last |
| Re: Cannot pass changed content in form ¶ | |
| My first comment, while not a complete solution, is that using a standard submit button works, while the javascript submit code does not. I have a similar test page set up, and have been working with: <input type="submit" name="action" value="Preview" /> I had not thought about doing a link to a javascript function. I tried putting: <a href="" onclick="self.document.testform.submit(); return false;">Preview</a> in as a test, but it failed to submit changes (it did submit the original code, however). I did some experimenting, and discovered why the javascript submission method does not work. For some (odd) reason, it fails to trigger the onsubmit event for the form. HTMLArea relies on this event to perform pre-submission processing. I am not sure *why* the event doesn't trigger, but because it doesn't we need to work around it. (Note that the event didn't trigger in my own custom test, even leaving HTMLArea out of the picture.) In order to fix the problem, I had to use an <input> element to submit the form. I added onsubmit="return beforeSubmit();" to my <form>, which allows me to add any processing code I want to the beforeSubmit() javascript function: function beforeSubmit() {HTMLArea automatically interrupts the onsubmit event and updates the textarea with any changes, and then makes sure that all other onsubmit handlers get called, so this should always work. (I still have no idea why document.formname.submit() fails to trigger the onsubmit event -- it didn't trigger my beforeSubmit() function either, which seems a bit broken to me. This is a browser issue though, not an HTMLArea issue.) I hope this helps! | |
| last |














