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.

Background based on user's group

View previous topic View next topic Go down

Solved Background based on user's group

Post by SarkZKalie on January 23rd 2015, 7:54 pm

Technical Details

Forum version : PunBB
Position : Founder
Concerned browser(s) : Mozilla Firefox, Google Chrome, Opera
Who the problem concerns : All members
Forum link : http://rotavn.nstars.org/t5-request-blog-testing

Description of problem

Hello

I've activated Blog feature for my web page. After applied some change on CSS, overall everything is okay, except one thing
Code:
<div class="dhighlight banner">
<div id="dh_img_blog"><a href="">{postrow.displayed.POSTER_AVATAR}</a></div><br/><br/>
<h4><p>{postrow.displayed.POSTER_NAME}</p><br /><br />{postrow.displayed.POSTER_RANK_NEW}
</h4>
<br class="clfloat"/>
</div>
Everyone can post a blog type thread and it will be great if user info can show in a banner at the end of their post (first post only).
For example:
If user #1 (normal member) opens a blog type thread, the banner will show like this image below
But with #2 (group A), #3 (group B) and #4 (group C)...etc. The banner will change the background based on group that they belong.
And I'm thinking about give them a style by CSS, but actually it's not feasable. A script works in blog only, harder what I know.

Is it possible? If you can, enlighten or suggest me some ideas.Twisted Evil
Thanks for reading!


Last edited by sarkzkalie01 on January 25th 2015, 8:33 am; edited 1 time in total

SarkZKalie
Forumember

Male Posts : 419
Reputation : 73
Language : English

http://rotavn.nstars.org/

Back to top Go down

Solved Re: Background based on user's group

Post by SarkZKalie on January 24th 2015, 6:43 pm

Bumpcyclops

SarkZKalie
Forumember

Male Posts : 419
Reputation : 73
Language : English

http://rotavn.nstars.org/

Back to top Go down

Solved Re: Background based on user's group

Post by Ange Tuteur on January 24th 2015, 7:01 pm

@sarkzkalie01, you're changing the poster background image based on group membership correct ? If that's the case, I wrote a small script for doing so, which you can find here : http://fmdesign.forumotion.com/t230-add-a-classname-to-group-member-posts along with an explanation.

I'm not sure if it'll work on blog comments, but if it doesn't let me know.

Ange Tuteur
Forumaster

Male Posts : 13021
Reputation : 2683
Language : EN10, FR5
Location : Pennsylvania

http://fmdesign.forumotion.com

Back to top Go down

Solved Re: Background based on user's group

Post by SarkZKalie on January 25th 2015, 8:30 am

@Ange Tuteur Yeah, thanks you Katty!
I've added this script to my viewcomment_body template, so it works perfect in blog.Twisted Evil

SarkZKalie
Forumember

Male Posts : 419
Reputation : 73
Language : English

http://rotavn.nstars.org/

Back to top Go down

Solved Re: Background based on user's group

Post by SLGray on January 25th 2015, 6:15 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 : 35629
Reputation : 2372
Language : English
Location : United States

http://fmthemes.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