Tôi có một tệp bó trông như thế này, nó sẽ chụp ảnh trang web và cắt nó:
cd C:\users\***\Downloads\IECapt-2008-06-10
IECapt --delay=10000 --url=http://test.com/picture.swf?id=1 --out="C:\users\***\My Documents\picture.png"
cd C:\users\***\My Documents
convert picture.png -trim picture.png
ftp -s:place_img.txt
Tôi đã tự hỏi là có một cách mà tôi có thể thay đổi tập lệnh này để chấp nhận đầu vào của người dùng để thay thế URL và tên tệp bằng những gì người dùng nhập vào. Ví dụ: người dùng sẽ nhập URL và tên tệp và nó sẽ thay thế những thứ sau:
cd C:\users\***\Downloads\IECapt-2008-06-10
IECapt --delay=10000 --url=(((http://test.com/picture.swf?id=1))) --out="C:\users\***\My Documents\((picture)).png"
cd C:\users\***\My Documents
convert ((picture)).png -trim ((picture)).png
ftp -s:place_img.txt
(((URL được thay thế)))
((Tên tệp được thay thế))
Đây là tệp "place_picture.txt":
open test.com
username
pass
hash
bin
lcd c:\users\***\My Documents
cd public_html/test.com/test
put picture.png
bye