I am running Drupal 5.1. Our host just upgraded PHP to version to 5.2.5 and now I am getting the following error:

Fatal error: Cannot use string offset as an array in /home/public_html/sites/all/modules/captcha/captcha.module on line 169

Our other site running PHP 4.4.7 with the same version of Drupal, along with the same versions of Captcha and TextImage. On this site we are not experiencing any problems.

My first question is, how can I edit the database to disable the Captcha and TextImage modules so that I can at least get my site back online?

The second question, is there a patch or anything to fix this problem?

Thanks,

Chris

Comments

mrf’s picture

This post tells you how to disable the modules in the DB, not sure if there are any patches.

Griff1324’s picture

Thank you! I did find instructions on how to disable the module. Now I need to fix the problem with the captcha.

WorldFallz’s picture

Searching the captcha module issues queue with "Cannot use string offset" yielded several results. Take a look--

===
"Give a man a fish and you feed him for a day.
Teach a man to fish and you feed him for a lifetime."
-- Lao Tzu
"God helps those who help themselves." -- Benjamin Franklin
"Search is your best friend." -- Worldfallz

cog.rusty’s picture

I recall following one of those issues once. From what I remember.
- The http://drupal.org/project/textimage module is completely unrelated to captchas
- I'd say just make sure to use the latest version (now 5.x-3.1), run update.php, and maybe clear your browser's cookies (strangely that helped someone).

Drupal 5.1 shouldn't have any problem with PHP 5.2 (but contributed modules are another matter).