This enables pathauto to create extra aliases for categories which resolve into the taxonomy_menu tree, when the taxonomy_menu module is present.

The end result is that all references to taxonomy/term go to the appropriate place in taxonomy_menu/

However, it requires this patch against the drupal base to work correctly: this patch enables the path aliases to taxonomy_menu/ to recurse up the chain to the top-level alias created by pathauto.

http://drupal.org/node/21239

CommentFileSizeAuthor
#1 pathauto.module_0.patch2.54 KBaws
pathauto.module.patch2.54 KBaws
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

aws’s picture

FileSize
2.54 KB

here is that patch again to correct a bug in the delete

mnl’s picture

I just tried this patch and the action failed in all but one place. I am patching against the most current pathauto module.

Here is the output from running patch:

Hunk #1 FAILED at 292.
Hunk #2 FAILED at 378.
Hunk #3 FAILED at 416.
Hunk #4 FAILED at 434.
Hunk #5 succeeded at 494 with fuzz 2 (offset -63 lines).
Hunk #6 FAILED at 620.
5 out of 6 hunks FAILED -- saving rejects to file ./pathauto.module.rej

mikeryan’s picture

Pathauto has been completely rewritten since aws created that patch. It's more modular now, so it should be possible to implement this without patching pathauto, by creating a pathauto_taxonomy_menu.inc file using the API I've provided. And I'm hoping aws (or someone else) will do that - I'm looking forward to getting some feedback on the API.

mikeryan’s picture

mnl’s picture

i just got back to work on this site.. so i'm trying now to use your API to create auto aliases for all taxonomy_menu paths.. but i'm not having much luck. i started with your pathauto_node.inc file, but after changing all the function names to the new module (taxonomy_menu) they don't seem be running.

an api spec would be really helpful, as would any other docs and advice. it looks like it's pretty clean and straight forward, but i must be missing something.

mikeryan’s picture

If there's anything unclear or incomplete about the API documentation in README.txt (under "Implementing automatic aliases for a module"), please let me know. Where specifically are you having trouble?

Thanks.

mikeryan’s picture

Assigned: Unassigned » mikeryan

I'm closing for this now - if there's some specific feedback on where the current API documentation in README.txt falls short, please reopen this with your comments.

Under the current design center of pathauto (as a service module for other modules), I will only support core modules in the "official" distribution, support for contributed modules is in the hands of the module authors and interested consumers of those modules.

chaosmt’s picture

I just wanted to point out to the more php aware working on the projects, that there is still interest in getting that "it just works" with taxonomy_menu working again. Perhaps it would be easier to just explain how to setup pathauto to do just that, without writing the code to make it happen. Either way, I apperciative of the help and the great work so many put forward on drupal and these modules.

dkruglyak’s picture

Status: Closed (fixed) » Active

This is an important issue. Without this fix there are two duplicate and confusing sets of category pages: One through taxonomy menu, the other through pathauto.

Any feedback on how to fix this is appreciated.

mikeryan’s picture

Can you describe what the problem you see is? Not everyone uses taxonomy_menu...

As previously mentioned, pathauto provides an API for other contributed modules to hook into its automated alias generation features. Unless something is lacking in the API, this issue probably should belong to taxonomy_menu.

diroussel’s picture

yeah, the problem probably is in taxonomy menu. I've just had this problem on a site I'm setting up, and reading the above comments would agree that it's taxonomy_menu that needs fixing.

I don't understand why taxonomy menu uses different urls to taxonomy, anyway...

mikeryan’s picture

Project: Pathauto » Taxonomy Menu
Version: 4.6.x-1.x-dev »
Assigned: mikeryan » Unassigned

Support for integrating taxonomy_menu and pathauto should come from the taxonomy_menu side. If the pathauto API or its documentation is lacking, please let me know.

brmassa’s picture

Version: » master
Status: Active » Closed (fixed)
johnv’s picture

Version: master » 5.x-1.x-dev

Reassigning, to not show anymore in 7.x issues.