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)
 mod_db_setup is missing this code
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

shaggy073077
Starting Member

29 Posts

Posted - 25 April 2015 :  13:29:00  Show Profile  Send shaggy073077 an AOL message  Send shaggy073077 a Yahoo! Message  Reply with Quote
Hi all,

Maybe in the dotnet release the mod_db_setup files with will have this in the header of it. It's missing "All Forum--->Admin Section buttons/links right below the header.

Ok coders don't laugh.

Around/about line number 50-71 it'll show this:

if MemberID <> intAdminMemberID then
   Err_Msg = "<li>Only the Forum Admin can access this page</li>"

   Response.Write "<table align=""center"" width=""50%"" height=""50%"">" & vbNewLine & _
         "  <tr>" & vbNewLine & _
         "    <td>" & vbNewLine & _
         "    <br><br><p align=""center""><font face=""Verdana, Arial, Helvetica"" size=""3"" color=""#FF0000"">There has been a problem!</font></p>" & vbNewLine & _
         "      <table align=""center"" border=""0"">" & vbNewLine & _
         "        <tr>" & vbNewLine & _
         "          <td><font face=""Verdana, Arial, Helvetica"" size=""2"" color=""#FF0000""><ul>" & Err_Msg & "</ul></font></td>" & vbNewLine & _
         "        </tr>" & vbNewLine & _
         "      </table>" & vbNewLine & _
         "    <p align=""center"" valign=""middle""><font face=""Verdana, Arial, Helvetica"" size=""2""><a href=""JavaScript:history.go(-1)"">Go Back To Admin Section</a></font></p>" & vbNewLine & _
         "    <br><br></td>" & vbNewLine & _
         "  </tr>" & vbNewLine & _
         "</table>" & vbNewLine
Response.Write " <br></td>" & vbNewLine & _
" </tr>" & vbNewLine & _
"</table>" & vbNewLine
   writefooter
   Response.End
end if


Add below this below:

Response.Write " <table border=""0"" width=""100%"">" & vbNewLine & _
      "        <tr>" & vbNewLine & _
      "          <td width=""33%"" align=""left"" nowrap><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """>" & vbNewLine & _
      "          " & getCurrentIcon(strIconFolderOpen,"","align=""absmiddle""") & " <a href=""default.asp"">All Forums</a><br />" & vbNewLine & _
      "          " & getCurrentIcon(strIconBar,"","align=""absmiddle""") & getCurrentIcon(strIconFolderOpenTopic,"","align=""absmiddle""") & " <a href=""admin_home.asp"">Admin Section</a><br /></font></td>" & vbNewLine & _
      "        </tr>" & vbNewLine & _
      "      </table>" & vbNewLine


Snitz forum is missing the top part two links below the header. the "all forum" and "Admin Section" link on the top below the header. That's what this mod add is them links.

shaggy073077
Starting Member

29 Posts

Posted - 25 April 2015 :  13:31:16  Show Profile  Send shaggy073077 an AOL message  Send shaggy073077 a Yahoo! Message  Reply with Quote
I have also posted a code snippet some where's on here similar to this one except it adds code lines below where it says "Click here to go to the forum" you pretty much don't need that mod if your adding this one.
Go to Top of Page

Carefree
Advanced Member

Philippines
4207 Posts

Posted - 25 April 2015 :  15:44:14  Show Profile  Reply with Quote
You can clean all that up a bit.

"admin_mod_dbsetup.asp"


Look for the following lines (appx 35-63):

%>
<!--#include file="config.asp"-->
<%
if Session(strCookieURL & "Approval") <> "15916941253" then
	scriptname = split(request.servervariables("SCRIPT_NAME"),"/")
	Response.Redirect "admin_login.asp?target=" & scriptname(ubound(scriptname))
end if
%>
<!--#include file="inc_sha256.asp"-->
<!--#include file="inc_header.asp"-->
<%
if MemberID <> intAdminMemberID then
	Err_Msg = "<li>Only the Forum Admin can access this page</li>"

	Response.Write	"<table align=""center"" width=""50%"" height=""50%"">" & vbNewLine & _
			"  <tr>" & vbNewLine & _
			"    <td>" & vbNewLine & _
			"    <p align=""center""><font face=""Verdana, Arial, Helvetica"" size=""3"" color=""#FF0000"">There has been a problem!</font></p>" & vbNewLine & _
			"      <table align=""center"" border=""0"">" & vbNewLine & _
			"        <tr>" & vbNewLine & _
			"          <td><font face=""Verdana, Arial, Helvetica"" size=""2"" color=""#FF0000""><ul>" & Err_Msg & "</ul></font></td>" & vbNewLine & _
			"        </tr>" & vbNewLine & _
			"      </table>" & vbNewLine & _
			"    <p align=""center"" valign=""middle""><font face=""Verdana, Arial, Helvetica"" size=""2""><a href=""JavaScript:history.go(-1)"">Go Back To Admin Section</a></font></p>" & vbNewLine & _
			"    </td>" & vbNewLine & _
			"  </tr>" & vbNewLine & _
			"</table>" & vbNewLine
	Response.End
end if

Replace them with these:


%>
<!--#INCLUDE FILE="config.asp"-->
<!--#INCLUDE FILE="inc_sha256.asp"-->
<!--#INCLUDE FILE="inc_header.asp"-->
<%
If Session(strCookieURL & "Approval") <> "15916941253" Or (MemberID <> intAdminMemberID) Then
	scriptname = split(Request.ServerVariables("SCRIPT_NAME"),"/")
	Response.Redirect "admin_login.asp?target=" & scriptname(ubound(scriptname)) & "?" & Request.ServerVariables("Query_String")
End If
Response.Write	"<table border=""0"" width=""100%"">" & vbNewLine & _
	"	<tr>" & vbNewLine & _
	"		<td width=""33%"" align=""left"" nowrap><font face=""" & strDefaultFontFace & """ size=""" & strDefaultFontSize & """>" & vbNewLine & _
	"		" & getCurrentIcon(strIconFolder,"","align=""absmiddle""") & " <a href=""admin_home.asp"">Admin Section</a><br />" & vbNewLine & _
	"		" & getCurrentIcon(strIconBar,"","align=""absmiddle""") & getCurrentIcon(strIconFolderOpen,"","align=""absmiddle""") & " <a href=""default.asp"">All Forums</a><br />" & vbNewLine & _
	"		" & getCurrentIcon(strIconBlank,"","align=""absmiddle""") & getCurrentIcon(strIconBar,"","align=""absmiddle""") & getCurrentIcon(strIconFolderOpenTopic,"","align=""absmiddle""") & " <b>Database Modification</b><br /></font></td>" & vbNewLine & _
	"	</tr>" & vbNewLine & _
	"</table>" & vbNewLine & _
	"<br />" & vbNewLine


Edited by - Carefree on 25 April 2015 15:45:13
Go to Top of Page

shaggy073077
Starting Member

29 Posts

Posted - 26 April 2015 :  05:20:56  Show Profile  Send shaggy073077 an AOL message  Send shaggy073077 a Yahoo! Message  Reply with Quote
thanks carefree. I didn't know how far off I was. Them two links right below header is in every last file/link in admin_home but the db_setup files.

Edited by - shaggy073077 on 26 April 2015 05:21:40
Go to Top of Page

Carefree
Advanced Member

Philippines
4207 Posts

Posted - 27 April 2015 :  08:27:50  Show Profile  Reply with Quote
You were on the right track. Reason it could be streamlined was due to relocating the "include" files. By moving "inc_header.asp" up where I put it, you can now identify the member's ID (and use it to compare against the admin member ID). That lets us eliminate all of that secondary error trapping business.
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
Snitz Forums 2000 © 2000-2021 Snitz™ Communications Go To Top Of Page
This page was generated in 0.12 seconds. Powered By: Snitz Forums 2000 Version 3.4.07