Opened 13 years ago
Closed 13 years ago
#17501 closed defect (bug) (fixed)
Javascript errors in press this
Reported by: | greuben | Owned by: | azaozz |
---|---|---|---|
Milestone: | 3.2 | Priority: | normal |
Severity: | major | Version: | |
Component: | Press This | Keywords: | has-patch needs-testing |
Focuses: | Cc: |
Description
On press this click embed video, insert some code and click insert video. An error is thrown in Chrome and the box does not close
Uncaught Error: HIERARCHY_REQUEST_ERR: DOM Exception 3
Attachments (2)
Change History (8)
#3
follow-up:
↓ 5
@
13 years ago
Seems like mceCleanup needs selection
Backtrace
Uncaught Error: HIERARCHY_REQUEST_ERR: DOM Exception 3 c.create.getBookmark -- tiny_mce.js:1 c.EditorCommands.t.mceCleanup -- tiny_mce.js:1 q -- tiny_mce.js:1 m.create.execCommand -- tiny_mce.js:1 j.EditorManager.d.execCommand -- tiny_mce.js:1 append_editor -- press-this.php:161 (anonymous function):4 f.event.handle -- jquery.js:17 f.event.add.k.i.handle.k -- jquery.js:16
Code
mceCleanup : function() { var bookmark = selection.getBookmark(); // the errors occurs here editor.setContent(editor.getContent({cleanup : TRUE}), {cleanup : TRUE}); selection.moveToBookmark(bookmark); },
@azaozz: can you confirm if the latest patch is working? see 17501.2.diff
#4
@
13 years ago
- Keywords needs-testing added
- Owner set to azaozz
- Status changed from new to reviewing
Assigning to azaozz for review, testing and commit/!commit call.
#5
in reply to:
↑ 3
@
13 years ago
Replying to greuben:
Seems like mceCleanup needs selection
...
@azaozz: can you confirm if the latest patch is working? see 17501.2.diff
Yes, seems to be working. I dug a bit deeper and think we can skip the forced mceCleanup
completely. That seems to happen automatically in this version of TinyMCE. Please reopen if there are still issues when adding videos or images in Press This.
The first arg. for
execInstanceCommand()
should be the editor ID which is the same as the ID of the textarea that was replaced (content), so the proposed patch seems to be disabling thecleanup
.