vForums Support :: Programming & Coding :: Code Requests & Support :: [F] Staff have normal rank mod - View Topic
 |  |
| This topic was locked 22nd Apr 08 at 6:42am by Michael | dog199200 Guest | [F] Staff have normal rank mod (21st Apr 08 at 2:05am UTC) Resolved | | can i get a mod fo this code so that i will only show the rank image not the rank name?
 Code: - <script type="text/javascript">
- <!--
- var ranks = Array(); var r=0;
-
- ranks[r++] = Array(0, 'Freshie', 1, 'http://i25.photobucket.com/albums/c51/dog199200/Digimon/fresh.png');
- ranks[r++] = Array(50, 'In-Training', 1, 'http://i25.photobucket.com/albums/c51/dog199200/Digimon/training.png');
- ranks[r++] = Array(100, 'Rookie', 1, 'http://i25.photobucket.com/albums/c51/dog199200/Digimon/rookie.png');
- ranks[r++] = Array(200, 'Champion', 1, 'http://i25.photobucket.com/albums/c51/dog199200/Digimon/champion.png');
- ranks[r++] = Array(500, 'Ultimate', 1, 'http://i25.photobucket.com/albums/c51/dog199200/Digimon/Ultimate.png');
- ranks[r++] = Array(1000, 'Mega', 1, 'http://i25.photobucket.com/albums/c51/dog199200/Digimon/Mega.png');
- ranks[r++] = Array(2500, 'Bio-Merge', 1, 'http://i25.photobucket.com/albums/c51/dog199200/Digimon/Bio-Merge.png');
- ranks[r++] = Array(5000, 'Sublime', 1, 'http://i25.photobucket.com/albums/c51/dog199200/Digimon/Sublime.png');
-
- function assign_rank(display_name, posts) {
- if(!display_name.match(/group(0|$)/i)) {
- posts = parseInt(posts.replace(/,/g, ''));
- r = 0;
- while(ranks[r] && ranks[r][0] < posts) {
- r++;
- }
- if(r > 0)
- r--;
- var rank_str = "<tr><td class=\"window1\" align=\"center\">" + ranks[r][1] + "<br />";
- for(c=0; c<ranks[r][2]; c++) {
- rank_str += "<img src=\""+ ranks[r][3] +"\" alt=\"*\" /></tr></td>";
- }
- document.write(rank_str);
- }
- }
- //-->
- </script>
| |
| Michael Moderator
    
![[Avatar]](http://av.wservices.co.uk/av.png) Recoding the future Posts: 4,043 Status: Offline Gender: Male Location: UK Joined:
Additional Groups: Coding Team
  
pmvForum | Re: Staff have normal rank mod (21st Apr 08 at 9:47pm UTC) | | remove:
+ ranks[r][1] + "<br />" | |
| dog199200 Guest | Re: Staff have normal rank mod (22nd Apr 08 at 1:19am UTC) | | ok that works try | |
| |
 |  |
|