-
Author
Tagged: Special Characters, Facebook Login. Error
-
July 9, 2018 at 12:45 #203330nikolisgtParticipant
Hello! I have problem with facebook login – register.
When the User has his / her profile name in Facebook only in Greek characters
Registration is not created, sent error in a window that says “Unable to create user with an empty name”.
July 9, 2018 at 20:19 #203397LauraModeratorHello, will assign the ticket to a higher support level who can help and advise you in your query.
Thanks! ?Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solutionLaura Solanes - Graphic Designer and Web Designer
Please be patient as I try to answer each topic as fast as i can.
If you like the theme or the support you've received please consider leaving us a review on Themeforest!
Always happy to help you 🙂
July 10, 2018 at 16:59 #203469RaduModeratorHi,
Install this plugin and check again: https://wordpress.org/plugins/wordpress-special-characters-in-usernames/
Let me know
Cheers
RHi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solutionJuly 10, 2018 at 17:31 #203471nikolisgtParticipantI have try this plugin and i have same problem. I have try it ALL ALL ALL before submit ticket.
Only one plugin make it works to no say “Unable to create user with an empty name”
This is plugin https://wordpress.org/plugins/restrict-usernames-emails-characters/
with this plugin allow user to register but username not import correct, showing username with symbol or with numbers. You can see Screenshot.
–
I have close all this plugins and i try this plugin https://el.wordpress.org/plugins/wp-facebook-login/
Register works well and greek charachters on username convert it in “Greeklish”
example: If Greek name Νίκος on username this plugin make it Nikos .
But this plugin not fully integrated with buddypress and all my community, for example, does not show the user activity Or when user login in website.Attachments:
You must be logged in to view attached files.July 11, 2018 at 15:36 #203566RaduModeratorHi,
There is a fix for wordpress to allow russian / ukrainian characters on username, if you will check to create a new user with russian you will cannot do that cuz the wordpress it not allow, please test the function and let me know
this it’s a old function that some users used in the past, just replace the characters with your specific greek ones
COPY CODEfunction kleo_translate_special_chars($str){ $tr = array( "А"=>"a", "Б"=>"b", "В"=>"v", "Г"=>"g", "Д"=>"d", "Е"=>"e", "Ё"=>"yo", "Ж"=>"zh", "З"=>"z", "И"=>"i", "Й"=>"j", "К"=>"k", "Л"=>"l", "М"=>"m", "Н"=>"n", "О"=>"o", "П"=>"p", "Р"=>"r", "С"=>"s", "Т"=>"t", "У"=>"u", "Ф"=>"f", "Х"=>"kh", "Ц"=>"ts", "Ч"=>"ch", "Ш"=>"sh", "Щ"=>"sch", "Ъ"=>"", "Ы"=>"y", "Ь"=>"", "Э"=>"e", "Ю"=>"yu", "Я"=>"ya", "а"=>"a", "б"=>"b", "в"=>"v", "г"=>"g", "д"=>"d", "е"=>"e", "ё"=>"yo", "ж"=>"zh", "з"=>"z", "и"=>"i", "й"=>"j", "к"=>"k", "л"=>"l", "м"=>"m", "н"=>"n", "о"=>"o", "п"=>"p", "р"=>"r", "с"=>"s", "т"=>"t", "у"=>"u", "ф"=>"f", "х"=>"kh", "ц"=>"ts", "ч"=>"ch", "ш"=>"sh", "щ"=>"sch", "ъ"=>"", "ы"=>"y", "ь"=>"", "э"=>"e", "ю"=>"yu", "я"=>"ya", " "=>"-", "."=>"", ","=>"", "/"=>"-", ":"=>"", ";"=>"","—"=>"", "–"=>"-" ); return strtr($str, $tr); } function kleo_extra_validate_username($valid, $username){ if( !$valid ){ $sanitized = sanitize_user( $username, true ); $valid = ( ! empty( $sanitized ) ); } return $valid; } add_filter('validate_username', 'kleo_extra_validate_username', 10, 2); function kleo_extra_sanitize_user($user, $raw_user, $strict) { $user = kleo_translate_special_chars($raw_user); return $user; } add_filter('sanitize_user', 'kleo_extra_sanitize_user', 10, 3);
It should work
Cheers
RHi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solutionJuly 11, 2018 at 20:11 #203599nikolisgtParticipantWorks! Thank you! But if users have same name system make name with numbers.
See that screenshotAttachments:
You must be logged in to view attached files.July 12, 2018 at 19:20 #203696RaduModeratorHi
Not sure why that maybe the wordpress cannot allow to have duplicated names or similar.
I think you will have to extend the snippets that i have provided to you to perform a check if the current user has same name as an existing one then to be added to database or similar, you can do this with help of a developer.
Cheers
RHi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution -
AuthorPosts
The forum ‘Bugs & Issues’ is closed to new topics and replies.