Solved: htmlspecialchars() expects parameter 1

Meer
12 jaren 4 maanden geleden #411 door Sandra
After updating my php to 5.2.17. I got the following error.

Warning: htmlspecialchars() expects parameter 1 to be string, array given in administrator/components/com_oscommerce/includes/functions/general.php on line 266

to solve this problem change:

find:
Code:
function tep_output_string($string, $translate = false, $protected = false) { if ($protected == true) { return htmlspecialchars($string); } else { if ($translate == false) { return tep_parse_input_field_data($string, array('"' => '"')); } else { return tep_parse_input_field_data($string, $translate); } } }

I changed line 40 to this:
if ($protected == false) {

Changed the true to false and it solve the problem.

I had to do the edit in 2 spots...but that error is gone now.
catalog/admin/includes/functions/general.php
catalog/includes/functions/general.php

Graag Inloggen of een account aanmaken deelnemen aan het gesprek.

Events Joomla
MarvikShop
Finnaly it's here:
 
No bridges, no look a likes!
This is the ultimate integration
between Oscommerce and Joomla!
Documentation
Site Showcase
Follow us