How do I bulk download a background image for Bing before more than 20 days?

Source: Internet
Author: User

Tool Preparation

wget ( click to download )

Batch command ( click to download )

User interface:http://area.sinaapp.com/bingImg?daysAgo=1(1 for days)

Implementation steps

1. Open Notepad and copy and paste the following code, new -Save as , file type select " All Files ", file name: Download bing background image. Bat (click Download), save on desktop.

@echo offset var=%cd%MD bingimg&cd bingimg for in Do%var%\ wget http://area.sinaapp.com/bingImg?daysAgo=%%i

2. Unzip the downloaded files to the Bing background image. Bat in the same level directory (here all on the desktop).

3. Double-click the Bing background image. Bat.

4, after downloading, the window will automatically exit, at this time the desktop will be more than a bingimg folder.

5. Download the result (23 photos of the history picture).

Code explanation

@echo offset var=%cd%MD bingimg&cd bingimg for in Do%var%\ wget http://area.sinaapp.com/bingImg?daysAgo=%%i

@echo off from the beginning of the bank to turn off Echo.

Set var=%cd% Set var: declares a variable var. %cd%: represents the absolute address of the directory where the current file is located, meaning that the address is passed to Var.

MD bingimg& CD bingimg create (MD)bingimg folder, and (&) Enter (CD) Bingimg folder

For/L %%i in (0,1,30 ) do%var%\wget http://area.sinaapp.com/bingImg?daysAgo=%%i

  1. for Batch loop directives.
  2. The/ l for parameter, which handles the sequence of numbers. (Note: l is lowercase, although it is nonsense, but still a reminder, avoid being considered as "1" or "|" UP).
  3. %%i A variable that passes a parameter.
  4. in the picture, his back is the loop parameter.
  5. (0,1,30) loop parameter, which in turn represents start from zero , self-increment is 1 , over 30 loops end.
  6. Do Just write, anyway, back. is the command that needs to be executed.
  7. The absolute address of the directory where the %var%\ wget program is located, which is the value%cd% passed to Var. (Note: "\" must not be less.) Wordy, for example: C:\Users\Youge\desktop\wget.exe, "\" is wget.exe after the "\", if you go, it will become c:\Users\Youge\ Desktopwget.exe, this path is invalid at this time, sorry wordy.
  8. wget http://area.sinaapp.com/bingImg?daysAgo=%%i wget's download instruction, followed by the URL, where "%%i " is the number of days.

For the for instruction does not understand can be entered in cmd:for/? (Here's another trick: if you don't know the instructions in DOS, we can add "/?" to the instructions, so we can find out the instructions related to help)

How do I bulk download background images for Bing before more than 20 days?

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.