Snitz Forums 2000
Snitz Forums 2000
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 Help Groups for Snitz Forums 2000 Users
 Help: MOD Implementation
 missing something in inc_header.asp
 New Topic  Topic Locked
 Printer Friendly
Next Page
Author Previous Topic Topic Next Topic
Page: of 2

Ryan
Average Member

USA
858 Posts

Posted - 06 September 2003 :  19:50:22  Show Profile  Visit Ryan's Homepage
I am redesinging inc_header.asp but I am having only one problem with it. When you are logged out it shows the login in box but below it it also says You are logged in as with the logout icon. I must have missed something. If one of you coders better than me would like at my txt of inc_header.asp I would appreciate it. While you are at it, if you would, please give the file a quick going over to determine if it will work overall. (Login in, usergroups, etc) I looked it over and carefully cut code and added it elsewhere and I think I did it but I would appreciate verification.
Visit the site I am talking about.

The Poultry Link - "Serving the best of the fancy with the best of the web"
Forum Setup Help

masterao
Senior Member

Sweden
1678 Posts

Posted - 06 September 2003 :  21:09:31  Show Profile  Visit masterao's Homepage
You must have removed an else from your inc_header.asp.

Look for line 486 of code in your inc_header.asp:


	end if -> 486
	Response.Write	"        <form action=""" & Request.ServerVariables("URL") & """ method=""post"" id=""form2"" name=""form2"">" & vbNewLine & _ -> 487


Add else (marked red below) below end if so that it looks like this:


	end if
else
	Response.Write	"        <form action=""" & Request.ServerVariables("URL") & """ method=""post"" id=""form2"" name=""form2"">" & vbNewLine & _

Jan
===========
FR Portal Forums | Active Users 4.0.20 Mod
Go to Top of Page

Ryan
Average Member

USA
858 Posts

Posted - 06 September 2003 :  21:27:31  Show Profile  Visit Ryan's Homepage
Sorry Jan, didnt work. I installed it at line 487 and got an error wanting the else to be removed.

The Poultry Link - "Serving the best of the fancy with the best of the web"
Forum Setup Help
Go to Top of Page

The Impact
Junior Member

Australia
398 Posts

Posted - 06 September 2003 :  21:59:37  Show Profile
The 'Else' is needed where Jan suggested.

The error is appearing because the statement isn't ended.

		Response.Write	"<br /><br /></font></td>" & vbNewLine & _
				"        </tr>" & vbNewLine
	end if
	Response.Write	"        </form>" & vbNewLine
end if
Response.Write	"      </table>" & vbNewLine & _
		"    </td>" & vbNewLine & _
		"  </tr>" & vbNewLine & _
Add the 'End If' in red located below the form tag around line 521.

That should fix your problem !
Go to Top of Page

masterao
Senior Member

Sweden
1678 Posts

Posted - 07 September 2003 :  11:10:22  Show Profile  Visit masterao's Homepage
The Impact is correct. I missed that the ending end if wasn't in place, and it should be put there as The Impact suggested. Nice catch, btw .

Jan
===========
FR Portal Forums | Active Users 4.0.20 Mod
Go to Top of Page

Ryan
Average Member

USA
858 Posts

Posted - 09 September 2003 :  13:53:41  Show Profile  Visit Ryan's Homepage
Thanks. Will try when I get the chance. I was thinking that possibly the else was supposed to be there with something else.

The Poultry Link - "Serving the best of the fancy with the best of the web"
Forum Setup Help
Go to Top of Page

Ryan
Average Member

USA
858 Posts

Posted - 09 September 2003 :  22:00:00  Show Profile  Visit Ryan's Homepage
Sorry it didnt work

The Poultry Link - "Serving the best of the fancy with the best of the web"
Forum Setup Help
Go to Top of Page

The Impact
Junior Member

Australia
398 Posts

Posted - 10 September 2003 :  04:58:01  Show Profile
This may sound like a really stupid question but did you complete both changes properly ?

And did you have an error or just the problem you started with ?
Go to Top of Page

Ryan
Average Member

USA
858 Posts

Posted - 10 September 2003 :  07:14:18  Show Profile  Visit Ryan's Homepage
I added the pieces of code to the lines you told me. I got an error.

The Poultry Link - "Serving the best of the fancy with the best of the web"
Forum Setup Help
Go to Top of Page

masterao
Senior Member

Sweden
1678 Posts

Posted - 10 September 2003 :  09:11:48  Show Profile  Visit masterao's Homepage
I tested your inc_header.asp on my test-forum (with some changes), and I noticed the error you mentioned.

Replace the last part of your inc_header (starting on line 440) with the following, and it should work properly for you:


if (mlev = 0) then
		Response.Write	"        <form action=""" & Request.ServerVariables("URL") & """ method=""post"" id=""form1"" name=""form1"">" & vbNewLine & _
				"        <input type=""hidden"" name=""Method_Type"" value=""login"">" & vbNewLine & _
				"        <tr>" & vbNewLine & _
				"          <td align=""center"">" & vbNewLine & _
				"            <table>" & vbNewLine & _
				"              <tr>" & vbNewLine
		if (strAuthType = "db") then
			Response.Write	"                <td><font face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize & """><b>Username:</b></font><br />" & vbNewLine & _
					"                <input type=""text"" name=""Name"" size=""10"" maxLength=""25"" value=""""></td>" & vbNewLine & _
					"                <td><font face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize & """><b>Password:</b></font><br />" & vbNewLine & _
					"                <input type=""password"" name=""Password"" size=""10"" maxLength=""25"" value=""""></td>" & vbNewLine & _
					"                <td valign=""bottom"">" & vbNewLine
			if strGfxButtons = "1" then
				Response.Write	"                <input src=""" & strImageUrl & "login_box_button.gif"" type=""image"" border=""0"" value=""Login"" id=""submit1"" name=""Login"">" & vbNewLine
			else
				Response.Write	"                <input type=""submit"" value=""Login"" id=""submit1"" name=""submit1"">" & vbNewLine
			end if 
			Response.Write	"                </td>" & vbNewLine & _
					"              </tr>" & vbNewLine & _
					"              <tr>" & vbNewLine & _
					"                <td colspan=""3"" align=""left""><font face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize & """>" & vbNewLine & _
					"                <input type=""checkbox"" name=""SavePassWord"" value=""true"" tabindex=""-1"" CHECKED><b> Save Password</b></font></td>" & vbNewLine
		else
			if (strAuthType = "nt") then 
				Response.Write	"                <td><font face=""" & strDefaultFontFace & """ size=""1""  color=""" & strHiLiteFontColor & """>Please <a href=""policy.asp"" tabindex=""-1"">register</a> to post in these Forums</font></td>" & vbNewLine
			end if

		Response.Write	"              </tr>" & vbNewLine
		if (lcase(strEmail) = "1") then
			Response.Write	"              <tr>" & vbNewLine & _
					"                <td colspan=""3"" align=""left""><font face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize & """>" & vbNewLine & _
					"                <a href=""password.asp""" & dWStatus("Choose a new password if you have forgotten your current one...") & " tabindex=""-1"">Forgot your "
			if strAuthType = "nt" then Response.Write("Admin ")
			Response.Write	"Password?</a>" & vbNewLine
			if (lcase(strNoCookies) = "1") then
				Response.Write	"                |" & vbNewLine & _
						"                <a href=""admin_home.asp""" & dWStatus("Access the Forum Admin Functions...") & " tabindex=""-1"">Admin Options</a>" & vbNewLine
			end if
			Response.Write	"                <br /><br /></font></td>" & vbNewLine & _
					"              </tr>" & vbNewLine
		end if
		Response.Write	"            </table>" & vbNewLine & _
				"          </td>" & vbNewLine & _
				"        </tr>" & vbNewLine & _
				"        </form>" & vbNewLine
	end if
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 & _
			"            <table>" & vbNewLine & _
			"              <tr>" & vbNewLine & _
			"                <td align=""center""><font face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize & """>You are logged on as<br />"
	if strAuthType="nt" then
		Response.Write	"<b>" & Session(strCookieURL & "username") & " (" & Session(strCookieURL & "userid") & ")</b></font></td>" & vbNewLine & _
				"                <td> "
	else 
		if strAuthType = "db" then 
			Response.Write	"<b>" & ChkString(strDBNTUserName, "display") & "</b></font></td>" & vbNewLine & _
					"                <td>"
			if strGfxButtons = "1" then
				Response.Write	"<input src=""" & strImageUrl & "logout_box_button.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 & _
			"            </table>" & vbNewLine & _
			"          </td>" & vbNewLine & _
			"        </tr>" & vbNewLine
	if (mlev = 4) or (lcase(strNoCookies) = "1") then
		Response.Write	"        <tr>" & vbNewLine & _
				"          <td align=""center""><font face=""" & strDefaultFontFace & """ size=""" & strFooterFontSize & """><a href=""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=""admin_accounts_pending.asp""" & dWStatus("(" & User_Count & ") Member(s) awaiting approval") & " tabindex=""-1"">(" & User_Count & ") Member(s) awaiting approval</a>")
		Response.Write	"<br /><br /></font></td>" & vbNewLine & _
				"        </tr>" & vbNewLine
	end if
	Response.Write	"        </form>" & vbNewLine
end if
Response.Write	"      </table>" & vbNewLine & _
		"    </td>" & vbNewLine & _
		"  </tr>" & vbNewLine & _
		"</table>" & vbNewLine & _
		"<table align=""center"" border=""0"" cellPadding=""0"" cellSpacing=""0"" width=""95%"">" & vbNewLine

%>
<!--#INCLUDE FILE="alert_members.asp" -->
<%
%>
<!--#INCLUDE FILE="navigation_bar.asp" -->
<%
%>

Jan
===========
FR Portal Forums | Active Users 4.0.20 Mod

Edited by - masterao on 10 September 2003 09:37:28
Go to Top of Page

Ryan
Average Member

USA
858 Posts

Posted - 10 September 2003 :  11:28:42  Show Profile  Visit Ryan's Homepage
Thanks will try when I get on my computer which has my forum files.

The Poultry Link - "Serving the best of the fancy with the best of the web"
Forum Setup Help
Go to Top of Page

Ryan
Average Member

USA
858 Posts

Posted - 10 September 2003 :  17:46:03  Show Profile  Visit Ryan's Homepage
ouch. Nope sorry that was not it. It screwed it up terrible. It pushed everything over to the left of the screen cut off the footer and made a big black bar at the top.

The Poultry Link - "Serving the best of the fancy with the best of the web"
Forum Setup Help
Go to Top of Page

Roland
Advanced Member

Netherlands
9335 Posts

Posted - 10 September 2003 :  17:54:52  Show Profile
did you remove that TXT file, or is your server really slow at the moment?
Okay, well despite the fact that it takes ages to load the pages for me, I don't see any problems in the header part of your pages... Maybe I'm missing something, or you've found the solution

Edited by - Roland on 10 September 2003 18:01:43
Go to Top of Page

Ryan
Average Member

USA
858 Posts

Posted - 10 September 2003 :  17:57:30  Show Profile  Visit Ryan's Homepage
sorry FrutZle seemed to go really slow. Any I had to remake the file because I forgot to make a backup and I fixed it in the process.

The Poultry Link - "Serving the best of the fancy with the best of the web"
Forum Setup Help
Go to Top of Page

Roland
Advanced Member

Netherlands
9335 Posts

Posted - 10 September 2003 :  18:02:25  Show Profile
Glad to hear you fixed it... I was wondering where I should look to find the problem
Go to Top of Page

masterao
Senior Member

Sweden
1678 Posts

Posted - 10 September 2003 :  19:41:52  Show Profile  Visit masterao's Homepage
Im glad you got it fixed, as it seemed to be something else missing in addition to the login/logout display from your old inc_header.asp.

Jan
===========
FR Portal Forums | Active Users 4.0.20 Mod
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.42 seconds. Powered By: Snitz Forums 2000 Version 3.4.07