CMS MADE SIMPLE FORGE

Vehicle Listing

 

[#6774] Bug with search and php 5.3.6

avatar
Created By: aldi (al-d82)
Date Submitted: Sat Aug 13 17:47:35 -0400 2011

Assigned To: mw (mwoods)
Version: None
CMSMS Version: 1.9.2
Severity: None
Resolution: None
State: Open
Summary:
Bug with search and php 5.3.6
Detailed Description:
ther is an error with the searching and PHP Version 5.3.6

With PHP version 5.3.6 I get the error "
Warning: trim() expects parameter 1 to be string, array given in
/www/htdocs/w00e2fe1/cms/modules/autos/autos.module.php "

It's   if(substr($key,0,6) == "field_" && trim($value) != ""){

this works with php version 5.2.12 but not with 5.3.6.
there are only (vehicle) make and (vehicle) features affected.

NaN, a guy from the German CMSMS Support Forum gave me a tip how you can solve
the problem if u have php version 5.3.6


With this code:
if(substr($key,0,6) == "field_" && !empty($value)){ 

 it works again


History