Перейти к содержанию

BlackShot

Пользователи
  • Постов

    254
  • Зарегистрирован

  • Посещение

  • Победитель дней

    1

Сообщения, опубликованные BlackShot

  1. 10 hours ago, Xontero said:

    Logically, if two users use the same username, there will be problems when they try to login. This is usually prevented in user management systems so that each user has a unique username.

    A common way to avoid conflicts in usernames is to use a unique user ID. In this case, each user is assigned a unique identifier, which can be numeric or string. The user ID is used as a unique criterion for identifying each user, and the user name can be repeated.

    For example, in a user registration system, users can choose their usernames, but the system must have a mechanism to ensure that no one person chooses the same username. This is usually done using a database and looking up previous usernames.

     

    My approach: You should break the link between the username field and the database to not perform any validation and allow users to select duplicate names. You must then make sure to set up a login method using email, otherwise the system will not be able to determine the profile.:bz:

     

    In professional user management systems, the best approach to avoid conflicts in usernames is to use a unique identifier for each user, such as a userid.

    The method you describe can lead to system security and unreliability issues. From a security point of view, disabling the association of the username field with the database can create vulnerabilities in the system, since the username must be unique to identify each user and prevent unauthorized access to accounts. Also, associating a login method with email can cause other problems because email cannot by itself be a reliable and unique identifier for each user.

     

    8 hours ago, WaNted said:

    In general, this can be done. But you need to provide interactions with the name in the engine. For example, the \IPS\Helpers\Form\Member field gets users by name, and if you select a user with a name that already exists, it will store the first user with that name in the database, and not the one we need. Disable authorization by name, and leave only by email, etc. For good, you need to write a plugin here.

    Спасибо ребята! Я уже думал о том, чтобы разрешить вход только через электронную почту, а не через электронную почту и имя пользователя.

    Итак, достаточно изменить вариант входа в систему и удалить проверку на дублирование имени пользователя? Кто-нибудь знает, в какой файл мне нужно заглянуть, чтобы внести эти изменения? Потом попробую написать для него простенький плагин.

    РЕДАКТИРОВАТЬ:

    Хорошо, я только что прочитал это снова. Мне нужно будет внести больше изменений, чем ожидалось. Я все еще готов сделать это. Если кто-то может помочь с более конкретными шагами или примерами, я был бы признателен!

    По крайней мере, о том, как заставить поле «Member» правильно извлекать данные.

  2. 10 hours ago, dfdgfgfsd said:

    добавлять рандом строку к имени и ее скрывать

    ну или поправить движок так чтобы принимал одинаковые имена

    Какой из них легче? Не могли бы вы просветить меня, как начать делать что-то из этого?

  3. Привет,

    Я требую, чтобы все мои пользователи регистрировались под своим полным именем. Однако в моей стране есть несколько распространенных имен. Это может стать проблемой в будущем.

    Я хотел бы разрешить дублирование имен пользователей на своих форумах. Как мне это сделать?

  4. On 3/17/2023 at 6:46 AM, MrHaim said:

    ...

     

    I looked for the plugin in the marketplace and couldn't find it.
    Can you send a link here? Maybe they changed the name of the plugin?
    If it costs money and is relatively cheap I will buy it, if I don't try to find a newer version

    I'm still on 4.6.9, I haven't bothered upgrading yet. Is it displaying an error or it's simply not doing anything?

  5. Как я могу сделать так, чтобы пользователи получали уведомления по электронной почте, когда они получают предупреждения или когда они забанены? Есть ли плагин или опция для этого?

  6. On 9/8/2022 at 6:48 AM, aLEX49566 said:

    Well, I wrote my opinion - comment and like what you don't know - this is complete stupidity

    What is this for? What is the connection in the ability to download something and put comments and likes in advance? Think about what is decided by the logic of the complete? A person must decide for himself whether to comment on it or not, to like it or not .. the feeling that in the circle of fly agaric clamped and rural dictatorship

    Dude. A lot of people go into forums just to download stuff. If they've clicked the file in the first place, it's either because they were already looking for it or because it interests them. In the end, most files are useful but people don't even say a word about it.

    Reacting to files is a way to thank the poster in advance. At least there'll be a little be of gratitude and incentive for the author to keep sharing more files.

    If you end up not liking it, just remove your reaction. It takes less than 1 second.

  7. It is easier than I thought. I found this answer on another forum:

    Go to post template and add this to the top:

    {{if !isset(\IPS\Output::i()->metaTags['og:image'])}}
    	{{preg_match('~<img[^>]*?src="(<fileStore.core_Attachment>([^"]*))"[^>]*>~i', $comment->content(), $matches); }}
    	{{if isset($matches[1])}}
    		{{\IPS\Output::i()->parseFileObjectUrls($matches[1]);}}
    		{{\IPS\Output::i()->metaTags['og:image'] = $matches[1];}}
    	{{endif}}
    {{endif}}

    @by_ix

  8. 10 hours ago, ZIKURIK said:

    захукать надо метатег который выводит картинку, например og:image и подставить изображение туда

    Хм, я думаю, что приложение, которое я разместил там, уже делает это. Но почему-то не работает. Не могли бы вы рассказать нам пошагово, ZIKURIK? 🤔

  9. 1 minute ago, by_ix said:

    BlackShot If there is time for this, I will not promise anything.

    Спасибо. Приложение, которое я вам отправил, автоматически захватывает основные фотографии тем и превращает их в миниатюры. Может быть, вам просто нужно изменить тему. Я пытался искать, но не смог найти.

    @HooLIGUN ты хорошо разбираешься в таких вещах? 9_9

  10. 3 minutes ago, by_ix said:

    I asked this question a couple of times, but didn't get it.

    О, это несчастье! Как вы думаете, вы можете проверить приложение, которым я поделился, и посмотреть, сможете ли вы его отредактировать? Кажется, что он делает большую часть работы в этом смысле.

×
×
  • Создать...