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 Five Stars To Admins Always
 New Topic  Topic Locked
 Printer Friendly
Next Page
Author Previous Topic Topic Next Topic
Page: of 2

GauravBhabu
Advanced Member

4288 Posts

Posted - 03 September 2002 :  08:14:40  Show Profile
Mod Five Stars To Admins Always
Author: Rakesh Jain(GauravBhabu)
Compatability: Snitz version 3.4 and up

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



function getStar_Level(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
	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



Mod Five Stars To Admins and Moderators Always
Author: Rakesh Jain(GauravBhabu)
Compatability: Snitz version 3.4 and up

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



function getStar_Level(fM_LEVEL, fM_POSTS)
	dim strStarImage, intRank, strStar_Level
	dim intStarCount, strNewRankColor, arrRankLevels, arrRankColors
	strStar_Level = ""
	select case fM_LEVEL
		case "1"
			if (fM_POSTS < cint(intRankLevel1)) then getStar_Level = strStar_Level : exit function
		case "2", "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
                        Rem -Five Stars to Moderators Always
			intRank = 4
		case "3"
			strNewRankColor = strRankColorAdmin
                        Rem -Five Stars to Admins Always
			intRank = 4
	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

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 06 September 2002 15:27:59

ErEf
New Member

Netherlands
74 Posts

Posted - 03 September 2002 :  10:49:44  Show Profile  Visit ErEf's Homepage
after replacing the function default.asp returns with this error.
Error Type:
Microsoft VBScript compilation (0x800A03EE)
Expected ')'
/forum/inc_func_member.asp, line 98, column 16
if (fM_POSTS < cint(intRankLevel1)) then getStar_Level = strStar_Level : exit function

well found it out myself .. went something wrong with copy past. Works fine now.

Can it also be changed that also moderators have 5 stars?


If you think you can or you think you cannot, you are right. - Henry Ford

Edited by - ErEf on 03 September 2002 11:08:07
Go to Top of Page

drirene
Junior Member

USA
129 Posts

Posted - 04 September 2002 :  00:37:40  Show Profile  Visit drirene's Homepage
I found a much easier way to give mods and admins five stars: In 3.4.2 when you edit their profiles, you can change the number of posts they've made. Kick it up over 5000, and - BAM - five stars!

*Trubble* the Cat & Dr. Irene
http://drirene.com
Go to Top of Page

Kat
Advanced Member

United Kingdom
3065 Posts

Posted - 04 September 2002 :  05:09:57  Show Profile  Visit Kat's Homepage
Yeah but that isn't a proper fix. it isn't representative of the real posts. I wouldn't advise you do that.

KatsKorner

Installation Help | Snitz Mods | Forum Hosting
Go to Top of Page

alex042
Average Member

USA
631 Posts

Posted - 04 September 2002 :  08:02:26  Show Profile  Send alex042 an AOL message  Send alex042 a Yahoo! Message
quote:
Yeah but that isn't a proper fix. it isn't representative of the real posts. I wouldn't advise you do that.


People do it with checkbooks.

Go to Top of Page

Kat
Advanced Member

United Kingdom
3065 Posts

Posted - 04 September 2002 :  08:06:15  Show Profile  Visit Kat's Homepage
Pardon?

KatsKorner

Installation Help | Snitz Mods | Forum Hosting

Edited by - Kat on 04 September 2002 08:06:29
Go to Top of Page

alex042
Average Member

USA
631 Posts

Posted - 04 September 2002 :  08:28:39  Show Profile  Send alex042 an AOL message  Send alex042 a Yahoo! Message
quote:
Pardon?


Some companies wouldn't take checks from 'new' accounts. The account was assumed to be 'new' if the checks numbers were low, say less than 1000 so some people start their checkbook numbering sequence at 1001 instead of 101. That's what I ended up doing because I didn't want to deal with the hassle of companies not taking my check just because of the check number.

Go to Top of Page

Kat
Advanced Member

United Kingdom
3065 Posts

Posted - 04 September 2002 :  08:41:14  Show Profile  Visit Kat's Homepage
never heard of that with cheques in the UK.

KatsKorner

Installation Help | Snitz Mods | Forum Hosting
Go to Top of Page

GauravBhabu
Advanced Member

4288 Posts

Posted - 04 September 2002 :  08:50:54  Show Profile
Checks/Cheques? Discuss stars or the Mod please.
Go to Top of Page

Kat
Advanced Member

United Kingdom
3065 Posts

Posted - 04 September 2002 :  08:53:39  Show Profile  Visit Kat's Homepage
yeah i was just thinking that! sorry gaurav!

KatsKorner

Installation Help | Snitz Mods | Forum Hosting
Go to Top of Page

Lydecker
Junior Member

United Kingdom
297 Posts

Posted - 06 September 2002 :  14:50:25  Show Profile  Visit Lydecker's Homepage
I have to say I had ZERO faith in this MOD working when I looked at the amount of code I would be deleting, but it seems to work Great :) :) :)

How can we do the same with Moderators??

THanks for the MOD!!
Go to Top of Page

Lydecker
Junior Member

United Kingdom
297 Posts

Posted - 06 September 2002 :  14:54:52  Show Profile  Visit Lydecker's Homepage
Okay I took a stab - is this correct or will the site blow up in a day? Thanks



case "1"
strNewRankColor = arrRankColors(intRank)
case "2"
strNewRankColor = strRankColorMod
Rem -Five Stars to Mods Always
intRank = 4

case "3"
strNewRankColor = strRankColorAdmin
Rem -Five Stars to Admins Always
intRank = 4
Go to Top of Page

GauravBhabu
Advanced Member

4288 Posts

Posted - 06 September 2002 :  15:09:14  Show Profile
quote:
Originally posted by Lydecker

Okay I took a stab - is this correct or will the site blow up in a day? Thanks



case "1"
strNewRankColor = arrRankColors(intRank)
case "2"
strNewRankColor = strRankColorMod
Rem -Five Stars to Mods Always
intRank = 4

case "3"
strNewRankColor = strRankColorAdmin
Rem -Five Stars to Admins Always
intRank = 4





Need to change as shown below as well

	
select case fM_LEVEL
	case "1"
		if (fM_POSTS < cint(intRankLevel1)) then getStar_Level = strStar_Level : exit function
	case "2", "3"
		Rem -Admin, Moderator so continue
	case else
		getStar_Level = strStar_Level & "Error"
		exit function
end select


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)
Go to Top of Page

Lydecker
Junior Member

United Kingdom
297 Posts

Posted - 06 September 2002 :  15:16:50  Show Profile  Visit Lydecker's Homepage
Dosent work. I returns all stars as:
icon_star_.gif

The way I had it did work for MODS (but there was probibly something wrong) - but the code you just gave dosent show any stars :(

Any ideas??

Many thanks for the help.
Go to Top of Page

GauravBhabu
Advanced Member

4288 Posts

Posted - 06 September 2002 :  15:25:29  Show Profile
The change I mentioned is for the first part of the select case statements (5th and 7th statements within the function). The change you made also remains but that is for the second part.
Go to Top of Page

GauravBhabu
Advanced Member

4288 Posts

Posted - 06 September 2002 :  15:29:28  Show Profile
I also posted the code to give Five stars to both Admins and Moderators in my first post
Go to Top of Page
Page: of 2 Previous Topic Topic Next Topic  
Next Page
 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.26 seconds. Powered By: Snitz Forums 2000 Version 3.4.07