2481 posts
Nice Guy
- Most Wanted Bounty Winner
- Sold between 250 000 and 1 000 000 dollars
- Has been a member for 5-6 years
- Repeatedly Helped protect Envato Marketplaces against copyright violations
- Won a Competition
- Bought between 100 and 499 items
- Exclusive Author
- Referred between 200 and 499 users
RubenBristian
says
So i have an image object in the php file. How can i make that box appear and let the users save the image in their computer?
I am currently using imagejpeg($img, ””, 100);, which shows the picture and the the user can save it. But i want open that save box auto .. can it be done?
1389 posts
- Author was Featured
- Beta Tester
- Bought between 10 and 49 items
- Exclusive Author
- Grew a moustache for the Envato Movember competition
- Has been a member for 4-5 years
- Item was Featured
- Microlancer Beta Tester
- Referred between 10 and 49 users
Pdesignx
says
header("Content-Type: image/jpg");
header("Expires: 0");
header("Cache-Control: must-revalidate, post-check=0, pre-check=0");
header("content-disposition: attachment; filename=my_image.jpg");
imagejpeg($img, null, 100);
2481 posts
Nice Guy
- Most Wanted Bounty Winner
- Sold between 250 000 and 1 000 000 dollars
- Has been a member for 5-6 years
- Repeatedly Helped protect Envato Marketplaces against copyright violations
- Won a Competition
- Bought between 100 and 499 items
- Exclusive Author
- Referred between 200 and 499 users
RubenBristian
says
thanks! 
