我有2种内容类型（照片，视频），两者都有一个术语参考，对"主题" 分类。 主题术语在节点显示页面上显示，我想链接到照片的"/ photo /％" ，用于视频，用于视频，而不是默认的"/taxonomy/term/%".
I have 2 content types (photos, videos) and both have a term reference to a "topic" taxonomy. The topic terms are showing on the node display pages and I would like to link to "/photo/%" for photos and "/video/%" for videos instead of the default "/taxonomy/term/%".
How can I do that?
This problem is Hard if implemented the way suggested in the question. It becomes easy with pathauto if you use two separate vocabularies: video_topic and photo_topic. Then, video_topic could have pathauto paths that start with video/% and photos can have paths that begin with photo/%.
Consider: if you use a single vocabulary, then clicking on the link video/% would show both videos and photos. Same with photo/%. If this is what you want, then perhaps the path you should use should be topic/% instead of video/% and photo/%. If you do want the results to be shown separately, then separate vocabularies are definitely the way to go.
If you want to keep your video/% and photo/% vocabularies in sync, then you could add a video topic in code every time a photo topic was clicked, and visa-versa. It's important to consider how you want your system to behave, though, as that will drive the solution and implementation that you'll want to choose.
My answer is going to use two modules, that are tools, not solutions. You will get the flexibility to do most anything you want with the paths, at the cost of needing to understand how the modules work. I will provide an outline of the required configuration below, there are useful videos here, and I will try to update the answer if you get stuck anywhere specific.
Since Drupal doesn't allow you to use a variable at the first level, you can't do /%content_type/%term, so instead we create two pages. Personally, I would opt to do something like /products/%content_type/%term, as a single page will lower your maintenance burden down the road. That however, will require understand "Variants", to accommodate two pages in one. The videos will explain that.
I'm pretty sure you can set this up using Pathauto. I know for a fact that you can set custom taxonomy paths. I just did for my Drupal Commerce Site.
Just make sure that when you set a pattern, it doesn't overlap with a pattern you have set for another content type.
In Drupal 6, I've done this with the pathauto module, and a quick look at the Drupal 7 code suggests it works there as well. In D6, you go to
admin/build/path/pathauto and select
Taxonomy term paths and change it to whatever you want so something similar should work in D7.