javascript - Downloading HTML files without opening a browser -


i have url don't want open in browser. servlet url points able download jpeg image of rendered html document using html2canvas library based on specific params.

how can download html jpeg without rendering html on client side. possible. please share inputs.

you can try this:-

response.addheader("content-disposition", "attachment; filename=" + name); 

or ian suggested:-

content-disposition: attachment; filename=abc.jpeg 

Comments

Popular posts from this blog

Issues changing the value of an element in an array in matlab -

php - MySQLi binding parameters in a prepared statement doesn't work unless inserted after "WHERE" -

vb.net - Alternative to the T-SQL AS keyword -