Hi guys, our company's website has this file upload button for uploading multiple images. How can I create a script that automatically selects the images then uploads them? I already know the path of each images on the client's PC. I just don't want to script a click on the file upload button since I get a headache trying to make that work. My current goal is to script it in Autoit with something like:
$files1 = "C:\TeamBuilding\Team Games.jpg"
$files2 = "C:\TeamBuilding\Team Prayer.jpg"
$oIE.getelementbyid("file").upload $files1, $files2
Then after the image upload the form is submitted. Obviously the code above is a fantasy :D I just need the part to script uploading the images instead of clicking the upload button. My Autoit script will modify the innerHTML of this form to add the script for auto-upload. Is this doable?
Summary: Instead of clicking the "Upload File" button I want a script to upload certain .jpg files. Right now what I'm doing is manually clicking the "Upload File" button then selecting all the JPEG files. Somebody suggested a script that will click the upload button then types the path of each images but I already tried those, was a headache, I'm asking for a script in VB (since Autoit seem to be VBScript language). Once I get that script, what I will do is just modify the innerHTML of my company's site so instead of a plain <input type="file" name="file" multiple="">
it will automatically upload the pictures without having the user manually placed the pictures