---
title: Bulk Image Downloads for VOR
description: Image download
image: https://internal.netfluencecorp.com/hubfs/7800x4320.svg
---

Netfluence Corporation

- <https://www.facebook.com/netfluence/>
- <https://www.linkedin.com/company/7590040/>

[![logo-3](https://internal.netfluencecorp.com/hubfs/logo-3.svg "logo-3")](https://netfluencecorp.com/)

- SERVICES
- ABOUT US
- NEWS
- CONTACT US

![](https://internal.netfluencecorp.com/hubfs/7800x4320.svg)

## NETFLUENCE CORPORATION

# Knowledge Base

[Knowledge Base](https://internal.netfluencecorp.com/)  /  B. Development & Supporting Documentation  /  Bulk Image Downloads for VOR

# Bulk Image Downloads for VOR

Published: Nov 21, 2019 3:12:51 AM

## Introduction

This document highlights the steps to bulk download all Images requested by VOR. The script uses a CSV as input and download an image per row and then group them according to their brand names.

Folder structure:

```
/downloads/downloads/brandA/image1.jpg/downloads/brandA/image2.jpg/downloads/brandB/image1.jpg/downloads/brandB/image2.jpg
```

 

## CSV Format

The Script expects two required column for it to work. "Brand", "Image URL" but you can add any number of columns.

example CSV:

```
Brand,Part Name,Part Number,Image URL,Image OrderDV8 Offroad,Front bumper,FBCS1-01,https://cdn.shopify.com/s/files/1/1118/3812/products/FBCS1-01_Chevrolet_Silverado_1500_front_bumper_DV8_1024x1024.jpg,1DV8 Offroad,Front bumper,FBCS1-01,https://cdn.shopify.com/s/files/1/1118/3812/products/DSC_0292b_Medium_1024x1024.jpg,3DV8 Offroad,Front bumper,FBCS1-02,https://cdn.shopify.com/s/files/1/1118/3812/products/FBCS1-02_1024x1024.jpg,1DV8 Offroad,Rear bumper,RBCS1-01,https://cdn.shopify.com/s/files/1/1118/3812/products/DSC_0298b_Medium_1024x1024.jpg,2
```

 

## Steps to download images

### 1. Upload CSV to Server

 Open your terminal and upload the csv file to the server

```
> scp /path/to/request.csv root@tools.netfluence.io:
```

### 2. Connect to the server and create a folder to collect all files

```
> ssh root@tools.netfluence.io> mkdir -p /root/image_crawler/$(date +%Y%m%d)> cd /root/vor> time php public/index.php /download-images GET "input=/root/dv8.csv&folder=/root/image_crawler/$(date +%Y%m%d)"
```

### 3. Compile all files and folder to a single archive

Collect all files and folder and archive them to a single file for easier download

```
> cd /root/image_crawler/> tar -zcvf $(date +%Y%m%d).tgz $(date +%Y%m%d)
```

### 4. Prepare for Download

This step will give us the URL of the archived images for download

```
> mv /root/image_crawler/$(date +%Y%m%d).tgz /var/www/tools/public/download/> echo "Download available at https://tools.netfluence.io/download/$(date +%Y%m%d).tgz"
```

 

### Downloading failed download:

There are cases that the Image URL cannot be downloaded, whether the URL is 404 or the server did not allow connection. After execution, the script will output a CSV that contains all rows that was not downloaded.

![Screenshot 2019-11-21 at 3.49.54 PM](https://internal.netfluencecorp.com/hs-fs/hubfs/Screenshot%202019-11-21%20at%203.49.54%20PM.png?width=1706&name=Screenshot%202019-11-21%20at%203.49.54%20PM.png)

To download the failed download file, follow the steps below

```
> mv /file/path/of/faileddownload.csv /var/www/tools/publicThen you can download the file by visiting this URLhttps://tools.netfluence.io/download/faileddownload.csv
```

 

[<< Previous Post](https://internal.netfluencecorp.com/vpb-lite) [Next post >>](https://internal.netfluencecorp.com/ticketing-system-sow)

### Recent Articles

-  [Practial Exercise](https://internal.netfluencecorp.com/blog-post-practial-exrcisee)
-  [Integromat as CRM Extension End point](https://internal.netfluencecorp.com/integromat-as-crm-extension-end-point)
-  [Cloudbakers Header Navigation - How to change the link or redirection of a menu item in the Global Header Navigation Menu](https://internal.netfluencecorp.com/cloudbakers-header-navigation-how-to-change-the-url-of-menu-item-in-the-global-header-navigation-menu)
-  [For CSS](https://internal.netfluencecorp.com/test-title)
-  [VPB Module | Heading \[DRAFT\]](https://internal.netfluencecorp.com/vpb/module-heading)

![logo](https://internal.netfluencecorp.com/hubfs/logo.svg "logo")

### Company Newsletter:

Please Enter The Password:

Submit

Cancel

```json
{
  "@context" : "http://schema.org",
  "@type" : "Corporation",
  "address" : {
    "@type" : "PostalAddress",
    "addressCountry" : "United States",
    "addressLocality" : "North Bay Village",
    "postalCode" : "33141",
    "streetAddress" : "8000 West Drive #814"
  },
  "description" : "Netfluence helps marketing and sales teams execute the technical details of multi-touch campaigns, including custom templates, automation triggers, CRM workflows, sales processes, analytics tracking, and more.",
  "image" : "https://cdn2.hubspot.net/hubfs/487227/netfluence_technical_support_for_marketers_final%20(1200x1200).png",
  "logo" : "https://cdn2.hubspot.net/hubfs/487227/netfluence-hubspot-development-logo2.png",
  "name" : "Netfluence",
  "sameAs" : [ "https://www.facebook.com/netfluence/" ],
  "telephone" : "+1954-637-8374",
  "url" : "https://www.netfluencecorp.com/"
}
```