This section is used to configure the content of the feed file. How many fields the feed file is going to have, what delimiters will be used, whether or not the headers will be included, by which attributes the products will be added to the feed, - all this information is specified under Content Settings. Depending on the feed type being used, the content can be filled for CSV, TXT or XML format.
If XML format is selected for the feed file, the structure of this file is entered in the corresponding text area according to the template provided by the target shopping system or based on the general requirements for XML files.
GoMage.com DOES NOT provide any CSV, TXT or XML templates!
Content
Please enter a structure description of the XML file in the text area.
Usually, Shopping Engine Services provide a template of an xml file. Ask your Shopping Engine provider about the preferred XML template.
Important! The Attribute code must be enclosed in curly brackets and contain "var:" variable (see example): {{var:Attribute_Code}}.
{{block type="product"}}...{{/block}} – required block containing tags and attributes code.
For example:
{{block type="product"}} <part_number>{{var:sku}}</part_number> ............................. OR ................................... <g:price>{{var:price format="float"}}</g:price> {{/block}}
You can find all Attribute codes on Manage Attributes page (Catalog → Attributes → Manage Attributes)
You can also use static values.
For example:
{{block type="product"}} <g:condition>New</g:condition> {{/block}}
Important! The Attribute code for a Dynamic attribute must be enclosed in curly brackets and contain "var:" and "custom:" variables: {{var:custom:Attribute_Code}}.
For example:
{{block type="product"}} <category>{{var:custom:amazon_category}}</category> ................................ OR ................................... <price_vat>{{var:custom:price_vat format="float"}}</g:price_vat> {{/block}}
Forming an XML feed file for Categories
For example:
<categories> {{block type="category"}} <category> <id>{{var:entity_id}}</id> <level>{{var:level}}</level> <name>{{var:name}}</name> </category> {{/block}} </categories>
Custom XML Attribute Codes
Option | XML code |
Description |
Category > SubCategory |
{{var:category_subcategory}} |
Includes category and subcategory of a product. For example: Apparel > Shoes > Men |
Decode special chars |
format="htmlspecialchars_decode" |
Read more about Output Type |
Delete Space |
format="delete_space" |
Read more about Output Type |
Dynamic Attribute |
var:custom:dynamic_attribute_code |
Read more about Dynamic Attribute |
Encode special chars |
format="htmlspecialchars" |
|
Final Price |
{{var:final_price}} |
Allows you to get the "latest" prices for your products.
|
Float |
format="float" |
|
Image 2 - 5 |
{{var:image_2}} |
Use these attributes to upload the additional product images to the Feed file. |
Integer |
format="integer" |
Read more about Output Type |
Parent Base Image |
parent_base_image |
Allows you to get the "parent" base image URL from a Configurable product for all simple products that belong to it. |
Parent SKU |
{{var:parent:sku}} |
Use this attribute to export the parent product SKU for a simple product that belongs to it. |
Store Price |
{{var:store_price}} |
Allows you to get prices in the local currency for the selected store. |
Striptags |
format="striptags" |
Read more about Output Type |
Symbols Limit |
limit="10" |
Read more about Output Type |
URL (Parent Product) |
{{var:parent:url}} |
Allows you to get a "parent" URL from a Configurable product for all simple products that belong to it. |
XML Examples
Example 1: Encode Special Characters + Symbols Limit
{{block type="product"}} <name>{{var:name format="htmlspecialchars" limit="10"}}</name> {{/block}}
Example 2: Parent SKU
{{block type="product"}} <g:item_group_id>{{var:parent:sku}}</g:item_group_id> {{/block}}
Example 3 (for Google Shopping): Additional images in the Feed file
{{block type="product"}} <g:image_2>{{var:image_2}}</g:image_2> <g:image_3>{{var:image_3}}</g:image_3> <g:image_4>{{var:image_4}}</g:image_4> <g:image_5>{{var:image_5}}</g:image_5> {{/block}}
Example 4: Special Chars (Example for specialchars and urlencode / urldecode)
{{block type="product"}} <attribute>{{var:attr format="htmlspecialchars"}}</attribute> ................................ OR ................................... <attribute>{{var:attr format="htmlspecialchars_decode"}}</attribute> {{/block}}
Example 5: Pulling out the category or attribute from Parent Configurable Product and adding it to Child Simple Product
<name>{{var:parent:name}}</name>
Comments
0 comments
Please sign in to leave a comment.