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.

Staff Posting Color

View previous topic View next topic Go down

Solved Staff Posting Color

Post by FrOsTyXi on April 28th 2015, 6:08 am

@Ange Tuteur Hello I noticed there is a color on the bottom left of staff posts can I do this on my forum?
Maybe there is a topic.

Image:


Regards
FrOstyXi

FrOsTyXi
Forumember

Male Posts : 460
Reputation : 12
Language : english

http://team-psn.forum-board.net/

Back to top Go down

Solved Re: Staff Posting Color

Post by SLGray on April 28th 2015, 7:28 am



When your topic has been solved, ensure you mark the topic solved.
Never post your email in public.


SLGray
Administrator
Administrator

Male Posts : 36697
Reputation : 2445
Language : English
Location : United States

http://ztwds.forumotion.com/

Back to top Go down

Solved Re: Staff Posting Color

Post by Ange Tuteur on April 28th 2015, 9:28 am

Add a tag to your rank title with a specific class, frosty, for example.
( Users and groups > Rank administration > create or edit your rank )

Include an html tag with your personal classname. Ex :
Code:
<span class="frosty"></span>

Make sure to set it as a special rank, and assign it to yourself by editing your profil in the AP. Next go to Modules > JS codes management > create a new script

Placement : In the topics
Code:
$(function() {
  // find tags with the class frosty, then apply our bg class to the message body
  $('.frosty').closest('.post').addClass('frosty-bg');
});

After this we can define a style in Display > Colors > CSS stylesheet
Code:
.post.frosty-bg {
  background:red;
}

You can target anything in your posts by using your special class ( .frosty-bg )

Ange Tuteur
Forumaster

Male Posts : 13028
Reputation : 2704
Language : EN10, FR5
Location : Pennsylvania

http://fmdesign.forumotion.com

Back to top Go down

Solved Re: Staff Posting Color

Post by developer.ryan on April 28th 2015, 12:39 pm

The correct way:
Put this code in JavaScript
Select all pages
Or threads
This is the code I
Code:
FA.Ready(function() {
  for (var a = $('.postprofile', document.getElementById('main-content')), b, c, i = 0, j = a.length; i < j; i++) {
    b = a[i].innerHTML;
    if (/class="st-rang.*?"/.test(b)) {
      b = b.replace(/\n/gm, '').replace(/.*class="st-rang\s(.*?)".*/, '$1');
      c = a[i].parentNode.parentNode;
      c.className += ' st-answer';
      switch (b) {
        case 'bguser':
          c.className += ' bguser';
          break;       
      }
    }
  }
}, 'right');

This place it in css
Code:
.post.st-answer {
    background-image:url(place here is a picture to insert);
    background-position:0 100%;
    background-repeat:no-repeat;
    background-size:100%
}
.post.st-answer.bguser {
    background-image:url(place here is a picture to insert)
}
and went to Users & Groups = Ranks = Rank Administration = modify level
Put this
Code:
<strong class="st-rang bguser">put here the name of the rank</strong>
you can put them to a specific group or a specific member by class or group name

place the image sizes
Like this image sizes
https://i19.servimg.com/u/f19/19/17/81/75/admin110.png
You can design the gradient on this picture I do not know how to write the gradient

developer.ryan
Forumember

Posts : 98
Reputation : 6
Language : English,Chinese,Italian,French
Location : The doors of development

http://javascript:self.close()

Back to top Go down

Solved Re: Staff Posting Color

Post by FrOsTyXi on April 28th 2015, 12:51 pm

Thank you!! solved

FrOsTyXi
Forumember

Male Posts : 460
Reputation : 12
Language : english

http://team-psn.forum-board.net/

Back to top Go down

Solved Re: Staff Posting Color

Post by SLGray on April 28th 2015, 8:29 pm

Topic solved and archived


When your topic has been solved, ensure you mark the topic solved.
Never post your email in public.


SLGray
Administrator
Administrator

Male Posts : 36697
Reputation : 2445
Language : English
Location : United States

http://ztwds.forumotion.com/

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