xml - prestashop webservices for image in json format -
when parse image data using prestashop webservices in xml format work fine when change output format json getting error.
in xml format result is
<?xml version="1.0" encoding="utf-8"?> <prestashop xmlns:xlink="http://www.w3.org/1999/xlink"> <image_types> <image_type id="7" name="category_default" xlink:href="http://abcd.com/api/image_types/7"/> <image_type id="3" name="medium_default" xlink:href="http://abcd.com/api/image_types/3"/> </image_types> <images> <image id="10" xlink:href="http://abcd.com/api/images/categories/10"/> <image id="11" xlink:href="http://abcd.com/api/images/categories/11"/> <image id="3" xlink:href="http://abcd.com/api/images/categories/3"/> <image id="4" xlink:href="http://abcd.com/api/images/categories/4"/> <image id="5" xlink:href="http://abcd.com/api/images/categories/5"/> <image id="6" xlink:href="http://abcd.com/api/images/categories/6"/> <image id="7" xlink:href="http://abcd.com/api/images/categories/7"/> <image id="8" xlink:href="http://abcd.com/api/images/categories/8"/> <image id="9" xlink:href="http://abcd.com/api/images/categories/9"/> </images> </prestashop>
in json format result is
{"":[{"id":"7"},{"id":"3"},{"id":"10"},{"id":"11"},{"id":"3"},{"id":"4"},{"id":"5"},{"id":"6"},{"id":"7"},{"id":"8"},{"id":"9"}],"errors":[{"code":null,"message":"internal error. see error please display php errors."},{"code":null,"message":"internal error. see error please display php errors."},{"code":null,"message":"internal error. see error please display php errors."},{"code":null,"message":"internal error. see error please display php errors."},{"code":null,"message":"internal error. see error please display php errors."},{"code":null,"message":"internal error. see error please display php errors."},{"code":null,"message":"internal error. see error please display php errors."},{"code":null,"message":"internal error. see error please display php errors."},{"code":null,"message":"internal error. see error please display php errors."},{"code":null,"message":"internal error. see error please display php errors."},{"code":null,"message":"internal error. see error please display php errors."}]}
please help
use image prestashop web services
<img src="http://abcd.com/api/images/products/{{product_id}}/{{image_id}}?ws_key=ds2fhjqqqsag381pb52237254dvk9r14">
and product id , image id product list file xml/json. put id's on image url , image
Comments
Post a Comment