Latest topics
» bug in update color
by jlmic Today at 12:04

» Dark Theme Help
by Haggis Yesterday at 21:25

» Forumactif Edge - Greek Translation
by Van-Helsing Yesterday at 18:34

» Auto-suggest Plugin execute Javascript
by MiyakeDev Yesterday at 16:42

» Forumactif Edge - Releases
by Ange Tuteur Yesterday at 15:12

» Forumactif Edge - Arabic Translation
by Ange Tuteur Yesterday at 12:48

» Gateway to Role-Play
by JerriLeah7 Sun 26 Mar 2017, 15:40

» [GAME] Count to One Million!
by brandon_g Sun 26 Mar 2017, 11:51

» Happy Birthday Thread
by brandon_g Sun 26 Mar 2017, 11:50

» Forumactif Edge Web Page - Translations
by Ange Tuteur Sat 25 Mar 2017, 18:06

» Quick Reply Bug
by Ange Tuteur Sat 25 Mar 2017, 17:44

» Forumactif Edge - Portuguese Translation (Brazilian)
by Ange Tuteur Sat 25 Mar 2017, 17:40

» Adding text to reputation counter
by Ange Tuteur Thu 23 Mar 2017, 17:19

» Forumactif Edge - Spanish Translation
by Ange Tuteur Thu 23 Mar 2017, 16:24

» How do I add hover examine feature?
by dr.kran Thu 23 Mar 2017, 06:18

Recent Tutorials
Who is online?
In total there are 5 users online :: 0 Registered, 0 Hidden and 5 Guests :: 1 Bot

None

[ View the whole list ]


Most users ever online was 172 on Fri 19 Feb 2016, 05:17

Stylize & Make Rank Titles Link To Groups

View previous topic View next topic Go down

avatar
Ange Tuteur
Administrator
Title :
Coffee Addict
Gender : Male
Age : 21
Posts : 4393
Points : 9049
Reputation : 2189
Location : Macungie, PA
Language : EN10, FR5
Browser : Browser : Brave Forum Version : Forum Version : Forumactif Edge
Awards :
View all awards
View user profile https://github.com/SethClydesdale https://twitter.com/sethc1995

PostAnge Tuteur on Sat 03 Aug 2013, 18:34

Creating the rank title
Firstly you will need to create a new rank(at least for this tutorial if you're a novice)

Go to Administration Panel > Users & Groups > Ranks > Rank Administration > Add new rank

Now write the name of your rank into the rank title, for this tutorial I will be using Administrator. Once you have done that we will now make the title a link by adding:
Code:
<a href="/g1-administrators" class="Administrator" target="_blank">Administrator</a>

The group I am referring to is '/g1-administrators' if no primary url is present href will target local pages, for each group it changes, you can check these urls on the homepage. Our class being used is simple class="Administrator" this will be our hook selector so we can stylize the rank title through CSS. Lastly I am opening these ranks in a new window using target="_blank" you can remove or keep that depending on how you wish the rank link to behave.

Once you have edited the above to your liking be sure to save the rank title.

Stylizing the rank title
Now that we have our rank title and hook selector setup we can start stylizing our rank.

Go to Administration Panel > Display > Pictures and Colors > Colors > CSS Stylesheet

Our selector we will be using is 'a[href="/g1-administrators"].Administrator' read the following for a quick explanation. 'a[href="/g1-administrators"]' will help us stylize the url, it selects every '< a>' element whose href attribute value contains the substring "/g1-administrators". '.Administrator' is our basic selector for stylizing the default text of the rank title. Putting two together will help us in fully customizing the rank title however, this combination will not display properly on outdated browsers.

The setup I am using is the following, you can replace the selectors I have if you're using different ones.
Code:
a[href="/g1-administrators"].Administrator{
color: #C20000;
font-weight:bold;
text-shadow: 0px 0px 6px #C20000;
transition:0.5s;
}
.Administrator:hover{
margin-left:10px;
}

Once you have pasted the code into your stylesheet be sure to hit submit to apply the changes! Afterwards you should now have a stylized rank title that also links to the group of that title. Good luck! Wink

Explanations
For the transition effect we use the pseudo selector ':hover' on our basic selector.(.Administrator) When a user hovers their mouse over the rank the rank will move to the right by 10px; by adding a margin of 10px over 0.5seconds to the left which creates the effect of a moving unit. You can remove the hover and transition effect entirely if you do not prefer such.

Explanation :
color: This will allow you to modify the color of the rank title; you can specify colors using RGB, Hex, or text.
font-weight: This allows you to adjust the weight of the font using numbers or text.(700 is bold and bold is bold)
text-shadow: This allows you to create a text shadow for the text.(Read This for detailed info.)
transition: This specifies the amount of time it takes to complete a hover effect.
margin-left: This is the margin added to the left on a hover, it is specified in pixels(px) you can add different hover effects if you wish. Be sure to modify transition for different speeds.


Tutorial written by Ange Tuteur
avatar
Beyonder
Member
Title :
Gender : Male
Age : 20
Posts : 18
Points : 1104
Reputation : 6
Location : Beyond Realm
Language : English
Browser : Browser : Mozilla Firefox Forum Version : Forum Version : Other
Awards :
View all awards
View user profile http://narutorpguniverse.forumotion.com

PostBeyonder on Sat 25 Jul 2015, 05:33

Does this also work for hidden groups?
and how do i get the same title ranks as yours?
avatar
Michael_vx

Title :
Gender : Male
Age : 25
Posts : 299
Points : 1506
Reputation : 75
Language : Arabic
Browser : Browser : Mozilla Firefox Forum Version : Forum Version : Other
Awards :
View all awards
View user profile http://miccsoft.net https://www.facebook.com/Michaelvx2008

PostMichael_vx on Sat 25 Jul 2015, 11:52

can i see a preview as Example Very Happy
thank you
also please look in my question in the qeustions section thank you

View previous topic View next topic Back to top

Create an account or log in to leave a reply

You need to be a member in order to leave a reply.

Create an account

Join our community by creating a new account. It's easy!


Create a new account

Log in

Already have an account? No problem, log in here.


Log in

 
Permissions in this forum:
You cannot reply to topics in this forum