⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 upload.asp

📁 Web Development Upload ASP Web Development Upload ASP Web Development Upload ASP
💻 ASP
字号:
<!--#include file="Includes/_incFunctions.asp"-->
<!--#include file="Includes/_incUpload.asp"-->

<%	'do job here
dim Name, Email

'********************************************************
'[start section to be evaluated. Remove that on deployment version]
timeThen = milliDif()
'********************************************************

'********************************************************
'make the upload
Upload
'********************************************************
response.write "Upload Done<br/>"
'Response.end

'*********************************************************
'receive the rest of fields
			Name		= cstr ( myRequest("Name") )
			Email		= cstr ( myRequest("Email") )
'*********************************************************

'the directory path where to upload the file is get from _incFunctions.asp		
'response.write sPathData & GetName & "<br/>"
'response.end

'********************************************************
'save the file on the HDD
SaveFile  sPathData, GetName 
'********************************************************
response.write "Save Done<br>"
'response.end

errMsg	= "ok"

'********************************************************
'[end section to be evaluated. Remove that on deployment version]
timeNow = milliDif()
elapsed	=timeNow-timeThen
msg		="<br>Process time in ms: " & elapsed & "<br>" & elapsedpretty(elapsed)
'response.write msg
'Response.end
'********************************************************

' IIS tends to hang if you don't explicitly return SOMETHING.
' So, you should redirect to another page or simply thank them right here...
'the sURLredirect (asp redirect page name) is get from _incFunctions.asp
			
			
'FIRST WAY TO REDIRECT THE RESULTS. 
	'In fact is a post to sURLredirect asp page.
	'Comment the fallowing line if you want the SECOND way of redirect.
	response.redirect sURLredirect & "?FileName=" & GetName & "&TimeElapsed=" & msg & "&Name=" & Name & "&Email=" & Email & "&errMsg=" & errMsg				
%>


<form method="post" name="frmSubmit">
<input type="hidden" name="FileName"value="">
<input type="hidden" name="Name"	value="">
<input type="hidden" name="Email"	value="">
<input type="hidden" name="errMsg"	value="">
</form>
<script LANGUAGE="javascript">
<!--

//SECOND WAY TO REDIRECT THE RESULTS. 
function frmSubmit(sAction, sFileName, sName, sEmail, errMsg)
{	
	document.frmSubmit.action			= sAction;
	document.frmSubmit.FileName.value	= sFileName;
	document.frmSubmit.Name.value		= sName;
	document.frmSubmit.Email.value		= sEmail;
	document.frmSubmit.errMsg.value		= errMsg;
	document.frmSubmit.submit();
}

	//In fact is a post to sURLredirect asp page.
	//Comment the fallowing line if you want the FIRST way of redirect.
	frmSubmit("<%=sURLredirect%>", "<%=GetName %>", "<%=Name %>", "<%=Email%>", "<%=errMsg %>")
-->
</script>


⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -