1. Go to this page and download the library: Download thepublicgood/bidfeed 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/ */
thepublicgood / bidfeed example snippets
$feed = new TPG\BidFeed\Builder();
$product = new Product();
$feed->products()->push($product);
$xml = $feed->toXml();
// You can also save it directly to a file by passing a filename:
$feed->toXml('feed.xml');
// You can...
$feed->products()->push((new Product())->...);
// or add multiple products at once...
$feed->products()->push([$product1, $product2]);
// Set a selling price
$product->price(199.95);
// Set a selling price and market price
$product->price(199.95, 219.95);
// Set a marketing price
$product->marketPrice(211.50);
$product->availableQuantity(10);
$product->images([$image1, $image2]);
// Add an image to the collection
$product->imageCollection()->add($imageUrl3);