Jump to content

XML feed problem - s description (popisek)


minap
 Share

Recommended Posts

Cele odpoledne se to tu snazim vyresit, uz jsem dospel k tomu, ze se mi XML feed generuje. Diky Vam!

Ale stale se mi v nem neukazuje Description : http://www.cokeboys.cz/zbozi.php ...

Chapu, ze je v tom kodu nejaka podminka, ze kdyz je neco spatne, zobraz tecku asi. Ale co tam je spatneee?:)

Moc dekuji za jakoukoliv radu...

Share this post


Link to post
Share on other sites

Pouzivam tento kod:

<?php
$shopUrl = 'http://www.cokeboys.cz';  /// OPRAVIT
include(dirname(__FILE__).'/config/config.inc.php');/// ZKONTROVAT SPRAVNOST
include(dirname(__FILE__).'/init.php'); /// ZKONTROVAT SPRAVNOST
error_reporting(0);
$p=Product::getProducts(3, 0, 0, 'id_product', 'desc', false);/// ZKONTROVAT SPRAVNOST
$products=Product::getProductsProperties(3, $p);/// ZKONTROVAT SPRAVNOST

header("Content-Type: text/xml");
echo '<?xml version="1.0" encoding="utf-8"?>

COKEBOYS.CZ
www.cokeboys.cz/';

foreach ($products AS $row){
  if ($row['active']){

  $kategorie=array();
$category = new Category(intval($row['id_category_default']), intval(3));
while ($category->id <> 1) {
   $kategorie[]=$category->hideCategoryPosition($category->name);
   $category = new Category(intval($category->id_parent), intval(3));
}

$img=Product::getCover($row['id_product']);
echo '

'.str_replace("&", "&", $row['manufacturer_name']).'
'.str_replace("&", "&", $row['manufacturer_name']).' '.str_replace("&", "and", strip_tags($row['name'])).'
'.str_replace("&", "&", $row['manufacturer_name']).' '.str_replace("&", "and", strip_tags($row['name'])).'
'.str_replace("&", "&", $row['manufacturer_name']).' '.str_replace("&", "and", strip_tags($row['name'])).'.'.str_replace("&", "and", strip_tags($row['description_short'])).'
'.str_replace("&", "and", strip_tags($row['description_short'])).'.'.str_replace("&", "and", strip_tags($row['description'])).'
'.$row['link'].'
'.implode('>',array_reverse($kategorie)).'
http://www.cokeboys.cz/img/p/'.$row['id_product'].'-'.$img['id_image'].'-home.jpg
'.$row['tax_rate'].'
'.($row['price']*1).'
0
2
new
';

  }
} 
echo '';
/// DALE OPRAVIT NÁZEV OBCHODU V RADKU 
/// OPRAVIT DOMENU V RADKU  POD NAZVEM OBCHODU
/// DALE OPRAVIT DOMENU+CESTU K ADRESARI V RADKU 
/// OPRAVIT  - doruceni (dny)
?>

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...

Important Information

Cookies ensure the smooth running of our services. Using these, you accept the use of cookies. Learn More