Drupal pathauto token [term:parents:join-path] works wrong

1.2k views Asked by At

If parent term url wasn't autogenerated. And children term url was generated using token [term:parents:join-path], it use wrong parent category url (autogenerated, but not real).

Imagint we have set Blog taxonomy terms URL aliases generation rule to be [term:parents:join-path]/[term:name]

And we have categories structure: "Parent Category" with URL "my-parent-category" filled by hands.

"Sub Category" we will get URL"parent-category/sub-category" but not "my-parent-category/sub-category".

So if you filled some parent category URL by hands, you would have to update each subcategory URL and nodes URLs as well (if your node URL structure use full path throw the terms)

1

There are 1 answers

5
Dave Reid On

Answered in https://www.drupal.org/node/2311207

[term:parents:*] defaults to all the names of all the parent terms. You are wanting the actual URL alias of the parent term itself, not all parents, which is a different token: [term:parent:url:path] I believe.