Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Just wondering if there are plans for a D7 port of this? Great module with a specific and invaluable application. Thanks!
Comment | File | Size | Author |
---|---|---|---|
#31 | view_alias-d7-1138344-31.patch | 17.37 KB | rich.3po |
#28 | view_alias-d7-1138344-28.patch | 16.84 KB | rich.3po |
#24 | view_alias-d7-1138344-22.patch | 17.5 KB | Nor4a |
#23 | view_alias-d7-1138344-#22.patch | 17.5 KB | Nor4a |
#21 | view_alias.zip | 11.56 KB | Nor4a |
Comments
Comment #1
emackn CreditAttribution: emackn commentedI'd like too. Shouldn't be too hard really. Biggest issue is going to be dealing with views. Not sure if the current method of finding views with taxonomy args will work with views for D7.
Comment #2
basicmagic.net CreditAttribution: basicmagic.net commentedsubscribe
Comment #3
Maciej Lukianski CreditAttribution: Maciej Lukianski commentedSince Taxonomy is now a reference field and you have to expose it in views as contextual filter, it might be possible to create a more generic solution to use other reference fields as well (eg node->node) and create aliases for views using this as a filter as well.
Comment #4
crantok CreditAttribution: crantok commentedSubscribe
Comment #5
joelpittetHere is the port to D7
Would you mind providing me with commit access?
Comment #6
emackn CreditAttribution: emackn commentedneed to review
Comment #7
joelpittetThanks emackn, I keep forgetting that status for some reason. And you were correct the view getting arguments has changed drastically but may provide some improvements to this module.
Comment #8
pfaoclePatch didn't apply - was this against 6.x-2.2 or 6.x-2.x? Manually applied patch, but has not made module functional. Playing around with this, will comment again if I find anything useful.
Comment #9
joelpittet@leafish_paul it was patched against 6.x-2.x-dev
I am not the best at the patch formatting but I have been following the instructions. I cloned 6.x-2.x-dev to my machine, made the changes, and ran git diff > view_alias-d7-1138344.patch
Did it throw any useful errors?
Comment #10
Maciej Lukianski CreditAttribution: Maciej Lukianski commentedI found a different approach, which generates and deletes extra aliases using the rules module:
http://www.archive.org/details/LearnTheRulesFrameworkPart27-ExtraPathAli...
It can be a replacement for this module and should work for users, nodes, taxonomies
Comment #11
joelpittetI attached the zip so you guys don't have to worry about my patches until i figure out why my formatting is all messed on my git patches.
Comment #12
pfaocleThanks - I hit another issue with pathauto (#1267966: Pathauto patterns are not showing up) before I could get back to this. Seems to be working here, although there are several php notices on admin/config/search/path/patterns:
Notice: Trying to get property of non-object in _find_view_arguments() (line 231 of /snip/sites/default/modules/view_alias/view_alias.module).
Comment #13
sachbearbeiter CreditAttribution: sachbearbeiter commentedi tried #11 and so far it works fine ...
it seems, that this module saved my live, because i have to build nice urls with some views, that are taking taxonomies as arguments ...
i had the problem that views is not pathauto aware - term name as argument is not accurate - so i give the tid as argument and still get in the url a nice path ...
so i would spent a bounty for a D7 version and "Recurring Aliases" - so dear joelpittet or emackn - send me a pm if one of you want to go a little bit further ...
or are there mor generic approaches in D7 to solve problems like this? something with an default views php argument, that takes the aliased term name and uses a pathauto function to bring it into views?
thanks
Comment #14
Summit CreditAttribution: Summit commentedHi, Would this module also work on views with urls like products/[number]? I am building a view for drupal commerce product entities, and would love clean url for it.
greetings, Martijn
Comment #15
netentropy CreditAttribution: netentropy commentedI can confirm the zip in #11 works in Drupal 7 and with a site with a large number of terms.
We need to get this committed and maintained. Honestly I wish it was in Views itself.
Let me know what I can do.
Comment #16
joelpittetHere is a small patch, since people are using that d7 zip
Comment #17
emackn CreditAttribution: emackn commentedIs there a complete patch for the D7 upgrade?
Comment #18
joelpittet#5 for patch, #11 for zip + #16 for the minor fix on top
Comment #19
netentropy CreditAttribution: netentropy commentedI am having a bit of trouble with the D7 version.
If I try to use a path alias on two views for the same taxonomy term ID but different paths , that one tends to over come the other.
For example. everything on my site (tutorials, video, downloads) can be categorized by the same taxonomy term "content category"
When I set up the view path alias for questions to be filtered by "content category" the views alias work as intended, ie question/category-1
However if I build another view to sort tutorials by "content category" , when I build the path alias, instead of the expected tutorials/category-1 , it rewrites as the previous questions/category-1
thing it , it still works properly just with the wrong path.
any ideas?
Comment #20
emackn CreditAttribution: emackn commentedI'm going to create a 7 branch and try to get in the patches, if not they will have to be re-rolled.
Comment #21
Nor4a CreditAttribution: Nor4a commentedI made it working on D7.
Also rewrote the module - now it supports multiple taxonomy arguments seperated by "/". It supports also multilingual taxonomy terms - if the terms have common IDs for all the languages and localized.
Hope this functionality will be implemented in the public module release :)
Sorry - I'm using SVN and the pathcing would be too difficoult because a lot of code have been rewriten. So I'm adding all the code as an archive. Code has no Coder issues.
Comment #22
emackn CreditAttribution: emackn commentedI won't be unpacking a zip file, you will have to check out the code via git and create the patch file if you want me to look at the changes.
Comment #23
Nor4a CreditAttribution: Nor4a commentedAnd here comes the patch against 7.x-1.x which I checked out from repository.
Comment #24
Nor4a CreditAttribution: Nor4a commentedFix the name of the patch file, because # do not allow to download the file.
Comment #25
ram4nd CreditAttribution: ram4nd commentedSubscribe
Comment #26
bancarddata CreditAttribution: bancarddata commentedThis latest patch in #24 seems to depend on the internationalization module - I do not have it installed and am getting this error:
PHP Fatal error: Call to undefined function i18n_string() in /opt/apache/htdocs/drupal/sites/all/modules/view_alias/view_alias.module on line 166
Any way to modify this to not have that requirement?
Comment #27
candelas CreditAttribution: candelas commentedany news on this?
Comment #28
rich.3po CreditAttribution: rich.3po commentedHi - this is a really useful module.
I've applied that patch in #24 and noticed that not all views get picked up on the URL alias admin screen - specifically views that are in code rather than DB storage
I've made an update to fix this - see attached patch. It would be great to see a D7 release of this soon (even if dev release)
Other than this the module seems to work, but the code could use some cleaning up
cheers
Comment #29
emackn CreditAttribution: emackn commentedRich.3po,
Thanks for the patch. I'm sure others will appreciate the work as well. Tragically though, I no longer work with Drupal, so I've added you as a maintainer if you're willing. That way you can add any improvements you might need.
I'm glad that you got some use out of it. ;)
Comment #30
candelas CreditAttribution: candelas commented@rich.3po please, take it. I missed this module a lot :)
Comment #31
rich.3po CreditAttribution: rich.3po commented@emackn - ok thanks, i cant guarantee how much time i can put into this but i'll do my best to help out...
Regarding my patch in #28 i forgot to include the .info file. Heres the new patch
Comment #32
John Franklin CreditAttribution: John Franklin commentedCan we get this patch in to be a baseline D7 port? It seems to work for my very basic needs. I'm willing to be a co-maintainer of this to get a D7 port.
Comment #34
rich.3po CreditAttribution: rich.3po commentedI've now made a D7 dev release. I need to spend some time cleaning it up before rolling a full release, but it should be usable.
That said, if any other bugs are found let's address them in separate tickets
cheers
Comment #35
Leeteq CreditAttribution: Leeteq commentedGreat! So the Maintenance status and Development status of this module must be updated now, then?