Mention Users with @ Download 1.9.1

us bryce alvord 1 year ago

OSSN MENTION USERS COMPONENT

This component enables a user to mention other users in posts and comments by using the syntax @Full Name or conditionally @username and that will send the mentioned user a notification telling them that they were mentioned in a post or comment with a link to that item.

This can be used in conjunction with the Display Username component as of v1.2 if you want to display usernames and mention @username instead of display Full Name and mention @Full Name. It will dynamically switch based whether or not the Display Username component is installed and turned on. You can find more info on it here: https://www.opensource-socialnetwork.org/component/view/3065/display-username

  • When mentioning usernames using the Display Username component the exact casing must be used to match the user.

  • When mentioning user full names the casing DOES matter as that can help find uniqueness.

  • Mentions are not limited to the friends of the user, the entire user base can be mentioned

  • Multiple mentions can be done in a post or comment.

CHANGE LOG
-------------------1.9.1------------------

  • Added ability to parse off trailing '(apostrophe) and 's for use in plurals and ownership

  • Added recommended method and hooks from Z-Man

-------------------1.9--------------------

  • Added 'ossn:notifications:mention:post:created' to en locale

  • Added 'ossn:notifications:mention:comment:created' to en locale

  • Renamed init method from basic name to prevent potential collision with other components

POSSIBLE ENHANCEMENTS

  • No UI based on prototype having significant cons

  • ?

Comments
us Philip Lozier Replied 5 days ago

@Bryce alvord ... Just an accidental find. Was looking at the "invite firends" feature in "groups", and apparently it has a user lookup that works quite well. As I was typing it brought up user names and a thumbnail of their profile pic.

us Philip Lozier Replied 6 days ago

@Bryce alvord,

I hope you didn't get me wrong... I love the component. Just also was noticing the lack of reasonable message threading when we had it on even text based Bulletin board Systems decades ago, before even public internet. Full message threading and reply chains. Anyway, as Sri Visaya Yogi mentioned, doesn'y have to be a link or anything that fancy. Just a color change. I;m not a developer, but I would think that just by the fact that it sends the user a notification that some sort of simple lookup has already been made, no? Otherwise, HOW does it send the notification?

When it sends the notification couldn't a simple function be to change the text color blue, or something, from where that notification was triggered int he first place? If I knew ANYTHING about development I would try it, but... new jack city.

When I first looked at this, I thought it wasn't doing anything by the simple fact that was no kind of physical indication on the user end that it did. If it made that impression on me, then it even more so WRT the end user.

In all reality, there is A LOT of competition in this. There are also WAY cheaper social network softwares (I have premium and almost all the paid components) with a much more polished look. Just look on code canyon. Problem with them is that the level of customization, as in me being able to integrate other things into it and make it look like part of the system, is very, VERY, good with OSSN, but not with those other ones. They have a more polished look, with all, ALL, of the BASIC functions fully intact.

If I could have the basic functionality some of those have in the same manner, with the adding in of things to level I have started to do with OSSN, it would be like a wet dream... but... i have a long list to make that a reality. Aside from better (but basic) message and sharing features, the little things like thumbnails for group and page searches showing how many members and last post dates, realistic and more detailed user notifications just even enough to give the end user an idea of when at what post, message, etc, anyone may have liked or commented on, etc. being able to friggin be able to easily delete old notificationse, etc. Notifications don't even give a DATE, as it stands. Can't even know which ones have beemn looked at or not. I mean, come on, man/... this is basic stuff. I hope the developers take head. I LOVE OSSN for some of the things it has, but then feel that certain features are severely lacking, and even outright antiquated on others. Anyway... rant over. Appreciate that you have done what you have done.

regards,

Phil

ph Sri Visjaya Yogi Replied 7 days ago

How about instead of converting the user's name into a link (which links to the profile page) with @, how about change it's font color instead? So at least, people can identify it easily? Is it possible? Hmm, just a thought. :)

us Bryce alvord Replied 7 days ago

Hey Philip, I understand what you mean, I have been doing development for a bit so it's obvious that it would be great to do a lookup/search for users and make the name blue or something. The ossn architecture was never designed to be compatible with those features and adding them proved to be a major performance hit which only gets worse as user count increases. Z-man was nice enough to help me understand the ossn codebase and I created a proof of concept doing a lookup of users as you type and the performance sucked bad. It's not anybody's fault, it's just that I was not able to find something that was a good solution. If you or someone you know wants to explore some javascript libraries and do a proof of concept then I would be happy to help where I can. Sincerely I would love to have a solution and fill that hole in functionality. Thanks!

Bryce

us Philip Lozier Replied 1 week ago

This needs to have some indication to the end user creating the mention that it actually did something. Why? Because end users don't always understand 'hidden" functionality, and they are used to seeing something to indicate that a function has been completed when on other competative sites using other software. It's kind of a basic no brainer if you're trying to keep end users.

us Scotty maturin Replied 1 month ago

i cant get this to work at all

ph Sri Visjaya Yogi Replied 1 month ago

Hello publisher, any new update for this component? :) I hope you can add a feature to it like, the name will become a link once the user is tagged and font color will be changed .... or your could make it something like how adding group member names work where in their names will be highlighted in blue :)

Thanks for the component, I hope you'll update this one soon or someone in the community will update it . :)

German ~Z~ Man Replied 4 months ago

As for the technical part (just looked into your code)
The stripping in general is done via input() before saving records
When your com_wall_created is called the record already has been saved, though,
that is: no further stripping will be done.

So, theoretically (since you know the object id at that stage) your parser could add a blue span around mentions and you could rewrite the now colored object record with your own low level db query :)
But to make things really complete you would need to handle edits, too - otherwise your extra html would be removed again on saving. Yeah ... a rather tricky job that I doubt it's worth it.

German ~Z~ Man Replied 4 months ago

Honestly, I have no idea what all this 'blueish' stuff could be good for?

If it's my intention to leave Bryce Alvord a notification because my posting may be of interest for him, the name "Bryce Alvord" just passed my brain, I would add a "@" in front of his name, maybe do a spell check, and that's it. I don't need no blue reminder again that I just mentioned Bryce.

Bryce would receive a notification then - leading him directly to my posting, and once more a blue emphasis of his name wouldn't make much sense, because Bryce knows best that he IS Bryce.

3rd parties? Okay, may be focused that I mentioned Bryce. So what?

Breton Caroline Milk Replied 5 months ago

Hello, Bryce!

Exactly this , makes it easier to read.

Component

Developer: bryce
License GPL v2
Type: Communication
Minimum Requirement: 5.x
Latest Version: 1.9.1
Last Updated 1 year ago
Repository Url View Repository

Versions