You are here:  » Mapped Categories, but some are not appearing


Mapped Categories, but some are not appearing

Submitted by bat on Sat, 2011-01-15 14:36 in

Hi David
I've mapped some categories on {link saved} but after I import the feeds, some of these mapped categories aren't showing up. Any ideas?
I saw on another thread you talked about white space, and to use the 'trim' filter, but i cannot see any 'trim' filter in the filter section.

Also, is it possible to put map one original category into 2 different categories?

Thanks

Submitted by support on Sat, 2011-01-15 16:52

Hi bat,

Are you still seeing categories that you had tried to map showing up in the category list rather than what you had mapped them to? Normally when that's the case, it's because not all feeds that contain the original category names have been imported.

If you want to confirm that white space isn't the issue, you can add the Trim filter to your site by pasting the following code into the end of includes/filter.php just before the closing PHP tag:

  /*************************************************/
  /* trim */
  /*************************************************/
  $filter_names["trim"] = "Trim";
  function filter_trimConfigure($filter_data)
  {
    print "<p>There are no additional configuration parameters for this filter.</p>";
  }
  function filter_trimValidate($filter_data)
  {
  }
  function filter_trimExec($filter_data,$text)
  {
    return trim($text);
  }

Unfortunately as a product only belongs to one category it's not really possible to map an original category to multiple mapped categories. Is your requirement here that you would like certain products to show up in more than one category?

Cheers,
David.
--
PriceTapestry.com

Submitted by bat on Sat, 2011-01-15 17:45

I've tried that Trim code, but its not solved it.
The original category names for the missing mapped categories aren't showing up either. So it looks like I have mapped them correctly but the mapped category isn't appearing so those categories are in limbo and can't be accessed.

For example, i have mapped all the textile clothing into one category called, Textile Clothing. But its not appearing.

Submitted by support on Sat, 2011-01-15 19:14

Hi bat,

Could you drop me an email with a link to the installation and password for /admin/ and I'll check it all out for you...

Cheers,
David.
--
PriceTapestry.com

Submitted by tisbris on Sat, 2013-04-13 18:50

Hello David

I'm struggling with this product mapping.
The issue is that some categories doesn't get mapped, but others do.

I also tried this trim feature with no luck.

I have a mapped categori called Books.

These product has been mapped but still has it's own categories:

Books and Mags gt Brilliant Idea
Books Books Educational and info
Books Books Guides to a better s

mapping:
=Books and Mags gt Brilliant Idea
=Books Books Educational and info
=Books Books Guides to a better s

These are only samples as there are many more categories that doesn't get mapped?

Once again - please help :o)

Submitted by support on Sun, 2013-04-14 08:54

Hello Brian,

I notice that the initial values are being truncated as they are quite long values and also appear to contain a hierarchy - where you see "gt" in these examples they are most likely in the feed as &gt; however the "&" and ";" are stripped by normalisation.

It possible that a browser anomaly means that the mapped value is not exactly matching the database value, but in the first instance it is actually safe to extend the size of the `category` field significantly. To do this, create and run the following dbmod.php script which will increase the field size:

<?php
  
require("includes/common.php");
  
$sql "ALTER TABLE `".$config_databaseTablePrefix."products`
            CHANGE `category` `category` VARCHAR(150) NOT NULL default ''"
;
  
database_queryModify($sql,$result);
  print 
"Done.";
?>

After running the script, re-import all feeds and then re-create a test mapping (as the database values will now be much longer) and see if that does the trick; if not let me know and I'll help you investigate further...

Cheers,
David.
--
PriceTapestry.com