Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Beginner
16 Views

Image download

 

In listview, i am displaying image and link  <a href="'+imageURL+'" download>Save</a>  to download image ,

On click of save in emulator image is getting downloaded, After installing in phone the link is not responding and the image is not getting downloaded. 

Below is the code for reference:

el = document.getElementById('thelist');

 li = document.createElement('li');

 li.innerHTML='<br/><center>'+

  '<div id="divContainerID" class="divContainer">'+
 '<div class="divTitle">'+feed.items.title+'</div>'+
  '<div class="divImg"><img src="'+feed.items.media.m+'" height="auto"  width="100%" /></div>'+
    '</div><div class="divFooter"> <div class="divFooter"><a href="'+feed.items.media.m+'" download>Save</a></div><br/></div><br/></center>'
 el.appendChild(li, el.childNodes[0]);

Tags (2)
0 Kudos
7 Replies
Highlighted
Valued Contributor I
16 Views

Hi,

Could you give an example of the final url to download the image? What is placed in feed.items.media.m when running?

Regards,

Diego

0 Kudos
Highlighted
Beginner
16 Views

Hi, 

Here it is : http://farm8.staticflickr.com/7666/26760451752_84ed224ca1_m.jpg

The url differs for every li in listview

Regards , 

M

 

0 Kudos
Highlighted
Valued Contributor I
16 Views

Did you configure the whitelisting? Projects / Build Settings / Whitelist

0 Kudos
Highlighted
Beginner
16 Views

Hi, 

What should I configure? I have not touched this section . 

What should I configure for url like : http://farm8.staticflickr.com/7666/26760451752_84ed224ca1_m.jpg

 

Attached is the screen shot for reference

 

 

0 Kudos
Highlighted
16 Views

Mallikarjun -- follow the instructions and links in the info icons -- the (i) icons...

0 Kudos
Highlighted
Beginner
16 Views

 

Sorry Paul, I didn't get it. Please brief it

0 Kudos
Highlighted
16 Views

0 Kudos