I cant remove ?author=N url to a nicename.
-
Probably should be something simple, but I looked at many sites a solution to my problem.
I’m trying to remove the url ?author=N of a page of my site.
I want to change https://www.mydomain.com/?author=13 to https://www.mydomain.com/profile/username So far I removed author url, however the id is still there.My current code is:
} public static function get_profile_url($user_id = 0) { if ($user_id > 0) { $profile_url.="profile/" . $user_id; }
Not sure, but I think my target is $user_id I’ve used other alternatives such as $user_nicename but it still fails, any tips? thank you in advance for attention.
Viewing 4 replies - 1 through 4 (of 4 total)
Viewing 4 replies - 1 through 4 (of 4 total)
- The topic ‘I cant remove ?author=N url to a nicename.’ is closed to new replies.