Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixing issue with multiple instances on a page #209

Merged
merged 1 commit into from
Feb 18, 2013

Conversation

weotch
Copy link
Contributor

@weotch weotch commented Feb 6, 2013

I was getting a "Uncaught Error: NOT_FOUND_ERR: DOM Exception 8 for appendChild call" error when I had multiple textareas with WYSIWYGs on the same page. It was because, for the second instance, the options.toolbar was defined for the createToolbar() because of how it gets added into the options object in createEditor() before being passed to new wysi.Editor.

This fix clones the options object before adding the toolbar.

@mickvandijk
Copy link

Thanks for this answer. Helped me out!

2013/2/6 Robert Reinhard notifications@github.com

I was getting a "Uncaught Error: NOT_FOUND_ERR: DOM Exception 8 for
appendChild call" error when I had multiple textareas with WYSIWYGs on the
same page. It was because, for the second instance, the options.toolbar was
defined for the createToolbar() because of how it gets added into the
options object in createEditor() before being passed to new wysi.Editor.

This fix clones the options object before adding the toolbar.

You can merge this Pull Request by running

git pull https://github.com/weotch/bootstrap-wysihtml5 patch-1

Or view, comment on, or merge it at:

#209
Commit Summary

  • Fixing issue with multiple instances on a page

File Changes

Patch Links:

Mvg,
Mick van Dijk
Mickert.nl

jhollingworth added a commit that referenced this pull request Feb 18, 2013
Fixing issue with multiple instances on a page
@jhollingworth jhollingworth merged commit 70c2b0f into jhollingworth:master Feb 18, 2013
@weotch weotch deleted the patch-1 branch February 19, 2013 17:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants