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)
 UserGroups v1.0 BETA2
 New Topic  Topic Locked
 Printer Friendly
Previous Page | Next Page
Author Previous Topic Topic Next Topic
Page: of 10

Nikkol
Forum Moderator

USA
6907 Posts

Posted - 02 December 2003 :  09:02:47  Show Profile
what is the mix up in the readme, i must have missed that.

1. what is "admin allowed members"
2. you probably have a large user base and that's why it has a problem saving, it's timing out. suggestion would be to do what you did and move a limited number at a time. are you still having a problem with names containin ~ ?
3. there will be a fix for that i think. I'll be working on updating the zip file later tonight.
4. confirmation in what sense? like saying "are you sure?"


Nikkol ~ Help Us Help You | ReadMe | 3.4.03 fixes | security fixes ~
Go to Top of Page

Davio
Development Team Member

Jamaica
12217 Posts

Posted - 02 December 2003 :  09:51:20  Show Profile
Wizard, there is a fix for #3 in my post here: http://forum.snitz.com/forum/topic.asp?TOPIC_ID=48967&whichpage=2#267397

Support Snitz Forums
Go to Top of Page

altisdesign
Junior Member

United Kingdom
357 Posts

Posted - 02 December 2003 :  19:20:00  Show Profile
quote:
Originally posted by DavidRhodes

quote:
Originally posted by Davio

David, i got that error in the beta 1 version of the mod. The changes you made, by adding a check for EOF, is correct. The green code you highlighted won't be executed because blnAM = 0.


Are you sure, in my scenario I think blnAM should be 1.
	strSql = "SELECT MEMBER_ID, FORUM_ID FROM " & strTablePrefix & "ALLOWED_MEMBERS "
	strSql = strSql & " WHERE FORUM_ID = " & cLng(fForum_ID)
	strSql = strSql & " AND MEMBER_ID = " & cLng(fMemberID)

	Set rsAllowedMember = Server.CreateObject("ADODB.Recordset")
	rsAllowedMember.open strSql, my_Conn
	blnAM = 0
	if not rsAllowedMember.bof and not rsAllowedMember.eof then blnAM = 1
	rsAllowedMember.close
	set rsAllowedMember = nothing

blnAM is set to 1 if the member is an allowed member of the forum.

Strange thing is,
Scenario 1: there are 3 admins (inc me), I am not in the allowed member list, they are, but we can all see the forum anyway because we are admins. I don't get the error but the other 2 do.

Scenario 2: Same forum, all removed from the allowed member list, all of us get the error.

I tried adding the extra BOF check but that didn't work




David, I get this problem on line 1695 of inc_func_common.asp now when I'm moving posts from forum to forum. I havnt seen it before.. did you ever resolve the issue?

Altis Design offers all manner of web design services to a variety of commercial and personal clients
Go to Top of Page

DavidRhodes
Senior Member

United Kingdom
1222 Posts

Posted - 03 December 2003 :  04:15:45  Show Profile
I get this post moving topics aswell as posting in one forum, I haven't fixed it yet

The UK MkIVs Forum
Go to Top of Page

vmplanet
Junior Member

112 Posts

Posted - 03 December 2003 :  09:12:37  Show Profile
Okay Reinsintz.. will do nothing.
Go to Top of Page

wizard
Junior Member

208 Posts

Posted - 06 December 2003 :  08:50:23  Show Profile  Visit wizard's Homepage
For now, I have decided to leave the default forumers alone by not creating usergroup for it. I only create the others like VIPs, Probation, etc. The "admin allowed" is a MOD (not sure by who) which adds a new column in db to check if the user have access to the admin options. It's an easy way to get the Global Moderator rank without modding a lot of code.

With regard to the fix you all mention. I tried and got this:

Microsoft OLE DB Provider for SQL Server error '80040e14'

There are more columns in the INSERT statement than values specified in the VALUES clause. The number of values in the VALUES clause must match the number of columns specified in the INSERT statement.

/admin_usergroups.asp, line 76


I have solve that. Thanks.

Edited by - wizard on 06 December 2003 08:55:52
Go to Top of Page

Baroudeur
Starting Member

25 Posts

Posted - 11 December 2003 :  03:44:51  Show Profile
Is there a way to permit Moderator to edit user groups, allowing new members to been inserted or remove some other one ?

This account was hacked into by Image, a very honest guy as you all can see! Stealing people's passwords is his pasttime. Beware of this, before you register at his forums!
Go to Top of Page

DavidRhodes
Senior Member

United Kingdom
1222 Posts

Posted - 11 December 2003 :  04:27:13  Show Profile
quote:
Originally posted by Baroudeur

Is there a way to permit Moderator to edit user groups, allowing new members to been inserted or remove some other one ?



There's an option in the admin page called "Moderator Access to Forum UserGroup Permissions", set it to Edit.

The UK MkIVs Forum
Go to Top of Page

Baroudeur
Starting Member

25 Posts

Posted - 11 December 2003 :  11:27:13  Show Profile
Tats true David, but this only permit to authorize or forbid one usergroup to have acess in a forum, would like too to have possibility for Moderator to add or remove people inside a user group

This account was hacked into by Image, a very honest guy as you all can see! Stealing people's passwords is his pasttime. Beware of this, before you register at his forums!
Go to Top of Page

gDewar
Starting Member

USA
17 Posts

Posted - 27 December 2003 :  18:06:36  Show Profile  Send gDewar an AOL message
Nikkol: First off, I want to thank you for this MOD! In a sense I'm kinda glad I waited this long to start using Snitz... because I would have probably ended up trying to create User Groups by myself. (And would have ended making a much sloppier implementation) I haven't gotten a chance to use the MOD yet, though, I'm in the middle of putting it in.

I noticed a minor editing error on the UserGroups Mod readme.htm...

Where you detail the changes in code for the forum.asp, the right pane reads:



if strPrivateForums = "1" and (Request.Form("Method_Type") <> "login") and (Request.Form("Method_Type") <> "logout") and ForumChkSkipAllowed = 0 then
result = ChkForumAccess(Forum_ID, MemberID, true)
end if

'####### Begin UserGroup MOD #######
if strPrivateForums <> "1" and (Request.Form("Method_Type") <> "login") and (Request.Form("Method_Type") <> "logout") and ForumChkSkipAllowed = 0 then
result = ChkForumAccess(Forum_ID, MemberID, true)
end if
'####### End UserGroup MOD #######

if strModeration = "1" and AdminAllowed = 1 then
strUGView = Application(strCookieURL & "STRUGVIEW")
strUGMemView = Application(strCookieURL & "STRUGMEMVIEW")
strUGModForums = Application(strCookieURL & "STRUGMODFORUMS")
'####### End UserGroup MOD #######

if strSecureAdmin = "0" then
Session(strCookieURL & "Approval") = "15916941253"
end if




But should read:



if strPrivateForums = "1" and (Request.Form("Method_Type") <> "login") and (Request.Form("Method_Type") <> "logout") and ForumChkSkipAllowed = 0 then
result = ChkForumAccess(Forum_ID, MemberID, true)
end if

'####### Begin UserGroup MOD #######
if strPrivateForums <> "1" and (Request.Form("Method_Type") <> "login") and (Request.Form("Method_Type") <> "logout") and ForumChkSkipAllowed = 0 then
result = ChkForumAccess(Forum_ID, MemberID, true)
end if
'####### End UserGroup MOD #######

if strModeration = "1" and AdminAllowed = 1 then
UnModeratedPosts = CheckForUnModeratedPosts("FORUM", Cat_ID, Forum_ID, 0)
end if




At least, I *think* that's what it's supposed to read. Hope this helps!

Your Faithful Useless Newbie
Glenn Dewar
Go to Top of Page

gDewar
Starting Member

USA
17 Posts

Posted - 27 December 2003 :  19:48:28  Show Profile  Send gDewar an AOL message
I found the error in the ReadMe file that richfed and David Rhodes were talking about...

In the section on editing the Register.asp, next to the boxes detailing changes to line 189, there is a stay "surrounding code" box. There should be another "approximately line" box before it saying:

quote:
approximately line 577 add:
'####### Begin UserGroup MOD #######
if strAutoLogon = "1" then
          Call UserGroupAutoJoin(chkString(Session(strCookieURL & "strNTUserFullName"),"SQLString"))
else
          Call UserGroupAutoJoin(chkString(trim(Request.Form("Name")),"SQLString"))
end if
'####### End UserGroup MOD #######



Go to Top of Page

DavidRhodes
Senior Member

United Kingdom
1222 Posts

Posted - 29 December 2003 :  13:42:17  Show Profile
quote:
Originally posted by altisdesign

quote:
Originally posted by DavidRhodes

quote:
Originally posted by Davio

David, i got that error in the beta 1 version of the mod. The changes you made, by adding a check for EOF, is correct. The green code you highlighted won't be executed because blnAM = 0.


Are you sure, in my scenario I think blnAM should be 1.
	strSql = "SELECT MEMBER_ID, FORUM_ID FROM " & strTablePrefix & "ALLOWED_MEMBERS "
	strSql = strSql & " WHERE FORUM_ID = " & cLng(fForum_ID)
	strSql = strSql & " AND MEMBER_ID = " & cLng(fMemberID)

	Set rsAllowedMember = Server.CreateObject("ADODB.Recordset")
	rsAllowedMember.open strSql, my_Conn
	blnAM = 0
	if not rsAllowedMember.bof and not rsAllowedMember.eof then blnAM = 1
	rsAllowedMember.close
	set rsAllowedMember = nothing

blnAM is set to 1 if the member is an allowed member of the forum.

Strange thing is,
Scenario 1: there are 3 admins (inc me), I am not in the allowed member list, they are, but we can all see the forum anyway because we are admins. I don't get the error but the other 2 do.

Scenario 2: Same forum, all removed from the allowed member list, all of us get the error.

I tried adding the extra BOF check but that didn't work




David, I get this problem on line 1695 of inc_func_common.asp now when I'm moving posts from forum to forum. I havnt seen it before.. did you ever resolve the issue?



Has anyone fixed this yet?

The UK MkIVs Forum
Go to Top of Page

gDewar
Starting Member

USA
17 Posts

Posted - 30 December 2003 :  02:49:34  Show Profile  Send gDewar an AOL message
David,

I come from VB6 land... so maybe this is a dumb question...

In VB, True is = -1, Not 1. I know this is also the case in script because

Response.Write Int(True)

Returns -1

Shouldn't you guys use -1, not 1? Also, why aren't you guys using the True and False keywords to begin with?

This would seem especially important in this lawless land where there are no data types to force the correct values.

Maybe I'm just being a code fascist, I don't know... Just starting to get into this asp stuff so not sure I feel confident enough yet to root out the problem, but I may be more helpful soon - I've been using the forums in Interdev to teach myself this stuff.

Glenn
Go to Top of Page

gDewar
Starting Member

USA
17 Posts

Posted - 07 January 2004 :  13:15:29  Show Profile  Send gDewar an AOL message
quote:
Originally posted by DavidRhodes

Yeah, it's definitely that line, maybe it needs a BOF check also?
Do While Not rsAllowedUserGroups.eof Or rsAllowedUserGroups.bof Or OldisAllowedMember <> 1




I found the problem there. It's not the .Eof check that's the problem. It's the (OldisAllowedMember <> 1) comparison.

Here we are saying if Eof is not true Or OldisAllowedMember <> 1 then the code can move to the next line. So then it tries to get the field value regardless of whether there is one there or not.

I changed it to:
Do Until rsAllowedUserGroups.eof Or OldisAllowedMember = 1

Note that I used an Until here. You could say:
Do While Not rsAllowedUserGroups.eof And OldisAllowedMember <> 1

but I really prefer to use Until Eof instead of While Not Eof. Not is an extra operation (albeit the fastest one that can occur)

Let me know if this has been useful.
Go to Top of Page

DavidRhodes
Senior Member

United Kingdom
1222 Posts

Posted - 07 January 2004 :  14:47:13  Show Profile
quote:
Originally posted by gDewar

quote:
Originally posted by DavidRhodes

Yeah, it's definitely that line, maybe it needs a BOF check also?
Do While Not rsAllowedUserGroups.eof Or rsAllowedUserGroups.bof Or OldisAllowedMember <> 1




I found the problem there. It's not the .Eof check that's the problem. It's the (OldisAllowedMember <> 1) comparison.

Here we are saying if Eof is not true Or OldisAllowedMember <> 1 then the code can move to the next line. So then it tries to get the field value regardless of whether there is one there or not.

I changed it to:
Do Until rsAllowedUserGroups.eof Or OldisAllowedMember = 1

Note that I used an Until here. You could say:
Do While Not rsAllowedUserGroups.eof And OldisAllowedMember <> 1

but I really prefer to use Until Eof instead of While Not Eof. Not is an extra operation (albeit the fastest one that can occur)

Let me know if this has been useful.



That seems to have worked, thanks!

The UK MkIVs Forum
Go to Top of Page
Page: of 10 Previous Topic Topic Next Topic  
Previous Page | 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.14 seconds. Powered By: Snitz Forums 2000 Version 3.4.07