I am using php and html and i am trying to make two buttons:
- Print button: that print a specific picture (not the whole page)
- Download button: which will display the save as window to save a picture.
Do you know if this is possible and how, should it be done?
<form><input type="button" value="Download" onClick="window.location.href='your link'"></form>
You must use HEADER with proper MIME type to prompt the download immediately when you click the download button. The above @tyson567 methods just send you the new page where the image located, it'll not prompt you to download the image when you reached that page. Here is the example for method 1. The method 2 can be done with Javascritp or jQuery plugin. You just need to google for that.
thankyou both for your help. it worked for me.
Solved ? Marked it as Solved then.
As a small business owner, it is difficult to understand where you are on the search engine result pages. SEO is complicated and it is constantly changing. Every company wants ...
Hello everyone. I have a string that looks like this
(Mango, fruits, and), (Maize, cereals, and), (Mango juice, beverages, and)
I would like to convert the above string using php ...
I have a function that I need help with. The purpose of the function is to sort an array of objects by field. This function was using the PHP function ...