Ask Your Question

How to @refer to users with username that contains empty space?

asked 2012-06-25 03:09:25 -0500

alexandros.z gravatar image


If a user chooses a user name like "John Smith" (has a blank space between the first name and last name) do you know how I can @ reference to him?

I tried these but with no luck:

  • @John Smith
  • @John-Smith
edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted

answered 2012-06-29 09:43:14 -0500

powlo gravatar image

I just tried to reproduce this and I can @refer to users that have a space in the title. The url to the users profile should convert the " " to a "-", so "John Smith" becomes http://<site>/users/<user_id>/john-smith/. The user referred to also needs to exist. There can't be a space between the @ and the first character. Comments are not processed dynamically, ie if you @refer to someone that doesn't exist, then at the user so they do exist, the original comment will not pick up that the new user exists and can be legitimately @referred to.

I'm using the latest version from github, v0.7.43. So it's possible that there has been a fix added. What version of askbot are you using?

And what are you seeing when you try to @refer to a user with a space in the user name?

edit flag offensive delete link more


What is an example of a @refer to a user with a space in his username? Does @john-smith work? The OP indicated that this does not work, unless the @refer has to be all lowercase?

todofixthis gravatar imagetodofixthis ( 2012-06-29 10:16:03 -0500 )edit

@john-smith doesn't seem to work. @john smith (case insensitive) does.

powlo gravatar imagepowlo ( 2012-06-30 11:28:39 -0500 )edit

I can't get this to work over at ROS Answers, e.g. I tried @Firstname Secondname, @firstname secondname, @firstname-secondname. In the first two cases, the reference is wrongly linked to another user call "firstname". In the second case, nothing happens. I ensured, that there is no space between the @ and the first character and the user exists. Anyone knows what's going/am I doing wrong?

bit-pirate gravatar imagebit-pirate ( 2013-09-06 23:12:25 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower


Asked: 2012-06-25 03:09:25 -0500

Seen: 142 times

Last updated: Jun 29 '12