PHP code example of abishekrsrikaanth / shirts.io-php-sdk
1. Go to this page and download the library: Download abishekrsrikaanth/shirts.io-php-sdk library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
abishekrsrikaanth / shirts.io-php-sdk example snippets
$productObj = ShirtsIO::Products();
$categories = $productObj->getCategories(); //This will return an array of Product Categories
echo json_encode($categories);
$productObj = ShirtsIO::Products();
$products = $productObj->getProducts($categoryId);
echo json_encode($products);
$productObj = ShirtsIO::Products();
$productInfo = $productObj->getProductInfo($productId);
echo json_encode($productInfo);