(I'm new forgive me)
I want to have a webpage that asks a user to type in a file name i.e.: text.txt then press a button that will then go to a directory i.e.: c:\textfiles then display the text file they named in a text area.
this will load the txt files if they reside in the same location as the html thats calling them.
else add the path like this
window.open("files/"+txtfile+".txt")
<html>
<head>
<title>load file demo</title>
<script language=javascript>
function LoadFile()
{
var txtfile =document.filemenu.file.value;
window.open(txtfile+".txt")
}
</script>
Use a Program like Dreamweaver to create a java effect you want and then study the code it produces. Try changing some of the values etc. If you are stuck Google the command word.
Hope this helps
Keith
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.