Chrome shows this on a page like node/add/page:

[14:19:05.493] [Exception... "Component returned failure code: 0x80004005 (NS_ERROR_FAILURE) [nsIDOMHTMLDocument.execCommand]"  nsresult: "0x80004005 (NS_ERROR_FAILURE)"  location: "JS frame :: http://localhost/spark-git/8xx/profiles/spark/modules/contrib/aloha/build/alohaeditor/lib/aloha.js?v=custom%20build:%200.21.2%20+%20patches :: <TOP_LEVEL> :: line 29"  data: no]: Could not disable enableObjectResizing @ http://localhost/spark-git/8xx/profiles/spark/modules/contrib/aloha/build/alohaeditor/lib/aloha.js?v=custom%20build:%200.21.2%20+%20patches:29

I'm not entirely convinced this is an actual problem w/ Aloha vs. something dumb Spark 8.x-1.x is doing, but filing nonetheless...

Comments

Wim Leers’s picture

I've never seen anything like this!

Is this in Firefox? Did you also try in Chrome?

Wim Leers’s picture

Assigned: Unassigned » Wim Leers
Status: Active » Postponed (maintainer needs more info)

@webchick said the above *was* in Chrome. But googling for the error indicates it *must* have been Firefox.

I tried it in Firefox 14, no such error. Updated to 15, still not.

The error message suggests a problem with the specific Firefox version being used. Were you using a non-stable release perhaps?

lightsurge’s picture

Actually I've had this error in Chrome before, unless it's something other than the error message that you thought meant it had to be Firefox?

For me it was a plugin problem, I don't know which, did lazy trouble-shooting and disabled a few. Actually it might have been a Mozilla plugin for Chrome, maybe that's why there's cross-over.

lightsurge’s picture

Was so sure of myself but think I must be remembering wrong, googling it I see what you mean. Unless, I wonder if I had firebug lite installed.

lightsurge’s picture

i can replicate in Firefox 15.0.1 with Firebug 1.10.3

[Exception... "Component returned failure code: 0x80004005 (NS_ERROR_FAILURE) [nsIDOMHTMLDocument.execCommand]" nsresult: "0x80004005 (NS_ERROR_FAILURE)" location: "JS frame :: /modules/aloha/build/alohaeditor/lib/aloha.js?v=custom%20build:%200.21.2%20+%20patches :: :: line 29" data: no]: Could not disable enableObjectResizing

lightsurge’s picture

According to http://stackoverflow.com/questions/2901759/how-to-i-disable-the-moz-resi...

document.designMode = "on";

should come before:

document.execCommand( 'enableObjectResizing', false, false);

and it doesn't seem to in aloha core

https://github.com/alohaeditor/Aloha-Editor/blob/dev/src/lib/aloha/core....

lightsurge’s picture

Btw for me while I get the same error message Aloha loads fine, it just logs this error and presumably won't disable Firefox native image resizing.

Also it's nothing peculiar to Spark/Aloha, you can trigger the same error by going to this minimal demo http://chris.photobooks.com/tests/rte/moz_resizing/moz_resizing.html

Try turning native image resizing off before you click 'Make the iframe editable' (this is what triggers setDesignMode('on')). You'll get the error logged. Make the iframe editable and then turn off image resizing, and it'll work without error.

lightsurge’s picture

Wim Leers’s picture

Title: Aloha 8.x-2.x not loading on body fields » Aloha causes JS console error in Firefox, but works fine
Component: User interface » Aloha Editor (upstream)
Priority: Critical » Minor
Wim Leers’s picture

Assigned: Wim Leers » Unassigned
Issue tags: +post-feature freeze

.

Wim Leers’s picture

Status: Postponed (maintainer needs more info) » Postponed