Экспорт в GoogleMerchant
Нужно сделать экспорт в GoogleMerchant
Предложения
-
Бесплатно!
В настройках ТДС для узла структуры укажите (доработать можно как угодно):
sendHeaders();
echo '' . "\n";
echo '' . "\n";
echo '' . "\n";
echo '' . Core_Str::xml($oShop->name) . ''. "\n";
echo '' . Core_Str::xml('http://'.$sAlias) . ''. "\n";
echo '' . Core_Str::xml(html_entity_decode(strip_tags($oShop->description), ENT_COMPAT, 'UTF-8')) . ''. "\n";
Core_File::flush();
$oShop_Items = Core_Entity::factory('Shop_Item');
$oShop_Items->queryBuilder()
->where('shop_items.shop_id', '=', $oShop->id)
->where('shop_items.shop_group_id', '!=', 0)
->where('shop_items.shortcut_id', '=', 0)
->where('shop_items.modification_id', '=', 0)
->where('shop_items.active', '=', 1)
->where('shop_items.deleted', '=', 0);
$aShop_Items = $oShop_Items->findAll(FALSE);
foreach ($aShop_Items as $oShop_Item)
{
if ($oShop_Item->price > 0)
{
echo ''. "\n";
echo '' . Core_Str::xml($oShop_Item->seo_title) . ''. "\n";
echo '' . Core_Str::xml('http://'.$sAlias.'/'.$oShop_Item->getPath()) . ''. "\n";
echo '' . Core_Str::xml(html_entity_decode(strip_tags($oShop_Item->description), ENT_COMPAT, 'UTF-8')) . ''. "\n";
if ($oShop_Item->image_large != '')
{
echo '' . Core_Str::xml('http://' . $sAlias. $oShop_Item->getItemHref() . $oShop_Item->image_large) . ''. "\n";
}
echo '' . Core_Str::xml($oShop_Item->price) . ''. "\n";
if (!is_null($oShop_Item->marking))
{
echo '' . Core_Str::xml($oShop_Item->marking) . ''. "\n";
}
echo ''. "\n";
}
}
echo '' . "\n";
echo '';
Core_File::flush();
exit();