The Forum has been Updated
The code has been upgraded to the latest .NET core version. Please check instructions in the Community Announcements about migrating your account.
I was thinking of making the names from the admins and moderators in the posts on the left side red and green. After some hours of fiddling around with the following code I can use some help. It looks simple, just not a chance to make it happen.
All of the first posts user names are in red...sins this is the admin (Mlev4) css code color. Can somebody please kick me in the right direction
<
Code:
if lcase(strTopicNoWrapLeft) = "1" then Response.Write(" nowrap")
Response.Write ">" & vbNewLine
if mlev = 4 then
Response.Write " <p><b><span class=""postadminlink"">" & profileLink(ChkString(Member_Name,"display"),TMember_ID) & "</span></b><br />" & VbNewLine
end if
if mlev = 3 then
Response.Write " <p><b><span class=""postmodlink"">" & profileLink(ChkString(Member_Name,"display"),TMember_ID) & "</span></b><br />" & VbNewLine
end if
if mlev = 2 then
Response.Write " <p><b><span class=""postmodlink"">" & profileLink(ChkString(Member_Name,"display"),TMember_ID) & "</span></b><br />" & VbNewLine
end if
if mlev = 1 then
Response.Write " <p><font color=""" & strForumFontColor & """ face=""" & strDefaultFontFace & """ size=""2""><b><span>" & profileLink(ChkString(Member_Name,"display"),TMember_ID) & "</span></b></font><br />" & VbNewLine
end if
if strShowRank = 1 or strShowRank = 3 then
All of the first posts user names are in red...sins this is the admin (Mlev4) css code color. Can somebody please kick me in the right direction
Postet den
In the "active users mod" the moderators and admin have different colors, maybe you can take a look at it?
<
/Tribaliztic
- www.gotlandrace.se -
- www.gotlandrace.se -
Postet den
Bassman,
Your code does look simple and I would expect you to see them in red. Maybe something like this would work:For the replies and this for the 1st post (can not give you the line numbers, but I am sure that you know how to find where).I hope that points you in the right direction.
This is untested, but should work. <
Your code does look simple and I would expect you to see them in red. Maybe something like this would work:
Code:
if Reply_MemberLevel = 4 then
Response.Write " <p><b><span class=""postadminlink"">" & profileLink(ChkString(Member_Name,"display"),TMember_ID) & "</span></b><br />" & VbNewLine
elseif Reply_MemberLevel = 3 then
Response.Write " <p><b><span class=""postmodlink"">" & profileLink(ChkString(Member_Name,"display"),TMember_ID) & "</span></b><br />" & VbNewLine
elsif Reply_MemberLevel = 2 then
Response.Write " <p><b><span class=""postmodlink"">" & profileLink(ChkString(Member_Name,"display"),TMember_ID) & "</span></b><br />" & VbNewLine
elseif Reply_MemberLevel = 1 then
Response.Write " <p><font color=""" & strForumFontColor & """ face=""" & strDefaultFontFace & """ size=""2""><b><span>" & profileLink(ChkString(Member_Name,"display"),TMember_ID) & "</span></b></font><br />" & VbNewLine
end ifCode:
if Member_Level = 4 then
Response.Write " <p><b><span class=""postadminlink"">" & profileLink(ChkString(Member_Name,"display"),TMember_ID) & "</span></b><br />" & VbNewLine
elsif Member_Level = 3 then
Response.Write " <p><b><span class=""postmodlink"">" & profileLink(ChkString(Member_Name,"display"),TMember_ID) & "</span></b><br />" & VbNewLine
elseif Member_Level = 2 then
Response.Write " <p><b><span class=""postmodlink"">" & profileLink(ChkString(Member_Name,"display"),TMember_ID) & "</span></b><br />" & VbNewLine
elseif Member_Level = 1 then
Response.Write " <p><font color=""" & strForumFontColor & """ face=""" & strDefaultFontFace & """ size=""2""><b><span>" & profileLink(ChkString(Member_Name,"display"),TMember_ID) & "</span></b></font><br />" & VbNewLine
end ifThis is untested, but should work. <
Cheers,
David Greening
David Greening
Postet den
Indeed the red part was the problem, thanks Classicmotorcycling that code works great
It was the Reply_MemberLevel not just mlev
here the final version:
around line 750
Around line 1040
Edit: delete line Reply_MemberLevel = 4, thanks Shaggy<
here the final version:
around line 750
Code:
if Reply_MemberLevel = 3 then
Response.Write " <p><b><span class=""postadminlink"">" & profileLink(ChkString(Reply_MemberName,"display"),Reply_Author) & "</span></b><br />" & VbNewLine
elseif Reply_MemberLevel = 2 then
Response.Write " <p><b><span class=""postmodlink"">" & profileLink(ChkString(Reply_MemberName,"display"),Reply_Author) & "</span></b><br />" & VbNewLine
elseif Reply_MemberLevel = 1 then
Response.Write " <p><font color=""" & strForumFontColor & """ face=""" & strDefaultFontFace & """ size=""2""><b><span>" & profileLink(ChkString(Reply_MemberName,"display"),Reply_Author) & "</span></b></font><br />" & VbNewLine
end if
Around line 1040
Code:
if Member_Level = 3 then
Response.Write " <p><b><span class=""postadminlink"">" & profileLink(ChkString(Member_Name,"display"),TMember_ID) & "</span></b><br />" & VbNewLine
elseif Member_Level = 2 then
Response.Write " <p><b><span class=""postmodlink"">" & profileLink(ChkString(Member_Name,"display"),TMember_ID) & "</span></b><br />" & VbNewLine
elseif Member_Level = 1 then
Response.Write " <p><font color=""" & strForumFontColor & """ face=""" & strDefaultFontFace & """ size=""2""><b><span>" & profileLink(ChkString(Member_Name,"display"),TMember_ID) & "</span></b></font><br />" & VbNewLine
end ifEdit: delete line Reply_MemberLevel = 4, thanks Shaggy<
Sist redigert av
Postet den
No problems, glad I could help and point you in the right direction... Forgot to change the other items, but was in a hurry at 5:30am (Melbourne, Australia time) this morning before work to point you there...<
Cheers,
David Greening
David Greening
Postet den
I found them David, the direction was great
<
Postet den
You can remove the first if statment from both those snippets David provided - M_LEVEL will only ever be between 1 & 3, never 4.
<
Search is your friend
“I was having a mildly paranoid day, mostly due to the
fact that the mad priest lady from over the river had
taken to nailing weasels to my front door again.”
<
Search is your friend
“I was having a mildly paranoid day, mostly due to thefact that the mad priest lady from over the river had
taken to nailing weasels to my front door again.”
Postet den
Woops...thanks Shaggy<
Email Member
Message Member
Post Moderation
Filopplasting
If you're having problems uploading, try choosing a smaller image.
Forhåndsvis post
Send Topic
Loading...