FIX JSON.parse not needeed and missing simple quote escaping

This commit is contained in:
Regis Houssin 2019-01-21 16:48:14 +01:00
parent 0cba7e1613
commit 406f26b9d2

View File

@ -58,7 +58,7 @@ top_htmlhead($head, $title, $disablejs, $disablehead, $arrayofjs, $arrayofcss);
$categorie = new Categorie($db);
$categories = $categorie->get_full_arbo('product');
?>
var categories = JSON.parse( '<?php echo json_encode($categories);?>' );
var categories = <?php echo json_encode($categories, JSON_HEX_APOS); ?>;
var currentcat;
var pageproducts=0;
var pagecategories=0;