Parse an xml on the client side computer

P

Paul

I have only been doing ASP for 2 days now so I am learning as I go. I
am trying to paser through a xml document that is on the clients
computer.

I am using the XMLDOM object. The problem is that the path that I
supply using <input type="file" name="mFile"> is always looking to the
server's hard drive instead of the clients computer. How do I make the
XMLDOm object load the xml file from the clients computer.

Here is my code so Far

<%
Sub loadXml
dim doc
dim myPath

set doc = CreateObject("MSXML2.DOMDocument.3.0")
doc.resolveExternals = False
doc.validateOnParse = False
doc.async = false

myPath=cstr(Request.Form("mFile"))
doc.load myPath
'This is just so that I can make sure the file was loaded
Response.Write doc.xml
end sub

%>

<html>
<META name=VI60_defaultClientScript content=VBScript>
<body>
<form name="uploadMatt">
<input type="file" name="mFile">
<input onmousedown="<%loadXml%>" name="Submit" type="image"
src="images/login_btn.gif" width="73" height="22" border="0"
value="Enter">
</form>
<body>
</html>
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,999
Messages
2,570,243
Members
46,836
Latest member
login dogas

Latest Threads

Top