PrestaShop icon indicating copy to clipboard operation
PrestaShop copied to clipboard

htmlspecialchars expects parameter 1 to be string, array given

Open ZamperSPA opened this issue 6 years ago • 3 comments

update the module: Faceted Search and website stops responding

To Reproduce Steps to reproduce the behavior:

  1. Update module faceted from 3.0.6 to 3.4
  2. open any category

Screenshots imagen Log: https://pastebin.com/BiamYGyC imagen

Additional information

PrestaShop version: 1.7.6.2 PHP version: 7.2.26

ZamperSPA avatar Dec 26 '19 14:12 ZamperSPA

Hi @ZamperSPA,

I did not manage to reproduce the issue with PS1.7.6.2& ps_facetedsearch v3.4.0. I attached a screen record https://drive.google.com/file/d/1o22P1iBW_crTHD2nsIdhVudm7ypDM2mQ/view In the ps_facetedesarch configuration page, could you please try to click on the "Index all missing prices" & "Rebuild entire price index" & "Clear cache" buttons, check & feedback.

khouloudbelguith avatar Dec 26 '19 16:12 khouloudbelguith

Hi @ZamperSPA,

Since we had no news from you for more than 30 days, I'll close this ticket. Feel free to open another one if you can give specific details.

Thanks!

khouloudbelguith avatar Jan 27 '20 08:01 khouloudbelguith

Hello @khouloudbelguith, I'm facing the same error :

The error concerns the product page : PHP message: PHP Warning: htmlspecialchars() expects parameter 1 to be string, array given in var/cache/prod/smarty/compile/layouts_layout_left_column_tpl/84/9f/0d/849f0d8a7512ed672487a06a045d302b9e5e7c31_2.file.product-style-02.tpl.php on line 40'

Here is the concerned line on the compiled template : <meta itemprop="brand" content="<?php echo htmlspecialchars($_smarty_tpl->tpl_vars['product']->value['manufacturer_name'], ENT_QUOTES, 'UTF-8');?>

PS version : 1.7.6.4 PHP version : 7.3

simobenso avatar Jun 14 '20 20:06 simobenso