Snitz Forums 2000
Snitz Forums 2000
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 Snitz Forums 2000 MOD-Group
 MOD Add-On Forum (W/Code)
 Mod Extra Star to ForumAdmin
 New Topic  Topic Locked
 Printer Friendly
Author Previous Topic Topic Next Topic  

GauravBhabu
Advanced Member

4288 Posts

Posted - 26 September 2002 :  17:47:36  Show Profile
Mod Extra Star to ForumAdmin
Six Stars to Forum Admin and Five Stars To Other Admins
Author: Rakesh Jain(GauravBhabu)
Compatability: Snitz version 3.4 and up



Implementation:
Requires Modification of code in following files
1. inc_func_member.asp
2. member.asp
3. topic.asp

Step 1
File: inc_func_member.asp
Replace the function getStar_Level (Look between Lines 92-123) in the File inc_func_member.asp with the following.


function getStar_Level(fM_ID, fM_LEVEL, fM_POSTS)
	dim strStarImage, intRank, strStar_Level
	dim intStarCount, strNewRankColor, arrRankLevels, arrRankColors
	strStar_Level = ""
	select case fM_LEVEL
		case "1", "2"
			if (fM_POSTS < cint(intRankLevel1)) then getStar_Level = strStar_Level : exit function
		case "3"
			Rem -Admin, so continue
		case else
			getStar_Level = strStar_Level & "Error"
			exit function
	end select
	arrRankLevels = array(intRankLevel1,intRankLevel2,intRankLevel3,intRankLevel4,intRankLevel5)
	arrRankColors = array(strRankColor1,strRankColor2,strRankColor3,strRankColor4,strRankColor5)
	for intRank = 0 to 3
		if (fM_POSTS < cint(arrRankLevels(intRank + 1))) then exit for
	next
	arrRankLevels = empty 
	select case fM_LEVEL
		case "1"
			strNewRankColor = arrRankColors(intRank)
		case "2"
			strNewRankColor = strRankColorMod
		case "3"
			strNewRankColor = strRankColorAdmin
                        Rem -Five Stars to Admins Always
			intRank = 4
                        Rem -Six Stars to Forum Admin Always
                        if fM_ID = intAdminMemberID then intRank = intRank + 1
	end select
	arrRankColors = empty
	strStarImage = getCurrentIcon("icon_star_" & strNewRankColor & ".gif|13|12","","")
	for intStarCount = 0 to intRank
		strStar_Level =  strStar_Level & strStarImage
	next
	getStar_Level = strStar_Level
	strStarImage = "" :	strStar_Level = ""
	intRank = 0 :	intStarCount = 0
end function


Step 2
File: members.asp

Find these statements around Lines 439-441
if strShowRank = 2 or strShowRank = 3 then 
	Response.Write("<br />" & getStar_Level(Members_MemberLevel, Members_MemberPosts) & "")
end if


Modify/Replace the above statements as below

if strShowRank = 2 or strShowRank = 3 then 
	Response.Write("<br />" & getStar_Level(Members_MemberID, Members_MemberLevel, Members_MemberPosts) & "")
end if



Step 3
File: topic.asp

Find these statements around Lines 579-581
if strShowRank = 2 or strShowRank = 3 then
	Response.Write	"                " & getStar_Level(Reply_MemberLevel, Reply_MemberPosts) & "<br />" & vbNewLine
end if


Modify/Replace the above statements as below
if strShowRank = 2 or strShowRank = 3 then
	Response.Write	"                " & getStar_Level(Reply_MemberID, Reply_MemberLevel, Reply_MemberPosts) & "<br />" & vbNewLine
end if


Step 4
File: topic.asp

Find these statements around Lines 780-782

if strShowRank = 2 or strShowRank = 3 then
	Response.Write	"                " & getStar_Level(Member_Level, Member_Posts) & "<br />" & vbNewLine
end if


Modify/Replace the above statements as below
if strShowRank = 2 or strShowRank = 3 then
	Response.Write	"                " & getStar_Level(TMember_ID, Member_Level, Member_Posts) & "<br />" & vbNewLine
end if


That is all.

CSS and HTML4.01 Compilant Snitz Forum . ForumSquare . Rakesh Jain

It is difficult to IMPROVE on Perfection, There is no harm in Keep Trying.

Prayer Of Forgiveness
"I forgive all living beings. May all living beings forgive me!
I cherish the friendliness towards all and harbour enmity towards none." -- Aavashyaka Sutra(Translated)

Edited by - GauravBhabu on 12 October 2002 07:13:31

PeeWee.Inc
Senior Member

United Kingdom
1893 Posts

Posted - 26 September 2002 :  17:49:15  Show Profile  Visit PeeWee.Inc's Homepage
what would i need to edit on this mod to give the admin one star always?

De Priofundus Calmo Ad Te Damine
Go to Top of Page

GauravBhabu
Advanced Member

4288 Posts

Posted - 26 September 2002 :  17:54:21  Show Profile
quote:
Originally posted by PeeWee.Inc

what would i need to edit on this mod to give the admin one star always?



Do you want one star for admins only or other members also?
Go to Top of Page

PeeWee.Inc
Senior Member

United Kingdom
1893 Posts

Posted - 26 September 2002 :  17:55:48  Show Profile  Visit PeeWee.Inc's Homepage
just the super admin, you know the one, the first admin.

De Priofundus Calmo Ad Te Damine
Go to Top of Page

GauravBhabu
Advanced Member

4288 Posts

Posted - 26 September 2002 :  18:05:21  Show Profile
quote:
Originally posted by PeeWee.Inc

just the super admin, you know the one, the first admin.



Find the following statements in the function get_StarLevel posted in the first post

Rem -Six Stars to Forum Admin Always
if fM_ID = intAdminMemberID then intRank = intRank + 1

Modify as below
Rem -One Star to Forum Admin Always
if fM_ID = intAdminMemberID then intRank = 0


Edited by - GauravBhabu on 26 September 2002 18:06:15
Go to Top of Page

jarod
Starting Member

30 Posts

Posted - 26 September 2002 :  18:52:48  Show Profile
thanks
Go to Top of Page

user_99
Starting Member

Austria
10 Posts

Posted - 12 October 2002 :  13:16:06  Show Profile
thx, works great!
Go to Top of Page

GauravBhabu
Advanced Member

4288 Posts

Posted - 12 October 2002 :  13:24:07  Show Profile
Try this one Mod Stars Setup
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Topic Locked
 Printer Friendly
Jump To:
Snitz Forums 2000 © 2000-2021 Snitz™ Communications Go To Top Of Page
This page was generated in 0.2 seconds. Powered By: Snitz Forums 2000 Version 3.4.07