Coder Social home page Coder Social logo

Comments (5)

Jimmi08 avatar Jimmi08 commented on May 18, 2024

Next result:
if there is display name with those character, unique names are not correct, checked unique-mentions.txt

array (
  0 => '@Mi',
)

This same happens if Display name contains spaces.

from mentions.

arunshekher avatar arunshekher commented on May 18, 2024

@Jimmi08, Thank you & Sorry for the late response.

Yes the currently used RegEx pattern does not match those latin scripts with diacritic marks (accents) or non-latin characters at all.

I have improved the RegEx pattern in a development branch that adds support for these characters and they should be ready for release soon.

from mentions.

Jimmi08 avatar Jimmi08 commented on May 18, 2024

Hi and thank you. I am not sure if I didn't write this somewhere else too but the problem is somewhere else.
The display name can have spaces too now. But normally there should be the same rules as for loginname (not real name - field names are really confusing here)

We solved this by setting display name = login name and this way members can't change it. I really can't remember now what fields are used by your plugin but now I found that there was a similar solution in old gold system plugin, I will check it when I find the time.

from mentions.

arunshekher avatar arunshekher commented on May 18, 2024

For all user matching this plugin only check for 'user_name' field in user table.

And fetches user_id, user_email, user_image, user_login fields for autocomplete popup and emailing.

We solved this by setting display name = login name and this way members can't change it.

By that did you mean its solved in the current development version of e107inc/e107 repo?

I firmly believe if it has problems finding latin characters with diacritic marks from 'user_name' table that's because its not implemented yet.

from mentions.

Jimmi08 avatar Jimmi08 commented on May 18, 2024

Hi, no changes in core. This is how I understand this, I could be wrong.

User can have different user_name and display name. This is set in preferences and you can allow it only for some classes.
For example. my login name is Jimako but users can see me as Main Admin. They don't know my login name because it's not displayed, so they will search for the display name. By setting display name = login name in core prefs, they will see user name now and they will look (type) for Jimako. Do you know what I try to say? (or my user name is totally different to have it safe and they see only Jimako)

I didn't know this, but we are importing users from other database and they are used to look up for real names not nicknames. Of course, It was easy for me to customize your code to check user_login (display name) but then we have that problem with characters and spaces.
For now we tell them that there is no other option, we will see how they will get used to user names.

I don't know what is correct.

EDIT: there are fields: user_name, user_loginname, user_login. Sorry, I really can't remember which one is used where.

from mentions.

Related Issues (14)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.