Hi George,
Yes we activated by default tidy from Jahia 4.0.5 because we also needed it for other things (for example to automatically parse the content of the big texts, detects the internal "hardcoded" Jahia links and then make a warning if you delete a page which still has a cross-link within a big text).
Regarding Tidy and all these WYSIWYG HTML editors, this is a complex topic. First of all the Java version of tidy (jtidy) was not updated and maintained from 2001 or something like that. Several tests are then not in synch with the official tidy library. This is an open source project, so feel free to help the new team which now tries to reorganize a bit the jtidy project. On the WYSIWG side, there are dozens (I should say hundreds) of them available. Some are free (like HTMLArea), other are commercial (Like RealObjects Edit-on Pro which is also pre-customized with Jahia). Some are only working with IE. Others only with Firefox. Some only on Windows. Others on all platforms. Some are "cleaning" and"correcting" a bit too much the transmited HTML, others let all the HTML errors and this may then corrupts the underlying Jahia HTML page, etc... So we decided to develop a quite generic API to let each customer decide which is the best WYSIWYG editor he wants to use and/or to activate severla editors simultanesouly (or according to certain rules, for example IE client may use this editor and Firefox client another one). In all the case, Jahia may launch tidy in the back-end (even if a tidy was already used on the browser side in the WYSIWYG editor applet for example) to try to insure that the HTML code is not too bad and will not corrupt the underlying Jahia page. Of course you can desactivate this option.
Now if you really want to display your own complex HTML content, please rather use WebDAV and directly store your HTML files therein (for example check the HTML File Clipping template which is available in Jahia 4.0.5). Then you may directly edit your HTML content from any WebDAV compliant program (e.g. Dreamweaver), save it in the Jahia file repository and this will be automatically integrated within a page. Quite useful also if you want to let your users directly save their word file (saved in HTML) and upload it directly in Jahia.
Finally HTMLArea 3.0 is not in a final realease yet. The beta version we integrated was working quite nicely for all the basic edition stuff (and was working better than the previous editor we packaged) so we decided to integrate it already in the 4.0.5 release. Now of course it does not replace a real commercial WYSIWYG editor.
Cheers St�phane
At 22:57 02/03/2005, you wrote:
More information on this that makes this less critical but still an issue: In my jahia 404 installation, the HTML editor markup and tidy features seemed to be switched off by default so I did not realize this feature was there ... another newbie issue - sorry!
However in 405, these are turned on and so I ran into this. Once these are unchecked, things behave much better and I can accomplish the scripting that I need. However, it is still the case that when I paste something with a script into the content area, I cannot later update it since what is displayed in the editor (simple text as well as HTMLArea) is not the same. What I see is:
<input onclick="function anonymous() { function anonymous() { function anonymous() { executeCommands(); } } }" type="button" name="cmdNote" />
However, when I view the source of the saved page, it is correct. This means that it is a "write-only" exercise to add complex HTML source fragments and therefore the source for these have to be maintained outside of Jahia - not very satisfactory for content management.
George.
-----Original Message----- From: George Myers [mailto:[EMAIL PROTECTED] Sent: Friday, February 25, 2005 10:13 AM To: [email protected] Subject: RE: Jahia405 simple text editor question
Tried "toggle HTML source" mode of the HTMLArea editor and of the ActiveX editor. It does not help - the result is still a javascript error when the content is saved and the page is refreshed. Then when I view the content in the the HTMLArea editor in source mode, or in the simple text editor, I see the function is wrapped in a CDATA section. This starts to look like something that has changed somewhere deeper than the editor. Any further suggestions or work arounds (for example, where can I go to look at the saved HTML and perhaps remove the CDATA manually).
-----Original Message----- From: Serge Huber [mailto:[EMAIL PROTECTED] Sent: Friday, February 25, 2005 2:34 AM To: [email protected] Subject: Re: Jahia405 simple text editor question
Hi George,
Maybe you could try using the <HTML> mode of one of the new editors (such as HTMLArea) to solve your problem ?
Regards, Serge Huber.
George Myers wrote:
>In Jahia 405, can anyone suggest how to embed javascript script in HTML >using the "add text" >function other than putting it inline directly on the "onclick" event >of a link or control. >The latter is is fine for very simple things but is difficult to work >with for anything more complex. Is there any way to prevent the CDATA >modification to the script. > >In the 404 version I was able to "add text" by pasting in html using the >simple text editor. When saved the content looked as expected. There was >a drawback >in that the content could not be edited so you needed to delete and >re-create when changing. What also was allowed was the use of embedded >script fragments. >This allows >doing very useful things like launching desktop programs on the >intranet from a button on the portal. The simple file shown below >could be pasted in as-is, complete with <html> tags >and it worked out fine. Now it creates a syntax error in IE version 6 that >is >caused by wrapping the function in a CDATA section like: > ><script type="text/javascript"> ><![CDATA[ >function executeCommands() >{ > alert("here"); >} >]]> ></script> > >Here is the original script. >----------------- ><html> ><body> > ><script> >function executeCommands() >{ > alert("here"); >} ></script> ><CENTER> >Boilerplate ><INPUT onclick=executeCommands(); >type=button value="Run script" name="cmdNote"> </CENTER> > ></body> ></html> >------------ > >George Myers > > > >
