haka002 / prestashop-webservice-lib
PrestaShop Webservice 访问库。
2.2.2
2017-04-15 22:01 UTC
Requires
- php: >= 5.3.0
- ext-curl: *
This package is not auto-updated.
Last update: 2024-09-29 03:05:21 UTC
README
用于 PrestaShop Webservices 的 PHP 库
这个仓库只因为人们想使用 PrestaShop 1.7 的 webservice。原始版本和这个版本的区别仅在于最大版本号。
您可以在以下位置找到原始文档:http://doc.prestashop.com/display/PS16/Web+service+one-page+documentation
// Here we define constants /!\ You need to replace this parameters define('DEBUG', true); // Debug mode define('PS_SHOP_PATH', 'http://www.myshop.com/'); // Root path of your PrestaShop store define('PS_WS_AUTH_KEY', 'ZQ88PRJX5VWQHCWE4EE7SQ7HPNX00RAJ'); // Auth key (Get it in your Back Office) require_once('./PSWebServiceLibrary.php'); // Here we make the WebService Call try { $webService = new PrestaShopWebservice(PS_SHOP_PATH, PS_WS_AUTH_KEY, DEBUG); // Here we set the option array for the Webservice : we want customers resources $opt['resource'] = 'customers'; // Call $xml = $webService->get($opt); // Here we get the elements from children of customers markup "customer" $resources = $xml->customers->children(); }