0

I use the following code:

<td width='200'><input type='text' name='textbox' value='text of .txt file' id='myInput'>

How can I input the contents of a text box from the contents of a text file? Patch text file: C:/textfile.txt

2019meganz
  • 21
  • 3
  • This is more or less not possible. You could look into having the user submit a file: https://developer.mozilla.org/en-US/docs/Web/API/File/Using_files_from_web_applications or request file system access: https://developer.mozilla.org/en-US/docs/Web/API/FileSystem – Sheraff Aug 06 '20 at 21:35
  • Look https://stackoverflow.com/questions/23331546/how-to-use-javascript-to-read-local-text-file-and-read-line-by-line – Sascha Aug 06 '20 at 21:43
  • Scenario. You visit my website, I read your root non-sandboxed level files into a hidden input on a form you submit for whatever reason and attach them to the payload I receive without your knowledge. How would you feel about that? ;) – Chris W. Aug 06 '20 at 21:50

0 Answers0