Pages - Menu

Sunday, February 3, 2013

Drupal Search Issue Fix with preg_replace error


Note: this change was needed due to a PCRE (PHP library) Update that cause Drupal search failing with preg_replace error

Overview

After a PHP update, the search function becomes malfunction, it return error message
"You must include at least one positive keyword with 3 characters or more"

It is required to update some configuration on the system.
Here are some links that can tell us about the issue:

Changes

To fix this issue, we must update the file using the update suggested here http://drupal.org/files/do-1446372-remove-surrogates.patch

1. Open this file:
 /home/o1.ftp/static/drupal-7.7/includes/unicode.inc
2. Go to line 76
3. Replace this code
'\x{D800}-\x{F8FF}\x{FB29}\x{FD3E}-\x{FD3F}\x{FDFC}-\x{FDFD}' .
with this one:
'\x{E000}-\x{F8FF}\x{FB29}\x{FD3E}-\x{FD3F}\x{FDFC}-\x{FDFD}' .

the difference is only the "D800" and "E000", and we need to change the "D800" to "E000"

1 comment:

  1. Awe-inspiring bequest! Your blog is attention-grabbing. I feel affection for it. Selecting a Content Management System is extremely essential moving forward. I only use Drupal. Because As a result of the top non-profits with Fight Hunger and UNICEF use Durpal, everything clicked For our Drupal hosting I chose GetPantheon including features like the capability to go live with 1 click which solution have you used?

    Drupal Development Tools

    ReplyDelete

 

Total Pageviews

Translate