I need to be able to grab specific files (only text files) using the tag, hosted on SVN server. The user would type in their username and password as well as the name of the file like this:
Username: John
Password: *****
Filename: mySite.html
this is the section I have with the form:
<form id="loginForm" action="requestFile()" method="post">
<div id="loginWindow">
<p class="signInText">Username</p>
<input type="text" name="username" id="username" required="required" />
<p class="signInText">Password</p>
<input type="password" name="password" id="password" required="required" />
<p class="signInText">File Name</p>
<input type="text" name="filename" id="filename" required="required" />
<input type="submit" value="Ok" id="submit" />
</div>
</form>
Once the user clicks 'OK', the website will request the file from the server and copy the file's text contents into a textarea on the same page. The user can then work on their file and later click a 'Save' button to copy the contents back to the server (probably by replacing the original file). The 'Save' functionality is something I'll think of later, but I need to establish a connection to the server and request and receive the proper files.
The server can be accessed via a website which will have an authentication popup to ask for username and password, after which it will display a list of the contents at that location. So for example wwww.myWebServerLocation.com:8080/svn/Folder/file.html
will request a username and password and then display the contents of the file in the browser. I just need to get these contents into my textarea using .
EDIT: I have not implemented the 'requestFile()' function. That's what I need a little direction in implementing.