Change the background in function of the rank
3 posters
Page 1 of 1
Change the background in function of the rank
Technical Details
Forum version : #phpBB3Position : Founder
Concerned browser(s) : Mozilla Firefox
Screenshot of problem : https://i.servimg.com/u/f18/14/92/41/94/scher570.png
Who the problem concerns : Yourself
Description of problem
Can you help me? I want to change the background in function of the rankI read this tutorial: https://help.forumotion.com/t115828-
How i can do?
Guest- Guest
Re: Change the background in function of the rank
That tutorial is based on gender, not rank. Are you wanting to change the color of the background?
Lost Founder's Password |Forum's Utilities |Report a Forum |General Rules |FAQ |Tricks & Tips
You need one post to send a PM.
You need one post to send a PM.
When your topic has been solved, ensure you mark the topic solved.
Never post your email in public.
Re: Change the background in function of the rank
Hi yes i know, i want to use that tutorial for rank... Can i make and exemple?
I write this code:
And i put this in CSS:
Are the code correct?
I write this code:
- Code:
$(function() {
var version = "phpBB3";
if(version.toLowerCase() == "phpbb3"){
$(".postprofile img[title='BOT']").closest('.post').prev('.post').addClass("fa_BOT");
$(".postprofile img[title='Admin']").closest('.post').prev('.post').addClass("fa_ADMIN");
}
});
And i put this in CSS:
- Code:
.fa_BOT {
background-color: black;
}
Are the code correct?
Guest- Guest
Re: Change the background in function of the rank
You want to create a background image based on rank... Correct?
-Brandon
-Brandon
Remember to mark your topic when a solution is found.
General Rules | Tips & Tricks | FAQ | Forgot Founder Password?
Team Leader
Review Section Rules | Request A Review | Sticker Points
Re: Change the background in function of the rank
The simplest method to understand and use would be this one :
In the rank title you should have an element with a class. For example an empty <i> tag with the class "rang."
Then as you can see in the script, we Query ".rang" and add our class "specialPost" to ".post." After this, all you need to do is add some CSS to your stylesheet.
In short; just change "rang" and "specialPost" to fit that of what you wish.
- Code:
$(function() {
$('.rang').closest('.post').addClass('specialPost');
});
In the rank title you should have an element with a class. For example an empty <i> tag with the class "rang."
- Code:
<i class="rang"></i>
Then as you can see in the script, we Query ".rang" and add our class "specialPost" to ".post." After this, all you need to do is add some CSS to your stylesheet.
- Code:
.specialPost {
background:red;
}
In short; just change "rang" and "specialPost" to fit that of what you wish.
Re: Change the background in function of the rank
You are fantastic, thanks very much
It works very good! I mark solved
It works very good! I mark solved
Guest- Guest
Re: Change the background in function of the rank
Topic solved and archived
Lost Founder's Password |Forum's Utilities |Report a Forum |General Rules |FAQ |Tricks & Tips
You need one post to send a PM.
You need one post to send a PM.
When your topic has been solved, ensure you mark the topic solved.
Never post your email in public.
Similar topics
» Hai i need this rank sets dont change size colour and rank name words..and put please stylish names
» Rank Background
» Background help and rank help.
» [background color update]-I want the code to change the background color
» How to change the background of this....
» Rank Background
» Background help and rank help.
» [background color update]-I want the code to change the background color
» How to change the background of this....
Page 1 of 1
Permissions in this forum:
You cannot reply to topics in this forum