• Resolved dawe90

    (@dawe90)


    Hello, i am trying to import products for almost 4-5 days. I have finally solved how to import variable products with xml, after that i can’t change categories during import. I search forums and docs and youtube but i cant find anything about manual mapping of product categories. Here an example about what do i want to do.

    Product Category in Xml i am importing:

    top clothing >> dresses >> tunics

    (hierarchical style, all of it in just one category path)

    i want to import this in

    Woman >> Clothing >> Dresses >> Tunics

    i have tried adding mapping rule like this

    in your file: Clothing >> dresses >> tunics Translated to: woman >> clothing >> dresses >> tunics

    But there was no difference :/

    i have tried function editor with this code

    [str_replace(“Clothing >> dresses >> tunics”, “woman >> clothing >> dresses >> tunics”, {categories[1]})]

    and i got syntax error unexpected “{” and expected “)” error or something while i’m saving function file. I don’t know how to code php functions, i tried everything what i can do.

    if this problem will be solved, im going to take videos, writing articles, and screaming at every window i see to how to be solved this…

    • This topic was modified 4 years, 1 month ago by dawe90.
Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author WP All Import

    (@wpallimport)

    Hi @dawe90,

    i have tried adding mapping rule like this

    in your file: Clothing >> dresses >> tunics Translated to: woman >> clothing >> dresses >> tunics

    But there was no difference :/

    Is “Clothing >> dresses >> tunics” the exact string that’s in your import file? If so, the mapping rule should have worked, but you’d need to make sure that “Apply mapping rules before splitting via separator symbol” is enabled. Please see: https://d.pr/i/Cov8ua.

    Let me know how it goes with that option.

    i have tried function editor with this code and i got syntax error unexpected “{” and expected “)” error or something while i’m saving function file.

    That’s an inline function, so you’d use it in the import template, you wouldn’t save it in the Function Editor. If you decide to use a PHP function, you can modify this one with your translation rules and use it: https://d.pr/zqrSxm.

    Plugin Author WP All Import

    (@wpallimport)

    Hi @dawe90,

    I’m marking this as resolved since it’s been a while. You can follow up in this thread if you still have questions.

    Anyone else with questions, please start a new topic.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Manual Category Mapping, Help’ is closed to new replies.