If you don't have a mail.css, and a stylesheet in the default page styles doesn't exist, you'll get a PHP error when sending a page. (For instance, the render/sifr module currently attempts to include a non-existent css.)
The fix for this is to add an @ before file_get_contents in theme_mimemail_message:
$output .= @file_get_contents($style);
A patch is attached.
| Comment | File | Size | Author |
|---|---|---|---|
| #8 | mimemail.304476_03.patch | 1.56 KB | sgabe |
| #7 | mimemail.304476_02.patch | 1.59 KB | sgabe |
| #6 | mimemail.304476_01.patch | 1.49 KB | sgabe |
| #3 | 304476-3.patch | 1.45 KB | Thomas_Zahreddin |
| file_get_contents.patch | 1.98 KB | aaron |
Comments
Comment #1
jerdavisAddressed this with a file_exists() check when including each $style. Committed to HEAD in http://drupal.org/cvs?commit=141349
Comment #2
Anonymous (not verified) commentedAutomatically closed -- issue fixed for two weeks with no activity.
Comment #3
Thomas_Zahreddin commentedHi,
i ran into the same issue.
Have you ever since march 2008 thought about a 5.x-1.1 Version of the module??
Old error are wasting peoples time.
patch is done against 5.x-1.0 Version of mimemail
Comment #4
Thomas_Zahreddin commentedVery similar problem in /mimemail/theme/mimemail.theme.inc Version DRUPAL-6--1-0-ALPHA1 in Line 42/43 .
Comment #5
Thomas_Zahreddin commentedVery similar problem in /mimemail/theme/mimemail.theme.inc Version DRUPAL-6--1-0-ALPHA1 in Line 42/43 .
Comment #6
sgabe commentedPatch attached for the current 6.x-1.0-alpha1 release.
Comment #7
sgabe commentedAttaching a revised version of the patch.
There was a wrong parameter in the
preg_replace()function. We can't usepath_to_theme()and other similar magic here, because that will break this functionality when CSS optimizing is enabled on the site. This issue isn't addressed to solve the styling problem anyway.Comment #8
sgabe commentedAttaching patch against current HEAD.
Comment #9
sgabe commentedCommitted to HEAD.