Climateimc.org and http://columbus.indymedia.org/ are both getting these errors.
* warning: Illegal offset type in isset or empty in /var/www/cbusimc.org/includes/path.inc on line 65.
* warning: Illegal offset type in /var/www/cbusimc.org/includes/path.inc on line 70.
With climateimc, the problem is that the IMC cities list is returning a $map[$path_language][$path] that's not a string, it's a SimpleXMLElement::__set_state(array( ))
The array is:
3 => array ( 'file' => '/var/www/climateimc.org/dev/sites/all/modules/indymedia_cities/indymedia_cities.theme.inc', 'line' => 112, 'function' => 'l', 'args' => array ( 0 => SimpleXMLElement::__set_state(array( )), 1 => SimpleXMLElement::__set_state(array( )), ), )
ekes thinks perhaps the XML isn't parsing properly?
I'm on IndymediaIRC pretty regularly (australian time).
| Comment | File | Size | Author |
|---|---|---|---|
| #11 | ekes-path-fix.patch | 1.22 KB | szczym |
| #9 | cimc_modules.txt | 1.71 KB | naught101 |
| #8 | php-menchester.html_.gz | 9.21 KB | szczym |
| #7 | climateimc_phpinfo.html_.gz | 8.51 KB | naught101 |
Comments
Comment #1
mfbI cannot reproduce this warning message so I'm not sure what would be causing it.
I don't think this module should even be calling drupal_lookup_path(). Could you generate a stack trace to see how it got there?
The expected behavior is that the arguments for l() at line 112 are SimpleXMLElement objects. PHP should automatically convert the objects to strings, although there might be cases where this doesn't work and we need to explicitly cast using (string).
Comment #2
naught101 commentedKam from Sydney indy is getting the same problem, confirmed that it's caused by this module. ClimateIMC and sydney IMC are one the same server.
How would you like me to run a backtrace? Ekes had me add this to includes/path.inc after line 65:
The array in the first post is from that. I can post the whole thing, but it's really long. You can view it at
66.135.32.15 dev.climateimc.org (no dns, you'll have to add it to your hosts file)
Comment #3
mfbThanks. Btw you can also install xdebug to get pretty backtraces. Now... why am I not seeing this on my install?! Since I can't reproduce it's rather difficult to fix.
Comment #4
szczym commentedHelo, im in the process of building new imc-pl site. Im also having path issue (currently its on common shared hosting server).
* warning: Illegal offset type in isset or empty in /home/indykant/public_html/includes/path.inc on line 65.
* warning: Illegal offset type in /home/indykant/public_html/includes/path.inc on line 70.
My site is almost vanilla based on http://drupal.org/project/indymedia_alba, have clean urls turn on and 2 languages (based on path).
Comment #5
mfbI still cannot reproduce this so not sure how to fix. I just changed london.indymedia.org to http://london.indymedia.org in the database just in case the lack of leading http:// was the issue.
Comment #6
szczym commentedso its a server issue ? maybe me and naught101 compare our phpinfos with the working one? if any of you is around, catch me on irc.indymedia.org#drupal-dev
Comment #7
naught101 commentedWorkaround: copy html from block into custom block.
Attached: http://www.climateimc.org/en/admin/reports/status/php
Comment #8
szczym commentedhere is my phpinfo too
Comment #9
naught101 commentedEnabled modules:
Comment #10
mfbIt's working for me with PHP 5.2.6-3ubuntu4.1 on Ubuntu 9.04 and PHP 5.2.9 on FreeBSD 7.2
Can you try adding
(string)in indymedia_cities.theme.inc where it's hitting the bug, to see if forcibly casting to string helps at all?Comment #11
szczym commentedEkes fixed the problem on our website, it works, no errors. im attaching the patch.
thanx ekes !
Comment #12
naught101 commentedWorks for me. Thanks.
Comment #13
mfbFixed in CVS. I used
strval()rather than(string)but these should be functionally equivalent. Thanks for the patch.