Project

General

Profile

Actions

Bug #19103

closed

RTEhtmlarea not loading after upgrade to 4.2.1

Added by Erik Bartos almost 16 years ago. Updated about 14 years ago.

Status:
Closed
Priority:
Should have
Category:
-
Target version:
-
Start date:
2008-07-14
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
PHP Version:
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

After upgrading typo3 source from version 4.1.1 to 4.2.1 the RTEhtmlarea is not loading in Opera 9.51 and also Mozilla Firefox 3.0, only IE7 works. Before upgrade, all mentioned browsers works, now when trying to edit some page content element with RTEhtmlarea, it freezes or give "fatal error" with exhausted php memory. I've tried tinyRTE extention instead, it works. However, RTEhtmlarea has more functions, so it will be better choice.

(issue imported from #M8963)


Files

rtehtmlarea_bugfix_8963.patch (1.33 KB) rtehtmlarea_bugfix_8963.patch Administrator Admin, 2008-08-18 17:14

Related issues 1 (0 open1 closed)

Related to TYPO3 Core - Bug #20976: htmlArea RTE displays empty editing area in Opera 10ClosedStanislas Rolland2009-09-02

Actions
Actions #1

Updated by Erik Bartos almost 16 years ago

Good news, I've found out, the setting for RTEhtmlarea called "Enable compressed scripts" must be unchecked, then the RTE works in all browsers.

Actions #2

Updated by Kurt Ludikovsky almost 16 years ago

I can confirm Eric' workaround, but I needed to logout-in to make it work.

Further I found that
Opera reports the following error in the Error Window:

JavaScript - http://www.mydomain.tld/typo3/alt_doc.php?returnUrl=db_list.php%3Fid%3D1328%26table%3D%26imagemode%3Don&edit[tt_content]1793=edit
Timeout thread: delay 50 ms
Error:
name: TypeError
message: Statement on line 63: Cannot convert undefined or null to Object
Backtrace:
Line 63 of linked script http://www.mydomain.tld/typo3temp/rtehtmlarea/htmlarea_4f86f87bfe8d502067ea_compressed.js
HTMLArea._appendToLog("[HTMLArea::initIframe]: Stylesheets successfully loaded.");if(!this.config.fullPage){doc.body.style.borderWidth="0px";doc.body.className="htmlarea-content-body";try{doc.body.innerHTML=this._textArea.value;}catch(e){HTMLArea._appendToLog("[HTMLArea::initIframe]: The HTML document is not well-formed.");alert(HTMLArea.I18N.msg["HTML-document-not-well-formed"]);docWellFormed=false;}}
Line 59 of linked script http://www.mydomain.tld/typo3temp/rtehtmlarea/htmlarea_4f86f87bfe8d502067ea_compressed.js
HTMLArea._appendToLog("[HTMLArea::initIframe]: Editor iframe head successfully initialized.");this.stylesLoaded();}
Line 50 of linked script http://www.mydomain.tld/typo3temp/rtehtmlarea/htmlarea_4f86f87bfe8d502067ea_compressed.js
function(editorNumber){var editor=RTEarea[editorNumber]["editor"];editor.initIframe();}
Line 1 of unknown script
HTMLArea.initIframe(1);
stacktrace: n/a; see 'opera:config#UserPrefs|Exceptions Have Stacktrace'


Maybe this helps someone in resoltving the issue.

Actions #3

Updated by Stanislas Rolland almost 16 years ago

I am unable to reproduce this issue in FF3 or Opera 9.51.

Actions #4

Updated by Kurt Ludikovsky almost 16 years ago

It does not appear in FF2.x !
Haven't tested it with FF3 yet.

Have you been working for some time with Opera, or just tried once?
I just tried it again:
  • Opened a text content element -> Editor worked ok
    (since I have not used HTMLarea for some time.)
  • switched to another content element -> Editor froze.

Error Window #######
JavaScript - http://www.mydomain.tld/typo3/alt_doc.php?returnUrl=db_list.php%3Fid%3D1303%26table%3D%26imagemode%3Don&edit[tt_content]1726=edit
Timeout thread: delay 50 ms
Error:
name: TypeError
message: Statement on line 1086: Cannot convert undefined or null to Object
Backtrace:
Line 1086 of linked script http://www.mydomain.tld/typo3temp/rtehtmlarea/htmlarea_4f86f87bfe8d502067ea.js
doc.body.style.borderWidth = "0px";
Line 1052 of linked script http://www.mydomain.tld/typo3temp/rtehtmlarea/htmlarea_4f86f87bfe8d502067ea.js
this.stylesLoaded();
Line 983 of linked script http://www.mydomain.tld/typo3temp/rtehtmlarea/htmlarea_4f86f87bfe8d502067ea.js
editor.initIframe();
Line 1 of unknown script
HTMLArea.initIframe(1);
stacktrace: n/a; see 'opera:config#UserPrefs|Exceptions Have Stacktrace' ######################

Now if tried to track the issue down, by using the Opera developer tools. The first time it broke on the indicted statement, but I could not identify the cause. It seemed that the invalid element was there correctly. But I I can't confirm this for 100%.

When I further tried to track the issue down having the script source shown, with break on error. the same page works fine. If I switch off the developer tools the editor page stalls.

Not easy to identify. Especially as I am not a pro in web development.

I'll report further if I can identify more.

Actions #5

Updated by Stanislas Rolland almost 16 years ago

No, I am unable to reproduce in Opera 9.51.

Please try to clear the TYPO3 configuration cache, delete all files in typo3temp/rtehtmlarea and clear the browser cache.

Actions #6

Updated by Erik Bartos almost 16 years ago

I've done another attemp. On system Fedora 9 with more or less default settings (java, php, mysql, etc...) I've installed new Typo3 4.2.1 version, only with basic system extentions. Again, in Opera 9.51 (Firefox 3.0.1 as well) running under WindowsXP or Fedora, htmlArea RTE doesn't load if option "Enable compressed scripts" is checked. Without this option it works fine.

The "reason" is not exhausted php memory as before, but something like.
"You tried to access the address http://*******/typo3/alt_doc.php?returnUrl=db_list.php%3Fid%3D79%26table%3D&edit[tt_content]205=edit, which is currently unavailable. Please make sure that the Web address (URL) is correctly spelled and punctuated, then try reloading the page."
I'm not so good in debuging browser errors, so cannot help you more.

Actions #7

Updated by Stanislas Rolland almost 16 years ago

@Erik: Did you clear the TYPO3 configuration cache, delete all files in typo3temp/rtehtmlarea and clear the browser cache?

The "reason" does not make any sense to me and does not seem RTE-related. Perhaps a server configuration issue? A security issue?

Actions #8

Updated by Erik Bartos almost 16 years ago

Of course, all caches've been cleaned. I'm using Typo3 3-4 years, so I've know some tricks connected with Typo3 installation :-)
Maybe you are right, that RTE is not related with this bug, after all it works with unchecked option. But as I wrote, the first case was pure update, without any changes in server configuration (php, apache...), such behaviour of Typo3 seemed to me strange and it was reason why I wrote my contribution. In the second case, the server configuration is slightly different, there are all new versions of php, mysql,...its new distribution Fedora 9.
I don't exactly understand what happens when the "compressed scripts" are enabled, maybe it's connected with javascript or so...Till the RTE works with this option disabled it's not such big disaster for me :-)

Actions #9

Updated by Stanislas Rolland almost 16 years ago

The compressed scripts do work in my instances of Opera 9.51 and Firefox 3. So it is not a matter of javascript. Since the RTE is working with uncompressed scripts, the only reason I can think is that the compressed scripts are not the right ones. Please confirm that you have deleted all files in typo3temp/rtehtmlarea.

Actions #10

Updated by Erik Bartos almost 16 years ago

I can confirm everytime I delete files in typo3temp/rtehtmlarea and clear cache of Typo3, then enable/disable compresses script option and see if I can edit existing content elements with RTE and if new elements can be added to the page. I'll perform other searches later...

Actions #11

Updated by Stanislas Rolland almost 16 years ago

hmm... maybe the compressed scripts are not written at all? Try to enable compressed scripts, and then try to use the RTE. Then do you have any files with names ending with compressed.js in typo3temp/rtehtmlarea?

Actions #12

Updated by Erik Bartos almost 16 years ago

No, there are no files in typo3temp/rtehtmlarea, nor *compressed.js nor others (all where erased before I enabled compressed scripts option)

Actions #13

Updated by Stanislas Rolland almost 16 years ago

Make sure that permissions on directory typo3temp/rtehtmlarea are set to 0755.

Actions #14

Updated by Stanislas Rolland almost 16 years ago

Hi Erik,

Please let me know if permissions on directory typo3temp/rtehtmlarea are set to 0755.

Actions #15

Updated by Erik Bartos almost 16 years ago

Yeh, the permissions are 757. I cannot answer, upcoming week also. But at the end I'll write my observations... Maybe, if you give me some hint what "compressed scripts" do, or what they change in the settings, may show me the way where the investigations can be perform...

Actions #16

Updated by Stanislas Rolland almost 16 years ago

The RTE scripts are cached to typo3temp/rtehtmlarea, they are re-cached when the version of the RTE changes. Compressed scripts are compressed JavaScript in which comments, unessential spaces, etc. are removed so that they be faster to load. Scripts are dynamically compressed on the server.

Actions #17

Updated by Dmitry Dulepov almost 16 years ago

I actually had the problem with compressed scripts too. It happens in some browsers. I do not remember details :( But it did not work for some editors and worked for others.

Stanislas, do you use t3lib_div::minifyJS() for compressing scripts?

Actions #18

Updated by Stanislas Rolland almost 16 years ago

Dmitry, yes, the scripts are compressed with t3lib_div::minifyJS().

If this is browser-dependant, it would have to be caused by some peculiar browser configuration, because it works for me and for many other users in all supported browsers.

Maybe a security issue.

Actions #19

Updated by Stanislas Rolland almost 16 years ago

Maybe a timing issue. Perhaps, the body of the document is not yet available.

Actions #20

Updated by Stanislas Rolland almost 16 years ago

Please try the attached patch. After applying the patch, before testing, you need to delete all files in typo3temp/rtehtmlarea and clear the browser cache.

Actions #21

Updated by Erik Bartos almost 16 years ago

All done as you wrote, without positive effect. Patch doesn't help me. I'm preparing another fresh installation of Typo3 v4.2.1, I'll send you the result.

Actions #22

Updated by Stanislas Rolland over 14 years ago

@Erik: Is this still an issue?

Actions #23

Updated by Stanislas Rolland about 14 years ago

No feedback. Closing the issue.

The problem with Opera may have been related to timing-related issue #11847, now fixed.

Actions

Also available in: Atom PDF