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)
 Universal Login for Snitz 3.4.03
 New Topic  Topic Locked
 Printer Friendly
Previous Page
Author Previous Topic Topic Next Topic
Page: of 13

jayceeaz
Starting Member

11 Posts

Posted - 02 March 2004 :  13:12:13  Show Profile
quote:
Originally posted by jayceeaz

Ok, I'm baaaack! Been a while cuz I got my host yanked. Getting back into the Snitz thang since I am alive again. Annnnyway, here's an issue I had before that I never bothered to ask about. By the unanswered questions here over the last 10 mos or so, I will assume I will never get an answer, but at least we can compare notes. :)

(posted elsewhere, so repeat)



Yeah, I got only one problem with Universal Login; I seem to end up with two complete collections of vars running at the same time... so when I make changes, I have to literally restart IIS before the changes can be read by the second (who knows why?) collection...

I was too lazy to go see why, when I run varChk.asp:

<% response.write "<table border=""1"">"
Response.Write("<tr><th>APPLICATION VARIABLE</th><th>CONTENTS</th></tr>")
For Each Item in Application.Contents()
Response.Write("<tr><td><font color=""black"" size=""2"">" & Item & "</font></td>" &_
"<td><font color=""black"" size=""2"">" & Application.Contents(Item) & "</font></td></tr>")
Next
response.write "</table>"
%>



I see two sets of forum settings. :) Guess I am including it twice or something. Shrug.



Anyone else see this problem? The exact symptom is:

(providing you actually use forum color schemes on your website as well, like I do)
Open your Universal site.
Log in.
Go to Forum Admin.
Change a color (for example: Category Font Color, set it to something noticably different).
Go back to Forums and verify the color you wanted is changed (you should see your category font titles in the new color.
Now go back to your website, and you will still see the old color from before you made the change.

In looking into why, it's because there are two collections running... one that is "/" (when you first go to the site and run the above varChk.asp, you will see only one collection) and one that is "/forum/" (now, rerun varChk.asp after clicking on the link to your forums, and see the new collection).

Any advice?


Go to Top of Page

mankler
Starting Member

Sweden
6 Posts

Posted - 23 May 2004 :  04:43:00  Show Profile  Visit mankler's Homepage
I don't know if this is of any help, but here is my stripped down inc_header.
I used skyhawks code (which didn't work for me. you can find it on the second page in this topic) and made some very minor changes.

<%
'#################################################################################
'## Snitz Forums 2000 v3.4.04
'#################################################################################
'## Copyright (C) 2000-04 Michael Anderson, Pierre Gorissen,
'## Huw Reddick and Richard Kinser
'##
'## This program is free software; you can redistribute it and/or
'## modify it under the terms of the GNU General Public License
'## as published by the Free Software Foundation; either version 2
'## of the License, or (at your option) any later version.
'##
'## All copyright notices regarding Snitz Forums 2000
'## must remain intact in the scripts and in the outputted HTML
'## The "powered by" text/logo with a link back to
'## http://forum.snitz.com in the footer of the pages MUST
'## remain visible when the pages are viewed on the internet or intranet.
'##
'## This program is distributed in the hope that it will be useful,
'## but WITHOUT ANY WARRANTY; without even the implied warranty of
'## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
'## GNU General Public License for more details.
'##
'## You should have received a copy of the GNU General Public License
'## along with this program; if not, write to the Free Software
'## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
'##
'## Support can be obtained from our support forums at:
'## http://forum.snitz.com
'##
'## Correspondence and Marketing Questions can be sent to:
'## manderson@snitz.com
'##
'## or
'##
'## Snitz Communications
'## C/O: Michael Anderson
'## PO Box 200
'## Harpswell, ME 04079
'#################################################################################
%>
<!--#INCLUDE FILE="inc_func_common.asp" -->
<%

'if strShowTimer = "1" then
' '### start of timer code
' Dim StopWatch(19)

' sub StartTimer(x)
' StopWatch(x) = timer
' end sub

' function StopTimer(x)
' EndTime = Timer

' 'Watch for the midnight wraparound...
' if EndTime < StopWatch(x) then
' EndTime = EndTime + (86400)
' end if

' StopTimer = EndTime - StopWatch(x)
' end function

' StartTimer 1

'### end of timer code
'end if

set my_Conn = Server.CreateObject("ADODB.Connection")
my_Conn.Open strConnString

if (strAuthType = "nt") then
call NTauthenticate()
if (ChkAccountReg() = "1") then
call NTUser()
end if
end if



'## START - REMOVAL, MODIFICATION OR CIRCUMVENTING THIS CODE WILL VIOLATE THE SNITZ FORUMS 2000 LICENSE AGREEMENT
Response.Write "<meta name=""copyright"" content=""This Forum code is Copyright (C) 2000-02 Michael Anderson, Pierre Gorissen, Huw Reddick and Richard Kinser, Non-Forum Related code is Copyright (C) " & strCopyright & """>" & vbNewline
'## END - REMOVAL, MODIFICATION OR CIRCUMVENTING THIS CODE WILL VIOLATE THE SNITZ FORUMS 2000 LICENSE AGREEMENT



strDBNTUserName = Request.Cookies(strUniqueID & "User")("Name")
strDBNTFUserName = trim(chkString(Request.Form("Name"),"SQLString"))
if strDBNTFUserName = "" then strDBNTFUserName = trim(chkString(Request.Form("User"),"SQLString"))
if strAuthType = "nt" then
strDBNTUserName = Session(strCookieURL & "userID")
strDBNTFUserName = Session(strCookieURL & "userID")
end if

select case Request.Form("Method_Type")
case "login"
strEncodedPassword = sha256("" & Request.Form("Password"))
select case chkUser(strDBNTFUserName, strEncodedPassword,-1)
case 1, 2, 3, 4
Call DoCookies(Request.Form("SavePassword"))
strLoginStatus = 1
case else
strLoginStatus = 0
end select
case "logout"
Call ClearCookies()
end select

if trim(strDBNTUserName) <> "" and trim(Request.Cookies(strUniqueID & "User")("Pword")) <> "" then
chkCookie = 1
mLev = cLng(chkUser(strDBNTUserName, Request.Cookies(strUniqueID & "User")("Pword"),-1))
chkCookie = 0
else
MemberID = -1
mLev = 0
end if

select case Request.Form("Method_Type")
case "login"
if strLoginStatus = 0 then
Response.Write "<p align=""center"">Your username and/or password were incorrect.</p>" & vbNewLine & _
"<p align=""center"">Please either try again or register for an account.</p>" & vbNewLine
else
Response.Write "<p align=""center"">You logged on successfully!</p>" & vbNewLine & _
"<p align=""center"">Thank you for your participation.</p>" & vbNewLine
end if
Response.Write "<meta http-equiv=""Refresh"" content=""1; URL=" & Request.ServerVariables("HTTP_REFERER") & """>" & vbNewLine & _
"<p align=""center""><a href=""" & Request.ServerVariables("HTTP_REFERER") & """>Back To Previous Page</a></p>" & vbNewLine
Response.End
case "logout"
Response.Write"<p align=""center"">You logged out successfully!</p>" & vbNewLine & _
"<p align=""center"">Thank you for your participation.</p>" & vbNewLine & _
"<meta http-equiv=""Refresh"" content=""1; URL=" & Request.ServerVariables("URL") & """>" & vbNewLine & _
"<p align=""center""><a href=""" & Request.ServerVariables("URL") & """>Back To Previous Page</a></p>" & vbNewLine
Response.End
end select
%>





I've also modified inc_login. All font and color tags are deleted, as well as the "Login questions". It works fine for me.

<%
'#################################################################################
'## Copyright (C) 2000-02 Michael Anderson, Pierre Gorissen,
'## Huw Reddick and Richard Kinser
'##
'## This program is free software; you can redistribute it and/or
'## modify it under the terms of the GNU General Public License
'## as published by the Free Software Foundation; either version 2
'## of the License, or any later version.
'##
'## All copyright notices regarding Snitz Forums 2000
'## must remain intact in the scripts and in the outputted HTML
'## The "powered by" text/logo with a link back to
'## http://forum.snitz.com in the footer of the pages MUST
'## remain visible when the pages are viewed on the internet or intranet.
'##
'## This program is distributed in the hope that it will be useful,
'## but WITHOUT ANY WARRANTY; without even the implied warranty of
'## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
'## GNU General Public License for more details.
'##
'## You should have received a copy of the GNU General Public License
'## along with this program; if not, write to the Free Software
'## Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
'##
'## Support can be obtained from support forums at:
'## http://forum.snitz.com
'##
'## Correspondence and Marketing Questions can be sent to:
'## reinhold@bigfoot.com
'##
'## or
'##
'## Snitz Communications
'## C/O: Michael Anderson
'## PO Box 200
'## Harpswell, ME 04079
'#################################################################################

fName = strDBNTFUserName
fPassword = ChkString(Request.Form("Password"), "SQLString")


Response.Write " <table border=""0"" cellspacing=""0"" cellpadding=""0"" align=""center"">" & vbNewLine & _
" <tr>" & vbNewLine & _
" <td valign=""top"">" & vbNewLine & _
" <table table width=""100%"" border=""0"" cellspacing=""1"" cellpadding=""4"" align=""center"">" & vbNewLine & _
" <tr>" & vbNewLine & _
" <td valign=""top"">" & vbNewLine & _
" <table border=""0"" cellpadding=""6"" cellspacing=""0"" width=""90%"" align=""center"">" & vbNewLine & _
" <tr valign=""top"">" & vbNewLine & _
" <td valign=""top"">" & vbNewLine
if (mlev = 0) then
if RequestMethod = "POST" and strLoginStatus = 0 then Response.Write(" Your username and/or password was incorrect.<br />" & vbNewLine)
Response.Write " <form action=""" & Request.ServerVariables("URL") & """ method=""post"" id=""Form1"" name=""Form1"">" & vbNewLine & _
" <input type=""hidden"" name=""Method_Type"" value=""login"">" & vbNewLine & _
" " & vbNewLine & _
" Username:<br />" & vbNewLine & _
" <input type=""text"" name=""Name"" size=""14"" maxLength=""25"" tabindex=""1"" value="""" style=""width:120px;"">" & vbNewLine & _
" " & vbNewLine & _
" </td></tr>" & vbNewLine & _
" <tr>" & vbNewLine & _
" <td valign=""top"">" & vbNewLine & _
" Password:<br />" & vbNewLine & _
" <input type=""password"" name=""Password"" size=""14"" tabindex=""2"" maxLength=""25"" value="""" style=""width:120px;"">" & vbNewLine
if strGfxButtons = "1" then
Response.Write " <input src=""" & strForumURL & "" & strImageUrl & "button_login.gif"" type=""image"" border=""0"" value=""Login"" id=""submit1"" name=""submit1"" tabindex=""3"">" & vbNewLine
else
Response.Write " <input class=""button"" type=""submit"" value=""Login"" id=""submit1"" name=""submit1"" tabindex=""3""></font>" & vbNewLine
end if




' new code################################################## </td> line under this new
else
Response.Write " <form action=""" & Request.ServerVariables("URL") & """ method=""post"" id=""form2"" name=""form2"">" & vbNewLine & _
" <input type=""hidden"" name=""Method_Type"" value=""logout"">" & vbNewLine & _
" <tr>" & vbNewLine & _
" <td align=""center"">" & vbNewLine & _
" You are logged on as<br />"
if strAuthType="nt" then
Response.Write "<b>" & Session(strCookieURL & "username") & " (" & Session(strCookieURL & "userid") & ")</b>" & vbNewLine
else
if strAuthType = "db" then
Response.Write "<b>" & ChkString(strDBNTUserName, "display") & "</b></td>" & vbNewLine
if strGfxButtons = "1" then
Response.Write "<input src=""" & strForumURL & "" & strImageUrl & "button_logout.gif"" type=""image"" border=""0"" value=""Logout"" id=""submit1"" name=""Logout"" tabindex=""-1"">"
else
Response.Write "<input type=""submit"" value=""Logout"" id=""submit1"" name=""submit1"" tabindex=""-1"">"
end if
end if
end if
Response.Write " </td>" & vbNewLine & _
" </tr>" & vbNewLine
if (mlev = 4) or (lcase(strNoCookies) = "1") then
Response.Write " <tr>" & vbNewLine & _
" <td align=""center""><a href=""" & strForumURL & "admin_home.asp""" & dWStatus("Access the Forum Admin Functions...") & " tabindex=""-1"">Admin Options</a>"
if mLev = 4 and (strEmailVal = "1" and strRestrictReg = "1" and strEmail = "1" and User_Count > 0) then Response.Write(" | <a href=""" & strForumURL & "admin_accounts_pending.asp""" & dWStatus("(" & User_Count & ") Member(s) awaiting approval") & " tabindex=""-1"">(" & User_Count & ") Member(s) awaiting approval</a>")
Response.Write "<br /><br /></td>" & vbNewLine & _
" </tr>" & vbNewLine
end if
Response.Write " </form>" & vbNewLine
end if
Response.Write " </table>" & vbNewLine & _
" </td>" & vbNewLine & _
" </tr>" & vbNewLine & _
"</table>" & vbNewLine & _
" </td>" & vbNewLine & _
" </form>" & vbNewLine & _
" </tr>" & vbNewLine & _
" </table>" & vbNewLine

%>



EDIT: Please keep in mind that I'm not very skilled in asp. There are probably some errors in these codes that I can't find.

Edited by - mankler on 23 May 2004 04:56:08
Go to Top of Page

pako
Starting Member

Spain
39 Posts

Posted - 28 May 2004 :  10:44:29  Show Profile  Visit pako's Homepage
quote:
Originally posted by jayceeaz


I see two sets of forum settings. :) Guess I am including it twice or something. Shrug.



Anyone else see this problem? The exact symptom is:

(providing you actually use forum color schemes on your website as well, like I do)
Open your Universal site.
Log in.
Go to Forum Admin.
Change a color (for example: Category Font Color, set it to something noticably different).
Go back to Forums and verify the color you wanted is changed (you should see your category font titles in the new color.
Now go back to your website, and you will still see the old color from before you made the change.

In looking into why, it's because there are two collections running... one that is "/" (when you first go to the site and run the above varChk.asp, you will see only one collection) and one that is "/forum/" (now, rerun varChk.asp after clicking on the link to your forums, and see the new collection).

Any advice?





You see two sets of forum settings because of strCookieURL value. When you go to the site create set with value "/" and when you go to the forum create set with value "/forum/". If you go to administration panel, you only change the second set (see config.asp). Members in site will see these changes when this application set will be reset and set again (but not when you change it as administrator. see in config.asp when the forum settings are reloaded).
Go to Top of Page

xgammon
Starting Member

6 Posts

Posted - 09 June 2004 :  11:55:55  Show Profile
I seem to be having trouble with the include virtual command. It cant seem to actually find this ... is there something that I need to change on my server, or is it something else?

TY
X


Xgammon
Go to Top of Page

xgammon
Starting Member

6 Posts

Posted - 09 June 2004 :  12:48:16  Show Profile
Ignore my question ... I will just use the login from within the forum folder and include the files absolutely as oppose to virtually. Seems to work fine ... @tonic ... this is a nifty device I could see the use for it. Thanks for taking the time to work on it.


Xgammon
Go to Top of Page

xgammon
Starting Member

6 Posts

Posted - 10 June 2004 :  12:44:36  Show Profile
I'll try this one ... I have read this whole post and remember seeing questions about the login not working. You log in and then you have to re-log-in again ... I dont remember seeing a solution so if anyone reads this post by tonight or tomorrow can ya help. If not ... I'm sure by then I will come acroos it and you can iksnay on the answer K!


Xgammon
Go to Top of Page

xgammon
Starting Member

6 Posts

Posted - 10 June 2004 :  13:13:28  Show Profile
Solved it! ... Jeez I should stop posting .. this topics seems to resemble a lifeless corpse. I probably could keep up the conversation by myself ... however, saving myself from further embarassment ... I probably will move on.


Xgammon
Go to Top of Page

TERM
New Member

82 Posts

Posted - 22 September 2004 :  23:15:40  Show Profile
I got the script working, but there is lay-out errors now, can someone please help me get rid of these errors;

My page looks like this (http://www.thecgn.com). The changes I want are;
1. I want my page to be pressed up against the left margin. It was against the left margin before I entered this MOD, but now its gone off course again.

Here is a copy of the text version of my inc_header.asp, if someone can look through it and PLEASE help me get rid of the problem or something, I would really appreciate it.

http://www.thecgn.com/inc_header.txt

Edited by - TERM on 22 September 2004 23:52:15
Go to Top of Page

EvilAndy
Starting Member

Australia
46 Posts

Posted - 10 November 2004 :  07:46:59  Show Profile
Is there an easy way to get the login script to continue processing the page rather than Response.End if the user cant login? I would like to display the rest of my page even though they have not been able to sign in. Or is it better just to open another page containing an error statement? Your thoughts.
Go to Top of Page

jjams
Starting Member

USA
5 Posts

Posted - 13 November 2004 :  18:39:54  Show Profile
OK call me dumb but every time I put the
<!--#INCLUDE VIRTUAL="forum/inc_login.asp"-->
<!--#INCLUDE VIRTUAL="forum/config.asp"-->
<!--#INCLUDE VIRTUAL="forum/inc_sha256.asp"-->
<!--#INCLUDE VIRTUAL="forum/inc_func_common.asp"-->
<!--#INCLUDE VIRTUAL="forum/inc_header.asp"-->
Into my site page I get 500 server Error I have tried this on test server and get the same error.

anyone can help
thanks,

`Sears
Go to Top of Page

PeeWee.Inc
Senior Member

United Kingdom
1893 Posts

Posted - 13 November 2004 :  19:30:00  Show Profile  Visit PeeWee.Inc's Homepage
do you have Friendly errors turned off in IE?

De Priofundus Calmo Ad Te Damine
Go to Top of Page
Page: of 13 Previous Topic Topic Next Topic  
Previous 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.23 seconds. Powered By: Snitz Forums 2000 Version 3.4.07