access local file and display the content

M

MD

Is it possible to load the local xml file and display in the div?
Currently i tried the following source when i put it to web
always gives me error saying "access is denied"


<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<script language="JavaScript">
function LoadFiles(){

var getsrchResSize_url = document.getElementById('filename').value;
var dom = new ActiveXObject("Msxml2.DOMDocument");
dom.async = false;
dom.load( getsrchResSize_url );
alert( dom.xml );
}
</script>
<body>
<form id="files">
<input type=file id=filename >
<input type=button onClick="LoadFiles();">
</form>
</body>
</html>
 
V

VK

MD said:
Is it possible to load the local xml file and display in the div?
Currently i tried the following source when i put it to web
always gives me error saying "access is denied"

Would you prefer any web-page able to read/write your hard disk? In the
standard security environment you are not allowed to access local files.
 

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

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,582
Members
45,070
Latest member
BiogenixGummies

Latest Threads

Top