Author |
Topic  |
|
Flynn Arrowstarr
Starting Member
16 Posts |
Posted - 03 April 2002 : 19:38:39
|
Quick question: is there a way to set up the Members list so that only the Admins and Mods can see it? I'm assuming it should be something simple, but my knowledge of .asp coding couldn't fill a thimble... Thanks.
Flynn
In this rat race known as life, the smart money is always on the rats. |
|
ruirib
Snitz Forums Admin
    
Portugal
26364 Posts |
Posted - 03 April 2002 : 19:57:01
|
An easy way do to this would be to add a line like this:
if mlev <3 Then Response.Redirect "default.asp"
You can add it after the Dim instructions, around line 59.
If a non mod or non admin user tries to get to it it will be redirected to default.asp.
You can also modify inc_top.asp, in order to have the members link not shown to non mods and non Admins. If you want that let me know...
------------------------------------------------- Installation Guide | Do's and Dont's | MODs |
 |
|
Flynn Arrowstarr
Starting Member
16 Posts |
Posted - 03 April 2002 : 20:02:50
|
quote:
You can also modify inc_top.asp, in order to have the members link not shown to non mods and non Admins. If you want that let me know... ruirib
Yes. Please 
Flynn
In this rat race known as life, the smart money is always on the rats. |
 |
|
ruirib
Snitz Forums Admin
    
Portugal
26364 Posts |
Posted - 03 April 2002 : 20:05:08
|
To stop the members link to bo shown to non Mods and non Admins, change these lines (starting around line 366 in inc_top.asp)
Response.Write " |" & vbNewline & _ " <a href=""members.asp""><acronym title=""Current members of these forums..."">Members</acronym></a>" & vbNewline & _ " |" & vbNewline & _ " <a href=""search.asp""><acronym title=""Perform a search by keyword, date, and/or name..."">Search</acronym></a>" & vbNewline & _ " |" & vbNewline & _ " <a href=""faq.asp""><acronym title=""Answers to Frequently Asked Questions..."">FAQ</acronym></a>" & vbNewline
to this:
Response.Write " |" & vbNewline If mlev >= 3 Then Response.Write "<a href=""members.asp""><acronym title=""Current members of these forums..."">Members</acronym></a>" & vbNewline & _ " |" & vbNewline End If
Response.Write "<a href=""search.asp""><acronym title=""Perform a search by keyword, date, and/or name..."">Search</acronym></a>" & vbNewline & _ " |" & vbNewline & _ " <a href=""faq.asp""><acronym title=""Answers to Frequently Asked Questions..."">FAQ</acronym></a>" & vbNewline
------------------------------------------------- Installation Guide | Do's and Dont's | MODs |
 |
|
Flynn Arrowstarr
Starting Member
16 Posts |
Posted - 03 April 2002 : 20:10:14
|
Thanks again! 
Flynn
In this rat race known as life, the smart money is always on the rats. |
 |
|
ruirib
Snitz Forums Admin
    
Portugal
26364 Posts |
|
CtryLuv
Starting Member
13 Posts |
Posted - 04 May 2002 : 23:23:39
|
Hi, I am trying to do the same thing, and have gotten the member link so it doesnt show up. I would also like to do what you said in your first post, but I am completely new to this. Which asp would I add the line into, and how do I know where the dim instructions end? Im very new to this, sorry for the trouble and thanks!
|
 |
|
ruirib
Snitz Forums Admin
    
Portugal
26364 Posts |
Posted - 05 May 2002 : 05:21:15
|
quote:
Hi, I am trying to do the same thing, and have gotten the member link so it doesnt show up. I would also like to do what you said in your first post, but I am completely new to this. Which asp would I add the line into, and how do I know where the dim instructions end? Im very new to this, sorry for the trouble and thanks!
Do it in members.asp. Just add it in a new line after the last line that started with Dim. It should be around line 59.
------------------------------------------------- Installation Guide | Do's and Dont's | MODs
Edited by - ruirib on 05 May 2002 05:22:27 |
 |
|
CtryLuv
Starting Member
13 Posts |
Posted - 05 May 2002 : 10:45:22
|
ok great!! Thanks so much!!
|
 |
|
ruirib
Snitz Forums Admin
    
Portugal
26364 Posts |
|
Cycas
Starting Member
United Kingdom
14 Posts |
Posted - 06 May 2002 : 19:10:58
|
Do these edits make the User Profile link in the Author column non functuioning too?
If not then, please, how could I do that?
Phil
|
 |
|
ruirib
Snitz Forums Admin
    
Portugal
26364 Posts |
Posted - 06 May 2002 : 19:24:19
|
quote:
Do these edits make the User Profile link in the Author column non functuioning too?
No they don't. That takes a bit more work.
quote:
If not then, please, how could I do that?
That will mean changing forum.asp, topic.asp and active.asp, at least. I'll have a look and let you know about it.
------------------------------------------------- Installation Guide | Do's and Dont's | MODs |
 |
|
ruirib
Snitz Forums Admin
    
Portugal
26364 Posts |
Posted - 06 May 2002 : 20:08:44
|
As I told you this one gives a bit more work:
1. In forum.asp:
Around line 380, comment the lines in green by adding a ' at their beginning, and add the line in red:
strLastAuthor = "<br>by: " ' if strUseExtendedProfile then ' strLastAuthor = strLastAuthor & "<a href=""pop_profile.asp?mode=display&id="& ChkString(rs("T_LAST_POST_AUTHOR"), "JSurlpath") & """>" 'else 'strLastAuthor = strLastAuthor & "<a href=""JavaScript:openWindow2('pop_profile.asp?mode=display&id=" & ChkString(rs("T_LAST_POST_AUTHOR"), "JSurlpath") & "')"">" 'end if 'strLastAuthor = strLastAuthor & ChkString(rs("LAST_POST_AUTHOR_NAME"), "display") & "</a>" strLastAuthor = strLastAuthor & " " & ChkString(rs("LAST_POST_AUTHOR_NAME"), "display")
2. In active.asp, do the same to the code starting in line 464:
' if strUseExtendedProfile then ' strLastAuthor = strLastAuthor & "<a href=""pop_profile.asp?mode=display&id="& Topic_Last_Post_Author & """>" ' else ' strLastAuthor = strLastAuthor & "<a href=""JavaScript:openWindow2('pop_profile.asp?mode=display&id=" & Topic_Last_Post_Author & "')"">" ' end if ' strLastAuthor = strLastAuthor & Topic_Last_Post_Author_Name & "</a>" strLastAuthor = strLastAuthor & Topic_Last_Post_Author_Name
3. In default.asp, similar:
starting line 334:
strLastUser = "<br>by: " ' if strUseExtendedProfile then ' strLastUser = strLastUser & "<a href=""pop_profile.asp?mode=display&id="& RsForum("MEMBER_ID") & """>" ' else ' strLastUser = strLastUser & "<a href=""JavaScript:openWindow2('pop_profile.asp?mode=display&id=" & rsForum("MEMBER_ID") & "')"">" ' end if ' strLastUser = strLastUser & chkString(rsForum("M_NAME"),"display") & "</a>" & vbNewline strLastUser = strLastUser & chkString(rsForum("M_NAME"),"display") & vbNewline
starting line 675:
LastPostAuthorLink = " by: " ' if strUseExtendedProfile then ' LastPostAuthorLink = LastPostAuthorLink & "<a href=""pop_profile.asp?mode=display&id="& intLastPostMember_ID & """>" ' else ' LastPostAuthorLink = LastPostAuthorLink & "<a href=""JavaScript:openWindow2('pop_profile.asp?mode=display&id=" & intLastPostMember_ID & "')"">" ' end if 'LastPostAuthorLink = LastPostAuthorLink & chkString(strLastPostMember_Name,"display") & "</a>" LastPostAuthorLink = LastPostAuthorLink & chkString(strLastPostMember_Name,"display")
starting line 860:
'if strUseExtendedProfile then ' Response.Write " <a href=""pop_profile.asp?mode=display&id="& NewMember_Id & """>" 'else ' Response.Write " <a href=""JavaScript:openWindow2('pop_profile.asp?mode=display&id=" & NewMember_Id & "')"">" 'end if 'Response.Write NewMember_Name & "</a>.</font>" & vbNewline & _ Response.Write NewMember_Name & "</font>" & vbNewline & _
4. In topic.asp, add the <!-- and --> at the begining and end of the lines shown:
starting line 375:
<!-- <a href="pop_profile.asp?mode=display&id=<% =rsReplies("R_AUTHOR") %>"> --> <% else %> <!-- <a href="JavaScript:openWindow3('pop_profile.asp?mode=display&id=<% =rsReplies("R_AUTHOR") %>')"> -->
starting line 403:
<!-- <a href="pop_profile.asp?mode=display&id=<% =rsReplies("MEMBER_ID") %>"><img src="icon_profile.gif" height=15 width=15 alt="Show Profile" border="0" align="absmiddle" hspace="6"></a> --> <% else %> <!-- <a href="JavaScript:openWindow3('pop_profile.asp?mode=display&id=<% =rsReplies("MEMBER_ID") %>')"><img src="icon_profile.gif" height=15 width=15 alt="Show Profile" border="0" align="absmiddle" hspace="6"></a> -->
starting line 523:
<!-- <a href="pop_profile.asp?mode=display&id=<% =rsTopic("MEMBER_ID") %>"> --> <% else %> <!-- <a href="JavaScript:openWindow3('pop_profile.asp?mode=display&id=<% =rsTopic("MEMBER_ID") %>')"> -->
starting line 549:
<!-- <a href="pop_profile.asp?mode=display&id=<% =rsTopic("MEMBER_ID") %>"><img src="icon_profile.gif" height=15 width=15 alt="Show Profile" border="0" align="absmiddle" hspace="6"></a>--> <% else %> <!-- <a href="JavaScript:openWindow3('pop_profile.asp?mode=display&id=<% =rsTopic("MEMBER_ID") %>')"><img src="icon_profile.gif" height=15 width=15 alt="Show Profile" border="0" align="absmiddle" hspace="6"></a> -->
I guess this will do it. If I missed anything you know how to do it now...
------------------------------------------------- Installation Guide | Do's and Dont's | MODs |
 |
|
|
Topic  |
|