javascript download file and get function code example
Example: javascript download file
$('a#someID').attr({target: '_blank',
href : 'http://localhost/directory/file.pdf'});
$('a#someID').attr({target: '_blank',
href : 'http://localhost/directory/file.pdf'});