williamkwr Posted November 25, 2013 Share Posted November 25, 2013 (edited) Bonjour; je newbie dans le domaine prestashop; j'ai recement réalisé une boutique avec pestashop 1.5.4. Mais je rencontre un souci lorsque je voudrais ajouté un produit au panier j'ai une erreur que voici. Impossible to add the product to the cart. textStatus: 'parsererror' errorThrown: 'SyntaxError: JSON.parse: bad control character in string literal' responseText: { "products": [ { "id": 2, "link": "http://localhost/solution/index.php?id_product=2&controller=product", "quantity": 1, "priceByLine": "280,000XAF", "name": "HP 600B ", "price": "280,000XAF", "price_float": "280000", "idCombination": 0, "idAddressDelivery": 0, "is_gift" : 0, "hasAttributes": false, "hasCustomizedDatas": false, "customizedDatas":[ ] }, { "id": 3, "link": "http://localhost/solution/index.php?id_product=3&controller=product", "quantity": 1, "priceByLine": "679,000XAF", "name": "DELL OPTIPLE...", "price": "679,000XAF", "price_float": "679000", "idCombination": 0, "idAddressDelivery": 0, "is_gift" : 0, "hasAttributes": false, "hasCustomizedDatas": false, "customizedDatas":[ ] } ], "discounts": [ ], "shippingCost": "0XAF", "shippingCostFloat": "0", "wrappingCost": "0XAF", "nbTotalProducts": "2", "total": "959,000XAF", "productTotal": "959,000XAF", "hasError" : false } Je voudrais savoir quel peut être la cause, comment le resoudre pour le moment j'ai activé l'option catalogue. Merci de votre aide. www.solutionbureautique.com Edited November 25, 2013 by Gregory Roussac (see edit history) Link to comment Share on other sites More sharing options...
Gregory Roussac Posted November 25, 2013 Share Posted November 25, 2013 Bonjour, Le json a l'air valide, je ne suis pas sur que le souci se trouve ici. Est ce que par hasard vous auriez toucher à un template ou autre ? On dirait des octets BOM en debut du template https://github.com/PrestaShop/PrestaShop/blob/bootstrap/modules/blockcart/blockcart-json.tpl . Quel éditeur vous utilisez ? Cordialement Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now