I created an XML feed from items I've scraped off a site (in total 37 items) but when I regsiter and try to import, only 2 items are being imported.
I ensured that the product name is unique and the XML feed seems to be valid and similar to other feeds I'm using (besides the encoding). What could the problem be?
One more thing to add, the XML feed is actually a dynamic file creating the feed on the fly (the htaccss tells it to be dynamic)
Thanks
Anton
Thanks for that David,
I've included cdata on all fields but the price might be the issue.
When you say valid what do you mean? SOmetimes the product is "free" is that not acceptable?, Also what do you mean by valid buy URL?
Many thanks for your quick reply!
Hi,
By "Valid URL", it just has to be present - that's all. As it stands, price does actually need to be a non-zero value; but this check can be easily removed. In includes/admin.php, look for the following code on line 156:
if (!$record[$admin_importFeed["field_name"]] || !$record[$admin_importFeed["field_buy_url"]] || !$record[$admin_importFeed["field_price"]]) return;
...and change this to:
if (!$record[$admin_importFeed["field_name"]] || !$record[$admin_importFeed["field_buy_url"]]) return;
Hope this helps,
Cheers,
David.
Hi,
Could you email me a link to the feed so I can take a look - i'll have a go on my test server...
Cheers,
David.
hi david,
I just sent it to support at iaaisoftware.com
Many thanks!
Anton
Hi Anton,
The conditions for importing a product are unique name; valid price and valid buy URL. Are all these fields present for every record?
It is also possible that there may be a structural problem with the XML, perhaps if the second record is never closed for example. If you are generating a description field from text scraped off another site, make sure that you enclose the text in CDATA tags, for example:
<description><![CDATA[Text goes here]]></description>
That will prevent any XML meaningful characters from within the description from corrupting the file...
Hope this helps!
Cheers,
David.