Forum Link: http://venthub.forumotion.com/
Forum Version: PunBB
Screenshot of what it looks like: https://gyazo.com/7c2b9ab637a732c848a9a19d07c3a496
Similar screenshot of what it should look like: https://gyazo.com/74b36575a7198611233294879c5a1367
Hello,
I needed help fixing the staff background on my forum, VentHub. I would just like it on the right side in the posts. I will provide the codes below. @Ange Tuteur
Forum Version: PunBB
Screenshot of what it looks like: https://gyazo.com/7c2b9ab637a732c848a9a19d07c3a496
Similar screenshot of what it should look like: https://gyazo.com/74b36575a7198611233294879c5a1367
Hello,
I needed help fixing the staff background on my forum, VentHub. I would just like it on the right side in the posts. I will provide the codes below. @Ange Tuteur
- Javascript:
- Code:
function parseGroupPosts() {
var groups = [
'admin', /* administrator */
'nrman', /* n r manager */
'bot', /* bot */
'sctr', /* social controller */
'hmem', /* honorary members */
'trep', /* trial reporter */
'tmod', /* trial moderator */
'gad', /* general administrator */
'nrep', /* news reporter */
'smod', /* super moderator */
'mod', /* moderator */
'mem' /* members */
],
profil = $('.post:not(.st-answer) .postprofile'),
html,
post,
i = 0,
j = profil.length,
k,
l = groups.length;
for (; i < j; i++) {
html = profil[i].innerHTML.replace(/\n/gm,'');
if (/class="st-rang.*?"/.test(html)) {
html = html.replace(/.*class="st-rang\s(.*?)".*/, '$1').replace(/\s/g, '');
post = profil[i].parentNode.parentNode;
post.className += ' st-answer';
for (k = 0; k < l; k++) {
if (html == groups[k]) {
post.className += ' ' + groups[k];
break;
}
}
}
}
};
$(parseGroupPosts);
- CSS:
- Code:
.post.st-answer.admin{border-right:5px solid #ff0000!important;}
.post.st-answer.nrman{border-right:5px solid #de0059!important;}
.post.st-answer.bot{border-right:5px solid #0AC92B!important;}
.post.st-answer.sctr{border-right:5px solid #079400!important;}
.post.st-answer.hmem{border-right:5px solid #ad8e29!important;}
.post.st-answer.trep{border-right:5px solid #a82871!important;}
.post.st-answer.tmod{border-right:5px solid #722d9c!important;}
.post.st-answer.gad{border-right:5px solid #000000!important;}
.post.st-answer.nrep{border-right:5px solid #de0059!important;}
.post.st-answer.smod{border-right:5px solid #0022ff!important;}
.post.st-answer.mod{border-right:5px solid #7f00e6!important;}
.post.st-answer.mem{border-right:5px solid #509bd9!important;}