Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
CT calls check_plain on arrays of task priorities, assignees, and statuses when cases are viewed, resulting in multitudes of the following error:
htmlspecialchars() expects parameter 1 to be string, array given in /var/www/drupal/atrium/includes/bootstrap.inc on line 860.
This is with a fresh install of Open Atrium.
Comments
Comment #1
Dane Powell CreditAttribution: Dane Powell commentedAlso, this only appears when viewing some cases and not others. I haven't figured out a pattern yet.
Comment #2
jmiccolis CreditAttribution: jmiccolis commentedAny chance you can tell me how to reproduce this?
Comment #3
Dane Powell CreditAttribution: Dane Powell commentedI've since moved away from Case Tracker, so I'm afraid I can't reproduce this. Feel free to close this if you'd like.
Comment #4
jmiccolis CreditAttribution: jmiccolis commentedSetting to closed. Thanks for posting back here even though you have moved away from CT.
Comment #5
langworthy CreditAttribution: langworthy commentedRan into this issue on an inherited OA codebase where both views and ctools had been installed in
sites/all/modules
, not sure if that's related. I've cleaned up system table as best I can.The first element of the array being passed to check_plain is the string "Open a new case assigned to a particular project." and there is an empty string as a second element.
When clearing caches this array is also passed to
mysql_real_escape_string()
in line 321 ofincludes/database.mysql.inc
.Comment #6
langworthy CreditAttribution: langworthy commentedTurns out casetracker_basic was (strangely) enabled along with atrium_casetracker. Disabling casetracker_basic fixed the problem.
Comment #7
Robin van Emden CreditAttribution: Robin van Emden commentedEven when disabling casetracker_basic this problem still occurs in our OA beta8 install. See also https://community.openatrium.com/issues/node/2560#comment-6324
Comment #8
suydam CreditAttribution: suydam commentedConfirmed.... still seeing problem with a clean OAb8 install without CT Basic enabled.
Comment #9
othermachines CreditAttribution: othermachines commentedRelated? No project, create case + comment results in preg_match() error (htmlspecialchars() error in PHP 5.3.1)
Comment #10
TallDavid CreditAttribution: TallDavid commentedI'm seeing this error on a site without Case Tracker installed. "htmlspecialchars() expects parameter 1 to be string, array given in" ... "bootstrap.inc on line 860"
There log indicates the Location as: "http://example.com/admin/reports/status/run-cron?destination=admin%2Fbui..."
Hope this additional information is useful.
Comment #11
kamenrs CreditAttribution: kamenrs commentedAs far as I investigated there can be many reasons to receive this error.
Some modules can cause this error: