HI!
Can someone else tell me how: Click on a link in text, url is a jpg file and appears a prompt to download?
The usually is the jpg opens a browser window but I don´t want this.
Prompt to a JPG
Moderator: General Moderators
I don't understand you???
But maybe that is what you wanted:
But maybe that is what you wanted:
Code: Select all
<a href="page1.html" title=""><img src="img.jpg" alt="my_pic"></a>Did you even try to search the forums?
http://forums.devnetwork.net/viewtopic.php?t=31717&highlight=php force download
http://forums.devnetwork.net/viewtopic.php?t=31717&highlight=php force download
- Chris Corbyn
- Breakbeat Nuttzer
- Posts: 13098
- Joined: Wed Mar 24, 2004 7:57 am
- Location: Melbourne, Australia
Usually just these two headers will suffice.
Code: Select all
header('Content-Diposition: attachment; filename=myfile.jpg');
header('Content-Type: image/jpeg');