This argument allows the existing URL arguments to be included into the path. This opens up the ability to drilldown results. My implementation needs some work, but works if your view is configured correctly.
taxonomyblocks.module:933
// Add the current args to the path.
$prefix = substr($pathpattern, 0, strpos($pathpattern, "%"));
$args_str = substr($_GET['q'], strlen($prefix));
if(strlen($args_str)) {
$path = str_replace('%args', substr($_GET['q'], strlen($prefix)), $path);
} else {
$path = str_replace('/%args', substr($_GET['q'], strlen($prefix)), $path);
}
| Comment | File | Size | Author |
|---|---|---|---|
| #5 | taxonomyblocks-798472-path-multi-arg.patch | 1.05 KB | recrit |
Comments
Comment #1
PixelClever commentedThis functionality already exists... I think the issue is just documentation. To do what you want you use the following placeholder format: %arg(1) which calls argument 1. Any argument can thus be called.
Comment #2
PixelClever commentedI updated the official documentation to list the available placeholders at http://pixelclever.com/documentation-advanced-taxonomy-blocks-module-dru...
Comment #3
vangorra commentedThe functionality does exist on a per-argument basis, but when you have a view created that takes n arguments. The arg(n) no longer operates all the well.
Exmaple:
site.tld/view/%arg(2)/%arg(3)/%arg(4)
can produce
site.tld/view/1//
Notice the empty slashes.
site.tld/view/%args
can produce
site.tld/view/1
No more empty slashes.
Comment #4
PixelClever commentedHmmm... Then it really just sounds to me like the existing %arg() placeholder needs to be fixed so that there isn't any empty spaces left in. I would say it's a bug that I need to fix. It may take me a little while to get around to it, but if you post a working patch I will apply it.
Comment #5
recrit commentedi ran into a similar situation for the multiple arguments. The attached patch has worked for me in my limited test case.
Comment #6
PixelClever commentedAfter considering this I have decided to just make the path replacement function a themeable function in the next version. That way you can manipulate the path as you like from a theme or a module. The patch above will work for some people, but for other people it will break things.
Comment #7
dobe commented