Jump to content
WebFlake

Ribbon In Topic View For Special Groups.


GradientWizzard

Recommended Posts

Hello,

So for add a ribbon on your topic view for a special group without a plugin just follow this tutorial (tested on 3.2.3, 3.3.X):

Posted Image

1) Log into your Admin CP
2) Click on "Look and Feel" > "Manage Template Sets"
3) Click on the name of the template set you wish to edit
4) In the left hand menu, select 'Topic Views' under 'post'
5) In the HTML code, scroll down until you see the following code :
 

<div class='post entry-content <if test="$post['post']['_repignored'] == 1">imgsize_ignore</if>'>	 {$post['post']['post']}	 {$post['post']['attachmentHtml']}

Add this code ABOVE the previous HTML code (maybe need adapte the position of the code depends the skin)
 

<if test="in_array($post['author']['member_group_id'], array(4,6,7,11,10) )"><img src="http://chost.us/public/style_images/imgfc/staff5.png" class="staffpost"></if>

Adapte the number for the groud ID like you want.
Change the name of images if you uploaded image is not named "staff5.png"

Now go in your CSS
1) Open ipb_styles.css
2) Scroll at the end and add this code :
 

.staffpost {top: -27px;right: -20px;z-index: 1000;float: right;position: relative;}

Adapte the css for you skin with the top and right variable.
A important step is to upload your image on your "style_image_name" folder.

For guys who want to have differents ribbon for moderators and admins (for exemple) just duplicate the code and change the name of image + group ID

<if test="in_array($post['author']['member_group_id'], array(7,11) )"><img src="http://xxx.us/public/style_images/imgfc/staff5.png" class="staffpost"></if><if test="in_array($post['author']['member_group_id'], array(4,10) )"><img src="http://xxx.us/public/style_images/imgfc/staff6.png" class="staffpost"></if>

Tutorial by Skye

  • Upvote 1

Achievements:

February 14 2013 - Joined WebFlake & Became Moderator.
March 26 2013 - Became a Dad of 1 kid.
April 8 2015 - Became a Dad of 2 kids.
July 15 2015 - Retired as a Moderator.
November 11 2016 - Passed my Car Driving Licence.
April 13 2017 - Became apart of the Junior Moderator Team.

Link to comment
Share on other sites

Guest Jerison

I don't think this works for 3.4.x. Because I looked up and down it for like 10 mins and I couldn't find <div class='post entry-content <if test="$post['post']['_repignored'] == 1">imgsize_ignore</if>'> {$post['post']['post']} {$post['post']['attachmentHtml']}

Link to comment
Share on other sites

Guest Jerison

Original post by me, you can add me in the credits, thanks.. :)

Can you help me do it on TV or join.me?

Link to comment
Share on other sites

  • 4 weeks later...
On 4/2/2013 at 11:39 PM, Davlin said:

Your profile lists your forum version as 3.4.x -- this tutorial explicitly states that it's only been tested on 3.2.x and 3.3.x. 

oh yeah didn't see that.. my bad!

 

 

is there any way to do this on 3.4.x ??

Link to comment
Share on other sites

  • Administrator

You're likely better off using [HQ] Badges 2.0.1 for 3.4.x. It offers the same ability to add special "badges" to the topic view for specified groups, and has a wider range of options.

 

  • Upvote 1
Link to comment
Share on other sites

On 4/3/2013 at 12:02 AM, Davlin said:

You're likely better off using [HQ] Badges 2.0.1 for 3.4.x. It offers the same ability to add special "badges" to the topic view for specified groups, and has a wider range of options.

 

?do=embed' frameborder='0' data-embedContent>

Thank you! it's really helpful :)

On 4/3/2013 at 12:02 AM, Davlin said:

You're likely better off using [HQ] Badges 2.0.1 for 3.4.x. It offers the same ability to add special "badges" to the topic view for specified groups, and has a wider range of options.

 

?do=embed' frameborder='0' data-embedContent>

did you know how to put these awards just for one special member?

  • Upvote 1
Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...