This is an issue relating to:

  • WYSIWYG
  • CKEDITOR
  • PICTURE
  • MULTISITE config

Background:

  • We have node forms that have text areas using the WYSIWYG text format.
  • We're currently in the process of moving our site from a dev environment (windows/apache/postgres - single site config) to a test environemt (linux/apache/postgres - multi site config).
  • By default, the Picture plugin is on.

Problem:

  • In a single site install - no issue.
  • In a multi site install - the wiring for Picture is messed up...

See attached images: before (plugin on) and after effect of toggling the Picture (plugin off) and error spewed out by the browser.

Workaround:
It wasn't obvious to me (as I went down the wrong path at first thinking it was a CKEditor path issue with multisite) but after re-reading the clue, figured out it was the Picture plugin that was causing our issues, after disabling it, the 'problem' goes away.

I haven't quite figured out where or why things are getting mangled....or at what level wetkit, the contribs etc...

Comments

nadine_cz’s picture

So...the // in the path name (see browser error.png) seems to resolve itself on windows, but our linux server is not at all happy with it.

in the picture.module; the function picture_wysiwyg_plugin

Line 1220 (ish)...
// 'path' => drupal_get_path('module', 'picture') .'/plugins/',
'path' => drupal_get_path('module', 'picture') .'/plugins',

Fixes it on our linux server, continues to work our windows server.......

Process question...does this issue get moved to picture? Do i open an issue in picture and link back to this one?

sylus’s picture

On first glance I think something might not be configured properly in your $base_path or apache.

In your above comment are you saying you had to comment out line 1220 to get everything to work?

drupal_get_path() should always be used to get the correct path and commenting it out will merely mask larger issues.

nadine_cz’s picture

Yeah...certainly not looking at 'masking' the larger issue...

The drupal_get_path() and $base_path resolve correctly, we’ve been running multisite config on the linux test server since January – I suspect we would have had problems before now. I know the Picture module has been there for a bit, but quite frankly, it’s only recently that we’ve exposed a textarea with the wysiwyg text format on our forms…

Line 1220 was commented out, duplicated and the trailing ‘/’ in ‘/plugins/’ was removed for testing...

Both the wysiwyg and picture module attach a trailing ‘/’ which ends up generated a path of

/profiles/wetkit/modules/contrib/picture/plugins//plugin.js

vs

/profiles/wetkit/modules/contrib/picture /plugins/plugin.js.

The double ‘/’ is generated on the window apache as well, but I suspect a rewrite rule is cleaning it up (?). It’s quite possible that our windows apache rewrite rules differ from our service provider’s (ssc) apache rewrite rules….there could definitely be something there.

I’ll explore further - I don't believe this is a wetkit issue.

sylus’s picture

Status: Active » Closed (cannot reproduce)

In the next release I have updated picture to v1.3. However I doubt this will fix any issues you are having. I am nearly certain this is related to your apache configuration / not having a proper base_url.

I setup a multisite myself to see whether I can reproduce this bug and was unable to. For now going to close this as can't reproduce please re-open if you have more information that points to this being a WxT issue. ^_^