Closed Bug 317725 Opened 19 years ago Closed 13 years ago

opensourcecms.com - Joomla WYSIWYG editor does not work in Firefox 1.5

Categories

(Tech Evangelism Graveyard :: English US, defect)

x86
Windows XP
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED INCOMPLETE

People

(Reporter: bulk, Unassigned)

References

()

Details

User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.8) Gecko/20051107 Firefox/1.5
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.8) Gecko/20051107 Firefox/1.5

With the latest firefox, the WYSIWYG editor in the popular Joomla CMS system is not functional

Reproducible: Always
Follow the link and choose the admin demo, login user admin, password demo, choose new content. 

Confirmed works in FF1.0.7, fails in FF1.5 on WinXP. In FF1.5, there are cross domain access errors which appear to cause the page to repeatedly attempt to reload.

It appears the document at demo.opensourcecms.com (with same document.domain) attempts to access content at www.opensourcecms.com. Why would that have worked at all even in 1.0?

Is this just an evangelism issue?
> attempts to access content at www.opensourcecms.com.

Access how, exactly?
Exception ``Permission denied to get property HTMLDocument.getElementsByTagName'' thrown from function anonymous(editor_id=string:"mce_editor_1") in <http://www.opensourcecms.com/demo/joomla/mambots/editors/tinymce/jscripts/tiny_mce/tiny_mce.js> line 9.

     function (editor_id) {
     2         var inst = tinyMCE.instances[editor_id];
 -   3         var doc = inst.getDoc();
 -   4         var head = doc.getElementsByTagName("head").item(0);

in venkman's interactive window:
0001: document.location.href
$[0] = [string] "http://demo.opensourcecms.com/joomla/administrator/index2.php?option=com_content&sectionid=0&task=new"
0001: document.domain
$[1] = [string] "demo.opensourcecms.com"

doc.location.href is "http://www.opensourcecms.com/demo/joomla/mambots/editors/tinymce/jscripts/tiny_mce/blank.htm"

I don't see why this should have worked in 1.0.7 either, but it does. I assume this is evangelism, but want confirmation just in case I am wrong.
Er... that should SO not be working in 1.0.7.   If it is, we clearly have a security issue on that branch, as far as I can tell.
The problem is as descibed here:

http://forum.joomla.org/index.php/topic,22051.0.html

In my case, the editor works but not function properly (only the save button works)
Hmmm, I'm tinkering with this on my Mac (Tiger 10.4.3/Apache1.3.33), trying to access via FireFox 1.5 [Mozilla/5.0 (Macintosh; U; PPC Mac OS X Mach-O; en-US; rv:1.8) Gecko/20051111 Firefox/1.5] and having no luck currently. Basically, the doc.location.href in the below script is only work after a reload from the page it came from.

[1] This is a local site on my computer. So I've defined joomla to access it via the IP number. There is no 'www' involved--the url is http://10.0.0.10/joomla.

[2] Oddly enough, reloading the page after reaching it will result in a properly inited editing window. I am allowed to edit and Apply EXACTLY ONCE. Then I have to reload the page to make more edits.

[3] The offending code block is this:

if(!tinyMCE.isMSIE&&doc.title!="blank_page"){
// The following line doesn't execute consistently--only after a reload
doc.location.href=tinyMCE.baseURL+"/blank.htm";
window.setTimeout("tinyMCE.setupContent('"+editor_id+"');",1000);
return;
}

I have added lots of returns so I could find the exact bit that was dying; in the unedited /joomla/mambots/editors/mosce/jscripts/tiny_mce/tiny_mce.js file, this is part of line 90. The error code it generates is this:

Error: [Exception... "Component returned failure code: 0x80004005 (NS_ERROR_FAILURE) [nsIDOMLocation.href]"  nsresult: "0x80004005 (NS_ERROR_FAILURE)"  location: "JS frame :: http://10.0.0.10/joomla/mambots/editors/mosce/jscripts/tiny_mce/tiny_mce.js :: anonymous :: line 90"  data: no]
Source File: http://10.0.0.10/joomla/mambots/editors/mosce/jscripts/tiny_mce/tiny_mce.js
Line: 90

I have also tried replace the code with a hardwired version to the blank.htm file, but that fails too, so it is definitely a problem with doc.location.href not working as expected apparently. (BTW, I tested the URL in an empty FireFox browser window and it does correctly load the blank.htm page, so I have the URL correctly entered!)

if(!tinyMCE.isMSIE&&doc.title!="blank_page"){
// ... So I tried hardwiring it but that also fails 
doc.location.href="http://10.0.0.10/joomla/mambots/editors/mosce/jscripts/tiny_mce/blank.htm";
window.setTimeout("tinyMCE.setupContent('"+editor_id+"');",1000);
return;
}

[4] Lastly, I tried having FireFox 1.5 create a new profile, but that didn't change the situation at all either, so I think it's definitely something weird in the way 1.5 is handling the doc.location.href call...
> if(!tinyMCE.isMSIE&&doc.title!="blank_page"){

What _is_ doc.title there?  What is it in a build that doesn't show this issue?  See bug 317750, which has some discussion about tinyMCE being broken because their "not IE" path makes some assumptions about page titles that are no longer true due to some security fixes.
Depends on: 317750
Oddly enough, I don't experience the reload problem (or any other problem AFAICT) with the demo here, using Fx 1.5 or tonight's Camino 1.8 branch nightly.  I do, however, see the reload issue in bug 314967, which Jesse apparently did not experience.
Argh. Just installed TinyMCE 2.0, which does indeed fix the problem. You can probably just delete this bug...

My apologies for adding to the clutter. For anyone else trying to get TinyMCE working with Firefox 1.5, it looks like you should go visit

http://tinymce.moxiecode.com/download.php

and replace your tinyMCE editor folder in joomla/mambots/editors.
This bug is about getting opensourcecms.com to update their tinyMCE install at this point..
Status: UNCONFIRMED → NEW
Ever confirmed: true
Summary: Joomla WYSIWYG editor does not work in Firefox 1.5 → opensourcecms.com - Joomla WYSIWYG editor does not work in Firefox 1.5
Tiny MCE is no longer functional in the trunk build from 2006-04-18: 
Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9a1) Gecko/20060418 Firefox/3.0a1

What is no longer functional:
Add an image in the editor. Click on the OK button to add the image to the mce textarea. The image is not added. This was functional in deerpark alpha (2.x) so something is changed here.
Julien, that's not the same bug as this one.  Please file a separate bug, with a link to a URL where the bug can be reproduced and a detailed step-by-step description of how to reproduce?  cc me and I'll look into it.
I posted the new bug:
https://bugzilla.mozilla.org/show_bug.cgi?id=335165

Please check it.
INCOMPLETE due to lack of activity since the end of 2009.

If someone is willing to investigate the issues raised in this bug to determine whether they still exist, *and* work with the site in question to fix any existing issues, please feel free to re-open and assign to yourself.

Sorry for the bugspam; filter on "NO MORE PRE-2010 TE BUGS" to remove.
Status: NEW → RESOLVED
Closed: 13 years ago
Resolution: --- → INCOMPLETE
Product: Tech Evangelism → Tech Evangelism Graveyard
You need to log in before you can comment on or make changes to this bug.