Jump to content


  • Posts

  • Joined

  • Last visited

Profile Information

  • Location
  • Activity

lestat95's Achievements


Newbie (1/14)



  1. Hi. I am trying make an XML feed for price comparison portals. However the execution of the code gets timed-out every time. I used the same code a while ago on 1.5.3 (different hosting provider), and it worked like a charm. Can anyone help please? The problem seems to be with the $kategorie generation (I need a full category path). Thanks! <?php $shopUrl='http://www.shop.domain'; include(dirname(__FILE__).'/config/config.inc.php'); include(dirname(__FILE__).'/init.php'); error_reporting(0); $p=Product::getProducts(7,0,0,'id_product','desc', false); // Language code $products=Product::getProductsProperties(7,$p); // Language code header("Content-Type:text/xml"); echo'<?xml version="1.0" encoding="utf-8"?> <SHOP>'; foreach ($products as $row) { $id_image = Product::getCover($row['id_product']); $image = new Image($id_image['id_image']); $imgurl = _PS_BASE_URL_._THEME_PROD_DIR_.$image->getExistingImgPath().".jpg"; $kategorie=array(); $category = new Category(intval($row['id_category_default']), intval(3)); while ($category->id <> 1) { $kategorie[]=$category->name; $category = new Category(intval($category->id_parent), intval(3)); } <SHOPITEM> <CODE>'.$row['id_product'].'</CODE> <NAME>'.htmlspecialchars($row['name']).'</NAME> <DESCRIPTION>'.strip_tags(htmlspecialchars($row['description_short'])).'</DESCRIPTION> <PRODUCT_URL>'.htmlspecialchars($row['link']).'</PRODUCT_URL> <IMGURL>'.htmlspecialchars($imgurl).'</IMGURL> <PRICE>'.($row['price']*1).'</PRICE> <MANUFACTURER>'.htmlspecialchars($row['manufacturer_name']).'</MANUFACTURER> <SHIPPING>3,90</SHIPPING> <CATEGORY>'.implode(' > ',array_reverse($kategorie)).'</CATEGORY> <AVAILABILITY>3 days</AVAILABILITY> </SHOPITEM>';}echo' </SHOP>';?>
  2. Hi guys. I am trying to make an xml feed for my Prestashop 1.5. Somehow I got stuck with listing all categories of the product. In my eshop, I've got a number of categories and several subcategories. Default product categories are not always the end subcategories, but mostly the upper level categories. I'd like to achieve something like <CATEGORY> Category 1 -> Subcategory 1 </CATEGORY> for my xml file. any help would be much appreciated
  3. I have not installed the 1.5.4 yet, but did you try to check the translations manually? That solved at least my problem, though it had a different root cause. Example that worked for me (Theme name BALIM, module directory name "blocksearchtop", module TPL filename: "blocksearch-top.tpl" language SK, translated string "search..." in English to "hladat..." in Slovak. Theme modules are located in the "themes/[THEME NAME]/modules" directory. in each module directory, there's [MODULENAME].tpl file, index.php and several [LANGUAGE CODE].php files. in the [MODULENAME].tpl file, look up the strings you need to translate. Example: {l s='search...' mod='blocksearchtop'} the corresponding translation in the language file should be then: <?php global $_MODULE; $_MODULE = array(); $_MODULE['<{blocksearchtop}balim>blocksearch-top_d77a48a51f8c62087570ab8f9d6ca55a'] = 'hľadať...'; d77a48a51f8c62087570ab8f9d6ca55a is MD5 hash of "search...". You can easily convert strings in any online MD5 generator... Let me know if that worked for you....
  4. I found the root cause, at least for my problem. Seems like an error in the TPL files of some modules. As an example, a module with name "blocksearchtop" located in themes/[themename]/modules/blocksearchtop in BLOCKSEARCHTOP.TPL, there was {l s='search...' mod='blocksearch'}. I have corrected it to {l s='search...' mod='blocksearchtop'} and everything is working as it should. I have noticed that several other modules in a number of commercial themes have similar issues. @jos0405: I am not sure, if that helps, since it has been working in your previous version.
  5. Hi everyone. I am trying to translate my installation of Prestashop into Slovak language. Unfortunately, module translations do not show on the website. Phrases that were supplied with the installation are working all right. However, when I try to do further translations in the back-office, everything gets saved correctly, even the sk.php file in the themes\[themename]\modules\[modulename] gets updated. The This is my second Prestashop implementation. In the previous one (same Prestashop version, different template), I had similar problems, but I have worked around them translating the phrases in the TPL files direcly. This time, I will require to have the site in several languages. Namely, I have problem with blockcart module in both default and other themes, but there are also others that are not working (probably all?) Has anyone encountered similar issue, or has a clue how to solve this? Many thanks for any advice on that.
  • Create New...

Important Information

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