
September 3rd, 2003, 04:51 AM
|
 |
Contributing User
|
|
Join Date: Aug 2003
Posts: 43
Time spent in forums: 3 h 24 m 40 sec
Reputation Power: 6
|
|
|
Code looks fine, but get a blank page
These code is suppose to delete files from a database and print how many files where deleted.
PHP Code:
<%@LANGUAGE="VBSCRIPT" CODEPAGE="1252"%>
<html>
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<body>
<%
'DELETE FILE FROM SERVER
dim myfile, fs
myfile = request.form("myfile")
Set fs=Server.CreateObject("Scripting.FileSystemObject")
if fs.FileExists(myfile) then
fs.DeleteFile(myfile), true
end if
set fs=nothing
docID = request.form("docID")
myDSN = "DSN=filemanager;uid=;pwd="
mySQL = "DELETE FROM docs WHERE docID=" & docID
Set Conn = Server.CreateObject("ADODB.Connection")
conn.open myDSN
Conn.Execute mySQL,howmany
response.write "The statement " & mySQL & "<b> deleted " & howmany & " records</b><br>"
Conn.Close
set conn=nothing
%>
<h1>OK</h1>
<% = myfile %>
</body>
</html>
I don't get any error message, but get a blank page and if I move out of the browser window my mouse pointer becomes a clock indicating something is being processed.
_________________
marCello70
|