Jump to content

trim() expects parameter 1 to be string


EJooste

Recommended Posts

Help please I was asked to transfer a friends website from one host to another. Now when using the search facility the following error message appears on the top of the results page:

 

Warning: trim() expects parameter 1 to be string, array given in /home/holid937/public_html/inc/xtc_parse_input_field_data.inc.php on line 20

 

you can try it yourself here:

 

http://holiday-rentals-paphos.com/property_finder.php/coID/12/type/propertyfinder

 

The code that the error is referring to is:

<?php
/* -----------------------------------------------------------------------------------------
   $Id: xtc_parse_input_field_data.inc.php,v 1.1.1.1 2007/12/15 12:32:41 jyotsna Exp $   

   XT-Commerce - community made shopping
   http://www.xt-commerce.com

   Copyright (c) 2003 XT-Commerce
   -----------------------------------------------------------------------------------------
   based on: 
   (c) 2000-2001 The Exchange Project  (earlier name of osCommerce)
   (c) 2002-2003 osCommerce(html_output.php,v 1.52 2003/03/19); www.oscommerce.com 
   (c) 2003	 nextcommerce (xtc_parse_input_field_data.inc.php,v 1.3 2003/08/13); www.nextcommerce.org

   Released under the GNU General Public License 
   ---------------------------------------------------------------------------------------*/
   
// Parse the data used in the html tags to ensure the tags will not break
  function xtc_parse_input_field_data($data, $parse) {
    return strtr(trim($data), $parse);
  }
 ?> 

my knowledge on php is limited and I'm not sure where the variables are defined but I could search the files if I knew what I was looking for.

 

Please help!!!

Link to comment
https://forums.phpfreaks.com/topic/280244-trim-expects-parameter-1-to-be-string/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.