I am getting the following two error messages:

Warning: Illegal string offset 'data' in template_preprocess_calendar_month() (line 38 of /home6/*****/public_html/profiles/*******/modules/contrib/calendar/theme/theme.inc).
Warning: Illegal string offset 'data' in template_preprocess_calendar_month() (line 43 of /home6/*******/public_html/profiles/*******/modules/contrib/calendar/theme/theme.inc).

This error message is slightly different from the latest dev version's error at: https://drupal.org/node/1471400.

I have built two sites for non-profits in Drupal, but am not a programmer, so I avoid using the dev versions of modules. What can be done to fix this issue?

Thanks in advance!
TV

Here is a patch

CommentFileSizeAuthor
#4 remove-warning_2105573_3.patch626 byteszakxxi
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

joshuautley’s picture

What version of PHP does your hosting provider run? I am guessing you are using a shared host provider as you stated you are not a programmer. It may be caused by running php 5.4.

I have php 5.4 on my local machine and I get this same error but on my production server I have php 5.3 and there is no error.

You can disable the errors from being displayed until you get it sorted out only turning them back on to trouble shoot the issue.

Configuration > Development > Logging and errors

http://localhost/admin/config/development/logging

gbirch’s picture

This is a duplicate of another issue: https://drupal.org/node/1471400

The patch at comment #58 works nicely.

Hope that helps.

(Comment edited because my fix didn't always work)

zakxxi’s picture

PHP Version 5.4.19 and same error
Solved by replacing on Line 38 of theme.inc :

$cell = $data['data'];

by :

if(!is_array($data))
continue;
$cell = $data['data'];
zakxxi’s picture

Issue summary: View changes
FileSize
626 bytes

This is a Patch, it's like #3

firesidelibrarian’s picture

Thanks everyone!
So do I apply both patches, and if so, in what order? Or do I just apply the second one?

firesidelibrarian’s picture

It appears I neglected to mention that my hosting provider runs PHP 5.4. I can select one of several versions of PHP, but for the modules I am using, this has been giving me the best results up until now.

Also, I am confused as to where to apply the patches. I understand the basics of applying patches, but cannot find the folder for the Calendar module to try the patch. It is not listed in sites/all/modules or in sites_oo/all/modules, so where do I apply it?

Thanks again!

firesidelibrarian’s picture

Found the place to apply the patch!

I am using the Open Outreach distribution, which means the Calendar module is in a slightly different location from a standard Drupal install:

profiles/openoutreach/modules/contrib/calendar

Uploading the "...78" patch and running it there worked!!

Feel free to close my issue, if no one else is having this problem, and thanks for being there!

Boobaa’s picture

Status: Active » Closed (duplicate)