Hello,
I have a csv feed and i have some problems with the categories
The categories from feed look like this
Category
Category::Subcategory
Category::Subcategory::Sub-Subcategory
Then, when is outputs the file looks like this:
Category
CategorySubcategory
CategorySubcategorySub-Subcategory
Help plz.
David,
If i make this change:
$record[$admin_importFeed["field_category"]] = tapestry_normalise($record[$admin_importFeed["field_category"]],":");
I have no results for categories.
Thanks,
Gabriel
Hi Gabriel,
Is that just with the single modification above, or having included the Explode filter and registering that against the category field?
To verify, if you could roll-back that change and make sure that you can then import categories again - then remake the change as above and let me know how you get on...
Cheers,
David.
Hi,
There is a solution for this in the second message in this thread:
http://www.pricetapestry.com/node/898
Then, add a new "Explode" filter to the category, enter "::" as the text to split on, and -1 as the return index. This will return the last value in the list separated by "::".
However, just like in the other thread before this will work you will have to permit the ":" character in the category field. In includes/admin.php look for the following code on line 170:
$record[$admin_importFeed["field_category"]] = tapestry_normalise($record[$admin_importFeed["field_category"]]);
Change this as follows to allow the ":" character:
$record[$admin_importFeed["field_category"]] = tapestry_normalise($record[$admin_importFeed["field_category"]],":");
Hope this helps!
Cheers,
David.