On xml import I would like to duplicate my 'category' field data into another field called 'category_map' in my 'feeds' table.
I would like this to be done before the 'global filters' or 'category mapping' is applied to the import data.
Can you help me with this please.
Option 2 worked perfectly for me.
Thankyou again David, your support is Phenomenal.
Hi Peter,
If all your feeds are the same format, simply go to Global Filters and add a new Text After filter to your category_map field. In the text box on the configuration page for the filter use the placeholder
%CATEGORY%
...where CATEGORY is the field name within your feeds that is registered as the category field.
If that's not an option because your feeds have different formats a single line of code at the top of the import record handler function in includes/admin.php will do the trick - look for the following comment around line 216:
/* apply user filters */
...and insert immediately before that point:
$importRecord["category_map"] = $importRecord["category"];
...and that will set your new category_map field to be equivalent to the category field regardless of feed format or registration...
Cheers,
David.
--
PriceTapestry.com