Hello
Most of the feeds I use from Affili.net, Awin, etc. have a category tree that looks mostly like this: Category1> Category 2> Category 3 or Category1 / Category2 / Category3 or Category1, Category2, Category3.
how can I just import the names or at least only the last category?
Thanks and Greetings
Marco
Hello
Can you explain the second step to me, unfortunately my english is not that good.
Do I have to continue with "Category Hierarchy Mapping"?
Can you send me a screen?
Thank you very much!
regards
Marco
Hi Marco,
It is not "Category Hierarchy Mapping" sorry for the confusion, I was just referring to the hierarchy in your feeds, that's all! I have removed some from the post above, let me know if you are still not sure of course..
Cheers,
David.
--
PriceTapestry.com
Yes, now I know even less :-)
I have adjusted the line in admin.php, but after importing I have the same problem? Can I send you an e-mail with screens, can I upload files in the forum?
Hello Marco,
Of course, please email me I will check it out first thing tomorrow with you...
Cheers,
David.
--
PriceTapestry.com
Perfect ... it works. You are brilliant!
Greets
Marco
Hello again,
what is who the categories with a "," are separated. Do I have to put a backslash before?
$importRecord["category"] = tapestry_normalise($importRecord["category"],">,\/,#,,");
or
$importRecord["category"] = tapestry_normalise($importRecord["category"],">,\/,#,\,");
regards
Marco
Hi Marco,
The list isn't actually comma separated - the comma in the original code above is actually the comma to be allowed in the name...
The only character that needs to be escaped is forward slash, so the following should do the trick...
$importRecord["category"] = tapestry_normalise($importRecord["category"],">,\/#");
Cheers,
David.
--
PriceTapestry.com
Hello,
Thank you very much!
I have a feed that has an enumeration at the Brand: "Apple, Samsung, Huawei, etc."
Can I also use it with Explore Filter (-1) at Brand?
regards
Marco
Hi Marco,
Sure - all the filters can be used against any field as required...
Cheers,
David.
--
PriceTapestry.com
Hello
I also need to customize the
"$ importRecord [" brand "]" ?
because I just remove the "," and paste them all together, like this:
AcerAmazonAppleAsusBlackberryFitbitFossilGarminGoogleHTCHuaweiLe
regards
Marco
Hi Marco,
Ah sorry I didn't mention that, the same modification to normalisation of brand will be required. To do this, edit includes/admin.php and look for the following code at line 222:
$importRecord["brand"] = tapestry_normalise($importRecord["brand"]);
...and REPLACE with:
$importRecord["brand"] = tapestry_normalise($importRecord["brand"],",");
Cheers,
David.
--
PriceTapestry.com
Hello
It's not "Brand".
Can I send you the feed link to test?
regards
Marco
Hello Marco,
Sure, if you're having problems with a specific feed you can email me a link (or attached /zipped if not too large) and I will check it out on my test server for you...
Cheers,
David.
--
PriceTapestry.com
Hello
worked, had to empty the cache again, sorry :-)
Greets
Marco
Hallo David
I have the following category in the feed: "Wohnen & Haushalt - Papeterie - Bürobedarf - Korrektur"
If I use the filter " - " and Explode "-1" then there is only: "Wohnen & Haushalt Papeterie Bürobedarf Korrektur"
But I only want the category: "Korrektur".
Do you have a solution?
regards
Marco
Hi Marco,
"-" is stripped by the normalisation so by the time filters are applied it is no longer in the category value to explode using.
What you can do is move the category normalisation to after the filters have been applied. To do this, edit includes/admin.php and look for the following code at line 198:
$importRecord["category"] = tapestry_normalise($importRecord["category"]);
...and comment out by replacing with:
/* $importRecord["category"] = tapestry_normalise($importRecord["category"]); */
Then look for the following code at line 259:
if ($filter_dropRecordFlag) return;
...and REPLACE with:
if ($filter_dropRecordFlag) return;
$importRecord["category"] = tapestry_normalise($importRecord["category"]);
Cheers,
David.
--
PriceTapestry.com
Hi Marco,
Sure - you can use the Explode filter to do this, but you'll need to make a small modification first since the characters used to separate the categories are stripped before filters are applied. To do this, edit includes/admin.php and look for the following code at line 265:
$importRecord["category"] = tapestry_normalise($importRecord["category"]);
...and REPLACE with:
$importRecord["category"] = tapestry_normalise($importRecord["category"],">,\/");
With this in place, using > as an example, add a new Explode filter to the Category field using > as the "Explode Character or String" and -1 as the "Return Index" which returns the last item in the category list...
Cheers,
David.
--
PriceTapestry.com