When fixing filenames for existing files it would be useful to be able to redirect visitors, who may have bookmarked the old paths or otherwise shared the URLs, to new the new ones. To that end, it would be very useful if transliteration_retroactive() could:

  • Check if path_redirect is installed,
  • If so, add a {path_redirect} record for the file.
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

Dave Reid’s picture

Would be great, as long as the proper APIs are used and not direct db queries to {path_redirect}. That bit us multiple times with pathauto.

jwilson3’s picture

Status: Active » Needs review
FileSize
1.04 KB

Please have a look...

DamienMcKenna’s picture

Looks simple, looks good. Anyone else care to test?

bsztreha’s picture

I also need this feature, i test and seems ok!
Patch created the alias, and it works

jwilson3’s picture

Status: Needs review » Reviewed & tested by the community

In light of #4, might I venture to RTBC my own patch, or is that going to far?

amateescu’s picture

Version: 6.x-3.0 » 7.x-3.x-dev
Status: Reviewed & tested by the community » Patch (to be ported)

Tested this one manually and it worked as advertised so I commited #2 to 6.x-3.x.

Needs to be ported to 7.x-3.x for the Redirect module.

amateescu’s picture

Assigned: Unassigned » amateescu
Status: Patch (to be ported) » Needs review
FileSize
984 bytes

Started to work on this.

amateescu’s picture

Status: Needs review » Fixed

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.