I want to rename https://example.com/user/1 to https://example.com/user/random. I created a user pattern type: /[user:account-name] and used the bulk generate and it doesn't create the new alias for user

CommentFileSizeAuthor
#4 3.png50.52 KBruriko
#4 2.png61.04 KBruriko
#4 1.png57.13 KBruriko

Issue fork pathauto-3612151

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

ruriko created an issue. See original summary.

ruriko’s picture

Issue summary: View changes
yusuf_khan’s picture

For Drupal 11 + Pathauto:

1. Use pattern:

user/[user:name]

(not `/[user:account-name]`)

2. Enable user aliases:

/admin/config/search/path/settings

3. Check existing aliases:

/admin/config/search/path/list

Delete old `/user/1` aliases if they exist.

4. Run bulk generate with **overwrite existing aliases** enabled.

5. Clear cache:

drush cr

If it still doesn't work, check your Pathauto version supports Drupal 11.

ruriko’s picture

StatusFileSize
new57.13 KB
new61.04 KB
new50.52 KB

I thought [user:account-name] was deprecated cause when I look at the available tokens it says so. Anyway I tried all those steps and still doesn't work. I didn't need to enable the user entity since it's enabled on default. Even if I did enter user/[user:name] it will still auto add the forward slash after saving. My drupal version is 11.4.2 and Pathauto version 8.x-1.15

1
2
3

akashkumar07 made their first commit to this issue’s fork.

akashkumar07’s picture

Status: Active » Needs review

Please review this MR change.