Skip Navigation

[Resolved] Change "Sorry, that username already exists!" message.

This support ticket is created 8 years, 4 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Supporter timezone: Asia/Hong_Kong (GMT+08:00)

Tagged: 

This topic contains 2 replies, has 2 voices.

Last updated by JP359 8 years, 4 months ago.

Assisted by: Luo Yang.

Author
Posts
#354451

I used Cred to create a new user registration form.

Is it possible to change the "Sorry, that username already exists!" message? I didn't see this configurable at all in the CRED form builder.

Thanks.

#354466

Dear JP,

The error message is from wordpress core file, you can use wordpress filter hook gettext to modify the string as what you want, for example, you can add below codes into your theme/functions.php:

add_filter('gettext', 'mycustom_func');
function mycustom_func($translated_text){
	if($translated_text == 'Sorry, that username already exists!'){
		$translated_text = 'my error message';
	}
	return $translated_text;
}

And test again.

More help:
gettext
This filter hook is applied to the translated text by the internationalization functions
http://codex.wordpress.org/Plugin_API/Filter_Reference/gettext

#356042

This worked. Thanks!

This ticket is now closed. If you're a WPML client and need related help, please open a new support ticket.