The forum of the forums
Welcome to the Official Support Forum of Forumotion!

To take full advantage of everything offered by our forum, please log in if you are already a member, or join our community if you've not yet.



Create a free forum like this one.

Mentions for usernames

View previous topic View next topic Go down

Solved Mentions for usernames

Post by Luffy on 10/4/2014, 11:19

Hello. I want to add mentions for the usernames in my forum. Someone gave me this code to add to javascript but doesn't seem to work! Can someone help me?

Code:
$(function () {
  var a = $('.name').get();
  for (i = 0; i < a.length; i++) {
  $(a[i].getElementsByTagName('a')[1]).dblclick(function (e) {
  e.preventDefault();
  document.getElementById('text_editor_textarea').value += '@[url=http://' + window.location.host + '/profile?mode=viewprofile&u=' + $(this).text() + ']' + $(this).text() + '[/url]';
  });
  }
});


Last edited by Marios94 on 11/4/2014, 10:02; edited 1 time in total
avatar
Luffy
Manager
Manager

Male Posts : 4624
Reputation : 466
Language : Greek, English
Location : Greece

http://helpgr.forumgreek.com/forum

Back to top Go down

Solved Re: Mentions for usernames

Post by Van-Helsing on 10/4/2014, 19:05

Hi Marios,
Please check this post http://help.forumotion.com/t116032p30-mention-mentioning-a-member-or-user if it is working.

Best Regards,
Dark-Avenger
avatar
Van-Helsing
Hyperactive

Male Posts : 2295
Reputation : 90
Language : English, Greek

http://helpgr.forumgreek.com/

Back to top Go down

Solved Re: Mentions for usernames

Post by Luffy on 10/4/2014, 20:44

I checked it. It's from there that they gave me the code. If someone who knows doesn't help there is no way that this will work. Unfortunately it doesn't work with any code its given in there.





avatar
Luffy
Manager
Manager

Male Posts : 4624
Reputation : 466
Language : Greek, English
Location : Greece

http://helpgr.forumgreek.com/forum

Back to top Go down

Solved Re: Mentions for usernames

Post by Van-Helsing on 10/4/2014, 21:41

Hi Marios,
Have you check Dom's Tutorial about advanced tagging system at http://fm.domdevelops.com/scripts/advanced-tagging-system.html ? Try this, it maybe works.

With Best Regards,
Dark-Avenger
avatar
Van-Helsing
Hyperactive

Male Posts : 2295
Reputation : 90
Language : English, Greek

http://helpgr.forumgreek.com/

Back to top Go down

Solved Re: Mentions for usernames

Post by Luffy on 11/4/2014, 00:52

Τhis is amazing thank you!

Solved
avatar
Luffy
Manager
Manager

Male Posts : 4624
Reputation : 466
Language : Greek, English
Location : Greece

http://helpgr.forumgreek.com/forum

Back to top Go down

Solved Re: Mentions for usernames

Post by Jophy on 11/4/2014, 13:55

Solved
avatar
Jophy
ForumGuru

Male Posts : 17924
Reputation : 835
Language : English
Location : Somewhere

Back to top Go down

View previous topic View next topic Back to top


 
Permissions in this forum:
You cannot reply to topics in this forum