Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8838303
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T09:57:32+00:00 2026-06-14T09:57:32+00:00

When going to edit account or edit profile in Drupal 7, the URL looks

  • 0

When going to edit account or edit profile in Drupal 7, the URL looks something like http://localhost/user/123/edit where 123 is the user id. Because of this, anyone can see how many users the site has, which I don’t want. Is there a way that I can change it to something like http://localhost/user/edit or something without an ID?

I’ve tried setting up a menu entry in my module, that acts as the edit account/profile page, but had no success.

Also, I don’t want to install a new module for this, I’d rather just write my code.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-14T09:57:33+00:00Added an answer on June 14, 2026 at 9:57 am

    What I did after all, was to create a hook_user_insert and to add 2 URL aliases in the urlalias table:

    user/$user->uid/edit -> user/$user->name/edit
    

    and

    user/$user->uid/edit/profile -> user/$user->name/edit/profile
    

    Hope this helps somebody.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Going to http://www.example.com/node/NID/edit , where NID is any valid nid referring to a node
Edit: It turns out I missed something obvious, but I'm going to leave the
I'm following this awful textbook, going through the basics of create/edit/delete records. The delete
I'm going to edit textbox value.. but i saw there's a problem protected void
I'm going to edit an ImageField using jquery ajax,after searching I found out I
In PHP I am going to edit some entity let say a project named:
I'm going to try building a custom language extension for Komodo Edit. In order
Edit: OK I asked the wrong question here. I'm going to be coding a
I am pretty sure this is some problem with the Apache configuration because it
Something very strange is going on with a custom view containing a TextView .

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.