Closed (fixed)
Project:
Wysiwyg
Version:
6.x-0.5
Component:
Code
Priority:
Minor
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
20 Jan 2009 at 00:42 UTC
Updated:
3 Feb 2009 at 22:30 UTC
The following code is causing the CSS aggregation to create 2 different files. In my case, one for the TinyMCE css file and another for the rest.
foreach ($files as $file) {
drupal_add_css($editor['css path'] . '/' . $file, 'module', 'screen');
}
Seems like this should be changed to:
foreach ($files as $file) {
drupal_add_css($editor['css path'] . '/' . $file, 'module');
}
Comments
Comment #1
sunWhat exactly do you mean with "In my case, one for the TinyMCE css file and another for the rest." ?
Comment #2
psynaptic commentedI mean: I have one aggregated file for all Drupal core plus contributed modules and another caused by WYSIWYG which only has TinyMCE stuff in. The CSS aggregator creates different files for different media. It's true that this CSS is just for screen but when other modules and core are doing one thing and this module is doing something else it seems like the "problem" needs to be fixed here. The "problem" is that this module forces an extra HTTP request when it need not. I have modified my installations to solve this problem in the time being while you decide if you will commit.
Comment #3
sunI checked whether it makes a difference, since the original purpose was to hide the editor in the print output, but the print output seems to be bad either way.
Committed a patch that removes media="screen".
Comment #4
psynaptic commentedThanks!