The modal dialogue popup for WYSIWYG broke for us when we switched to the Mothership theme or a child theme of it. Clicking on images takes you to a version of the image insert form with no CSS and no Javascript, because the jQuery selector cannot find the images to attach onclick events. Further options - insert, cancel, delete - won't work as they all require Javascript.
The main problem is that it looks like it's working right up to the point where you get an unstyled insert form, so we just thought that it was a bug in the module and started poking around. It's not obvious that it's the Javascript onclick assignment that's breaking. As it took us a long time to diagnose this, is there any way that the Javascript could warn?
Please find attached a very small patch that does this. When the number of "#browse .browse .view-content ul li a" onclick assignments is different from the number of "#browse .browse img" tags then it fires an alert. Ideally the system would degrade nicely without onclick assignments, but that probably involves a lot more refactoring.
(Temporary solution: copy modules/views/views-view.tpl.php to themes/yourtheme/views-view--ib-browser.tpl.php and clear the theme cache.)
| Comment | File | Size | Author |
|---|---|---|---|
| ib_views_themeing.patch | 510 bytes | jp.stacey |
Comments
Comment #1
peter törnstrand commentedGood idé to have the module warn when it thinks the markup is not correct. I have experienced similar problems when using the Tao base theme related to the pager .... so using themes that modify standard Drupal or Views templates is a problem.
Comment #2
peter törnstrand commentedCommited.