HEX
Server: Microsoft-IIS/10.0
System: Windows NT ITPWINWEBSVR22 10.0 build 20348 (Windows Server 2022) AMD64
User: www.conferencesearch.co.uk (0)
PHP: 8.3.30
Disabled: NONE
Upload Files
File: D:/web/homefly/vsadmin/inc/incadmin.asp
<%
'This code is copyright (c) Internet Business Solutions SL, all rights reserved.
'The contents of this file are protect under law as the intellectual property
'of Internet Business Solutions SL. Any use, reproduction, disclosure or copying
'of any kind without the express and written permission of Internet Business 
'Solutions SL is forbidden.
'Author: Vince Reid, vince@virtualred.net
Dim sSQL,rs,alldata,shipType,storeVersion,success,cnn,adoversion,errtext
success=0
Set rs = Server.CreateObject("ADODB.RecordSet")
Set cnn=Server.CreateObject("ADODB.Connection")
cnn.open sDSN
adoversion = cnn.Version
if adoversion < 2.5 then
	errtext = errtext & "Your ADO version is less than that required. (2.5).<br>You can update this at <a href='http://www.microsoft.com/data/'>http://www.microsoft.com/data/</a><br>" & vbCrLf
	success = -1
end if
on error resume next
sSQL = "UPDATE admin SET adminID=1 WHERE adminID=1"
cnn.Execute(sSQL)
if err.number<>0 then
	errtext = errtext & "Your database is not writeable. This probably means you just need to set the permissions on the directory the database is in to allow writing.<BR>Your host can help you with this.<br>" & vbCrLf
	success = -1
end if
on error goto 0
if Session("loggedon") <> "virtualstore" AND Trim(request.cookies("WRITECKL"))<>"" then
	sSQL="SELECT adminID FROM admin WHERE adminUser='" & Replace(request.cookies("WRITECKL"),"'","''") & "' AND adminPassword='" & Replace(request.cookies("WRITECKP"),"'","''") & "'"
	rs.Open sSQL,cnn,0,1
	if NOT (rs.EOF OR rs.BOF) then
		Session("loggedon") = "virtualstore"
	else
		success=2
	end if
	rs.Close
end if
if Session("loggedon") <> "virtualstore" AND success<>2 then response.end
sSQL = "SELECT adminShipping,adminVersion,adminUser,adminPassword FROM admin WHERE adminID=1"
rs.Open sSQL,cnn,0,1
shipType = Int(rs("adminShipping"))
storeVersion = rs("adminVersion")
adminUser = rs("adminUser")
adminPassword = rs("adminPassword")
rs.Close
cnn.Close
if Trim(request.querystring("writeck"))="yes" then
	response.write "<script src='savecookie.asp?WRITECKL=" & adminUser & "&WRITECKP=" & adminPassword & "'></script>"
	response.write "<meta http-equiv=""Refresh"" content=""3; URL=admin.asp"">"
	success=1
elseif Trim(request.querystring("writeck"))="no" then
	response.write "<script src='savecookie.asp?DELCK=yes'></script>"
	response.write "<meta http-equiv=""Refresh"" content=""3; URL=admin.asp"">"
	success=1
end if
%>
      <table border="0" cellspacing="0" cellpadding="0" width="100%" bgcolor="" align="center">
        <tr> 
          <td width="100%">
            <table width="100%" border="0" cellspacing="0" cellpadding="3" bgcolor="">
<% if success < 0 then %>
			  <tr> 
			    <td colspan="2"> 
				  <p><font size="2" color="#DD0000"><b>Before you start there are a couple of things 
				  you need to sort out.</b></font> <br>
				  <%=errtext%></p>
			    </td>
			  </tr>
<% end if %>
<% if success=1 then %>
			  <tr> 
				<td colspan="2" width="100%" align="center"><p>&nbsp;</p><p>&nbsp;</p>
				  <p><b>Operation Successful !</b></p><p>&nbsp;</p>
				  <p><font size="1">You will now be forwarded automatically to the admin home page. If that does not happen automatically, 
				  please <a href="admin.asp">click here</a>.</font></td>
			  </tr>
<% elseif success=2 then %>
			  <tr> 
				<td colspan="2" width="100%" align="center"><p>&nbsp;</p><p>&nbsp;</p>
				  <p><b>Operation Failed !</b></p><p>&nbsp;</p>
				  <p>It seems you have a corrupt cookie or have changed your login. Please <a href="login.asp">click here</a> to login, delete your cookie and set it again.</p></td>
			  </tr>
<% else %>
			  <tr> 
                <td colspan="2" width="100%" align="center"><b>Please choose from the list below.</b><br><font size="1">(Version: <%=storeVersion%>)</font><br>&nbsp;
                </td>
			  </tr>
			  <tr> 
				<td valign="top" width="50%" align="left">&nbsp;&nbsp;<a href="adminorders.asp"><b>View 
                        Orders </b></a><br>
                        &nbsp;
                </td>
				<td valign="top" width="50%"><a href="<%=helpbaseurl%>help.asp#orders" target="ttshelp"><b>Online Help</b></a></td>
			  </tr>
			  <tr> 
				<td width="50%" align="left">&nbsp;&nbsp;<a href="adminlogin.asp"><b>Change 
                        username / password </b></a> </td>
				<td width="50%"><a href="<%=helpbaseurl%>help.asp#uname" target="ttshelp"><b>Online Help</b></a></td>
			  </tr>
              <tr> 
				<td width="50%" align="left">&nbsp;&nbsp;<a href="adminmain.asp"><b>Edit 
                        admin settings </b></a> </td>
				<td width="50%"><a href="<%=helpbaseurl%>help.asp#admin" target="ttshelp"><b>Online Help</b></a></td>
			  </tr>
			  <tr> 
				<td width="50%" align="left">&nbsp;&nbsp;<a href="adminaffil.asp"><b>View 
                        affiliate partners report </b></a> </td>
				<td width="50%"><a href="<%=helpbaseurl%>help.asp#affiliate" target="ttshelp"><b>Online Help</b></a></td>
			  </tr>
			  <tr> 
				<td width="50%" align="left">&nbsp;&nbsp;<a href="admintopcats.asp"><b>Edit 
                        top categories </b></a> </td>
				<td width="50%"><a href="<%=helpbaseurl%>help.asp#topcats" target="ttshelp"><b>Online Help</b></a></td>
			  </tr>
			  <tr> 
				<td width="50%" align="left">&nbsp;&nbsp;<a href="admincats.asp"><b>Edit 
                        categories </b></a> </td>
				<td width="50%"><a href="<%=helpbaseurl%>help.asp#cats" target="ttshelp"><b>Online Help</b></a></td>
			  </tr>
			  <tr> 
				<td width="50%" align="left">&nbsp;&nbsp;<a href="adminprods.asp"><b>Edit 
                        products </b></a> </td>
				<td width="50%"><a href="<%=helpbaseurl%>help.asp#prods" target="ttshelp"><b>Online Help</b></a></td>
			  </tr>
			  <tr> 
				<td width="50%" align="left">&nbsp;&nbsp;<a href="adminprodopts.asp"><b>Edit 
                        product options </b></a> </td>
				<td width="50%"><a href="<%=helpbaseurl%>help.asp#prodopt" target="ttshelp"><b>Online Help</b></a></td>
			  </tr>
			  <tr> 
				<td width="50%" align="left">&nbsp;&nbsp;<a href="admindiscounts.asp"><b>Discounts 
                        and coupons </b></a> </td>
				<td width="50%"><a href="<%=helpbaseurl%>help.asp#discounts" target="ttshelp"><b>Online Help</b></a></td>
			  </tr>
			  <tr> 
				<td width="50%" align="left">&nbsp;&nbsp;<a href="adminstate.asp"><b>Edit 
                        States </b></a> </td>
				<td width="50%"><a href="<%=helpbaseurl%>help.asp#state" target="ttshelp"><b>Online Help</b></a></td>
			  </tr>
			  <tr> 
				<td width="50%" align="left">&nbsp;&nbsp;<a href="admincountry.asp"><b>Edit 
                        Countries </b></a> </td>
				<td width="50%"><a href="<%=helpbaseurl%>help.asp#country" target="ttshelp"><b>Online Help</b></a></td>
			  </tr>
<%	if shipType=2 OR shipType=5 then %>
			  <tr> 
				<td width="50%" align="left">&nbsp;&nbsp;<a href="adminzones.asp"><b>Edit 
                        Postal Zones </b></a> </td>
				<td width="50%"><a href="<%=helpbaseurl%>help.asp#pzone" target="ttshelp"><b>Online Help</b></a></td>
			  </tr>
<%	elseif shipType=3 OR shipType=4 then %>
			  <tr> 
				<td width="50%" align="left">&nbsp;&nbsp;<a href="adminuspsmeths.asp"><b>Edit 
                        U<%if shipType=3 then response.write "S"%>PS Shipping Methods </b></a> </td>
				<td width="50%"><a href="<%=helpbaseurl%>help.asp#shipmeth" target="ttshelp"><b>Online Help</b></a></td>
			  </tr>
<%	end if %>
			  <tr> 
                <td width="50%" align="left">&nbsp;&nbsp;<a href="adminpayprov.asp"><b>Edit Payment Providers </b></a></td>
				<td width="50%"><a href="<%=helpbaseurl%>help.asp#payprov" target="ttshelp"><b>Online Help</b></a></td>
			  </tr>
			  <tr> 
                <td width="50%" align="left">&nbsp;&nbsp;<a href="adminupslicense.asp"><b>Register with UPS </b></a></td>
				<td width="50%"><a href="<%=helpbaseurl%>help.asp#upsreg" target="ttshelp"><b>Online Help</b></a></td>
			  </tr>
			  <tr> 
				<td colspan="2" width="100%" align="left">&nbsp;&nbsp;<a href="logout.asp"><b>Logout
                        </b></a> </td>
			  </tr>
			  <tr> 
				<td colspan="2" width="100%" align="center"><p>&nbsp;</p>
				<%	if Trim(request.cookies("WRITECKL"))<>"" then %>
					<a href="admin.asp?writeck=no">Click here to delete the cookie stored on this PC.</a><br>
				<%	else %>
					<a href="admin.asp?writeck=yes">Click here to write a cookie to remember your username and password.</a><br>
				<%	end if %>
					<font size="1">(This is not recommended if you are on a shared or public computer)</font></td>
			  </tr>
<% end if %>
			  <tr> 
                <td colspan="2" width="100%" align="left"><img src="../images/clearpixel.gif" width="350" height="5">
                </td>
			  </tr>
            </table>
          </td>
        </tr>
      </table>