|
Post by Wormopolis on Mar 22, 2009 13:22:35 GMT -8
browser tested: IE and FF placement: global footer
lets you place [user]username[/user] in a post for a quick link to that user's profile.
<script type="text/javascript"> <!-- // USER tag - v1.2 // by Wormopolis - wormocodes.proboards.com // place [user]username[/user] in a post for quick link to their profile // optional: put [user=display text]username[/user] if you want it to show something other then username as the link text // keep header intact - do not rip // UBBC button by stevevb
var ubbcTrayButton="http://i197.photobucket.com/albums/aa250/WORMOPOLIS/usertagbutton.gif"; // set this variable to ="" if you dont want a button in the tray
if (pb_action.match(/display|recent|search2|pmview/)) { for (tds=document.getElementsByTagName('td'), e=0; e<tds.length; e++) { if (tds[e].colSpan==3 && tds[e].vAlign=="top" && tds[e].firstChild && tds[e].firstChild.nodeName.match(/hr/i)) { while (tds[e].innerHTML.match(/\[user(=(.*?))?\](.*?)\[\/user\]/)) { var nme='', optDname=''; nme=RegExp.$3; if (RegExp.$1) optDname=RegExp.$2; nwHTML="<a href='/index.cgi?action=viewprofile&user="+nme+"'><b>"+(optDname ? optDname : nme)+"</b></a>"; tds[e].innerHTML=tds[e].innerHTML.replace(/\[user(=(.*?))?\](.*?)\[\/user\]/,nwHTML); } } } } if (document.postForm && ubbcTrayButton) { var ubbcTray=document.postForm.color.parentNode; ubbcTray.appendChild(document.createElement('br')); var nwbtn=document.createElement('a'); nwbtn.href="javascript: add('[user]','[/user]');"; var btnimg=document.createElement('img'); btnimg.src=ubbcTrayButton; btnimg.border='0'; nwbtn.appendChild(btnimg); ubbcTray.appendChild(nwbtn); } // --> </script>
Preview: self explanatory
|
|
|
Post by Streamstrider on Oct 5, 2011 2:38:32 GMT -8
I was just curious if there was a possible function to have the user PMed when tagged? And if it was possible to add the tag to the subject title (or in another place that would make the tags appear beneath the thread title when viewing it from the list of threads in the board)?
|
|
|
Post by Wormopolis on Oct 5, 2011 23:43:21 GMT -8
it would be possible to change it so it sent a PM insteadof going to the profile. that would be a small change...
I dont understand what you mean by the second part though?
|
|
|
Post by Streamstrider on Oct 6, 2011 0:37:34 GMT -8
It's not quite what I meant for the PMing, I guess. Basically sending a notification to the user who was tagged in the post to let them know they had been tagged. An automatic PM.
The second part. . . . You know how we sometimes put tags in the subject title? I was wondering if something could be made, like an extra section in the form for the tags. The tags could be added to the subject title. However, the subject title might be too long, so I was wondering if it could just be placed below the subject title of the thread (which would show up when the user is viewing the threads int he board).
|
|
|
Post by Wormopolis on Oct 6, 2011 11:13:55 GMT -8
gonna be a sad face on both of those.
automatic PMs are against TOS. Iknow you were going for the "you were tagged in a post" thing, but it just cant be done.
the second part, it would still need to be stored in the thread subject OR in the first few lines of the post itself (like how I do the compatibility icons for codes). but I dont understand what tag you want added? you want to be able to put someone's username into a post and have it ALSO show under the thread title in the thread listing?
|
|
|
Post by Streamstrider on Oct 7, 2011 16:20:07 GMT -8
Just having the user be able to add the tags to a separate field (can be stored in the first few lines) that would have the tagged users appear below the thread title in the thread listing. Doesn't need to link to their profile in the post itself, although having the option might be nice.
|
|
|
Post by Wormopolis on Oct 8, 2011 0:21:05 GMT -8
well it all depends on storage really. in order to pull this off, you need to tap into the "post preview" feature (when you hover over the thread it gives the first 50 characters of the first post)
that being said, you get around 50 characters to store info. lets say 1 user is tagged, it could store their display name (lets say 10 characters), plus if you want it to link the length of their username (another 10). you are looking at only being able to tag 2 MAYBE 3 members.
unless you want to go the route of storing every members username and display name in an array in the code and update it if it changes.
|
|
|
Post by Streamstrider on Oct 9, 2011 0:46:13 GMT -8
Hmm. . . . . *taps chin as she thinks* This is a hard choice. . . . I think I'll pass for now, and if I come up with something, I'll let you know. I seem to be pretty good at bugging you anyway.
|
|
stevevb
Not New Member
Posts: 2
stevevb said 0 great things
|
Post by stevevb on Apr 15, 2012 22:52:09 GMT -8
With the user tag is it possible to put a add tags icon to it like the bold tag ( )?[MÜD:cool]
|
|
|
Post by Wormopolis on Apr 16, 2012 19:03:48 GMT -8
it sure can... you have an idea for the button graphic?
|
|
stevevb
Not New Member
Posts: 2
stevevb said 0 great things
|
Post by stevevb on Apr 17, 2012 4:48:51 GMT -8
it sure can... you have an idea for the button graphic? i just made this one its the same size of the bold button so it can easy blend in.
|
|
|
Post by Wormopolis on Apr 17, 2012 18:21:02 GMT -8
version update 1.2: added in ubbc button, added in ability to add option text for link in case you want to show something other then username as the link [user]admin[/user] would become adminbut [user=Wormo]admin[/user] would become Wormo
|
|