Hi,
I'm only interested in about 50 or so categories related to a particular product, and rather than creating a thousand drop record filters, different for every feed, I found this useful thread:
http://www.pricetapestry.com/node/1093
It allows me to only import stuff that fit a certain category but I get all the items in the feed as opposed to items in just my chosen categories.
I am just testing one category only here below:
I have one Category Mapping called "Mouse". Inside this is one line "Accessories Mouse".
I have edited /includes/admin.php at line 220 and here is my code:
/* apply category mappings */
if (isset($admin_importCategoryMappings[$category]))
{
$category = $admin_importCategoryMappings[$category];
$valid_categories = array("Mouse"=>1);
if (!isset($valid_categories[$category])) return false;
}
Am I doing something wrong in the code above? or perhaps I am going wrong in the category mapping section?
cheers,
Peter
Hello Peter,
You need to add the code after the { } rather than inside the brackets, so as it stands it won't be having any effect. Instead of:
/* apply category mappings */
if (isset($admin_importCategoryMappings[$category]))
{
$category = $admin_importCategoryMappings[$category];
$valid_categories = array("Mouse"=>1);
if (!isset($valid_categories[$category])) return false;
}
...change it to this:
/* apply category mappings */
if (isset($admin_importCategoryMappings[$category]))
{
$category = $admin_importCategoryMappings[$category];
}
$valid_categories = array("Mouse"=>1);
if (!isset($valid_categories[$category])) return false;
That should do the trick!
Cheers,
David.