Download a file using Download API

An example showing how to download a file using Download API using Tizen 2.3.
var request = new tizen.DownloadRequest(
    'http://download.tizen.org/tools/README.txt', // File URL
    'Downloads', // Destination directory
    'new-file-name.txt', // New file name
    'ALL', // Network type
    { // HTTP headers
        'Pragma': 'no-cache',
        'X-Agent': 'FileDownloader'
    }
);
var id = tizen.download.start(request);
tizen.download.pause(id);
tizen.download.resume(id);
tizen.download.cancel(id);

Responses

0 Replies