HTML5 Download Attribute

190 views
Skip to first unread message

Durga Prasad

unread,
May 28, 2016, 4:37:00 AM5/28/16
to DroidScript
Hi ,

I recently come to know in html5 there is a default attribute "Download" in href's to download the specific file. when i tried this, its working in normal browser, but not inside the Droidscript app. Do i have to do anything special to make it work inside droidscript. 

I am aware there is Droidscript downloader. But when i compare interms of simplicity I prefer this attribute does the job without much complicated code.

Any help appreciated.

<html>
<head>
</head>
<body>
<a href="http://www.example.com/filename.jpg" download>
<img src="http://www.example.com/filename.jpg">
</a>
</body>
</html>

nikhil baby

unread,
May 28, 2016, 4:43:42 AM5/28/16
to DroidScript
i don't think D.S can do this!

Coming version of D.S can use System downloader!

Dave Smart

unread,
May 28, 2016, 4:57:11 AM5/28/16
to DroidScript
Hi Guys,

Looks like this is pretty easy to implement.  


do we want a new 'download' option, or shall we just enable it by default?

Durga Prasad

unread,
May 28, 2016, 5:31:58 AM5/28/16
to DroidScript
Hi Dave,

Whichever is easy to implement that will be great. So when can we expect this facility in droidscript ?

Regards,
Durga

Dave Smart

unread,
May 28, 2016, 6:06:58 AM5/28/16
to DroidScript
Just testing it right now :)  So next beta release (if I it works ok).

Durga Prasad

unread,
May 28, 2016, 6:18:07 AM5/28/16
to DroidScript
Great ! Thanks !

Dave Smart

unread,
May 28, 2016, 7:44:24 AM5/28/16
to DroidScript
Message has been deleted

Durga Prasad

unread,
May 28, 2016, 8:04:10 AM5/28/16
to DroidScript
Okay.
I tried to use the droidscript downloader. For that I am passing the file name (which needs to be downloaded) to my main file from iframe page using a function.

But unfortunately whenever I do I got a protocol error (attached screenshot).

I am not sure on this part.

Also can we use the downloader as a separate js file apart from the main html so that I can call it whenever required?

Is that possible?

Screenshot_2016-05-28-17-24-56-1.jpg
Reply all
Reply to author
Forward
0 new messages