Download File
(→Example) |
|||
Line 12: | Line 12: | ||
− | == Example == | + | == Example 1 == |
<pre> | <pre> | ||
Line 24: | Line 24: | ||
[[File:downloadfile.jpg]] | [[File:downloadfile.jpg]] | ||
+ | |||
+ | |||
+ | == Example 2: XML Files == | ||
+ | |||
+ | Sometimes, you might encounter an xml file on a webpage that will be difficult to scrape. | ||
+ | |||
+ | Since it is a file, download file can help bypass the scraping method and grab everything you need to a file. | ||
+ | |||
+ | <pre> | ||
+ | navigate("http://www.npr.org/rss/rss.php?id=1057","Wait") | ||
+ | wait(3) | ||
+ | download file("http://www.npr.org/rss/rss.php?id=1057","C:\\Users\\Documents\\doc text.txt") | ||
+ | |||
+ | </pre> |
Revision as of 15:50, 16 November 2015
This command will download a file from the url location you provide that has a file for downloading.
Download File is a Browser Command.
Download URL: Where the url for the file being downloaded should go.
Save As: Determines where the downloaded file will be downloaded to in your system folders.
The file is given a name and a location is selected through the save as dialog that appears after clicking the browse button.
The command also accepts variables and functions such as $next list item, $list item, $random list item, $previous list item, and $table cell for the folder location and the download url.
Example 1
download file("http://ubotstudio.com/files/text%20files.txt", "C:\\Users\\UBook\\Documents\\bluedays.txt")
Running the command will download the file at the url to the specified location in your folder.
Example 2: XML Files
Sometimes, you might encounter an xml file on a webpage that will be difficult to scrape.
Since it is a file, download file can help bypass the scraping method and grab everything you need to a file.
navigate("http://www.npr.org/rss/rss.php?id=1057","Wait") wait(3) download file("http://www.npr.org/rss/rss.php?id=1057","C:\\Users\\Documents\\doc text.txt")