Need a new web host or having a problem with a script? Tips and advice on the best way to design, build and maintain your most valuable asset - your website!

how to put download link on my pic?

Posts: 46
Joined: 07 Jun 11

how to put download link on my pic?

i want the download link on my picture. When s.o click on the word "Download here" and it is the download link of my image

.so i want to put direct link on the word instead of just right click on the pic and select "save picture as". So can we put

link code on the word "download here"?
  • 0
Posts: 6369
Joined: 25 Feb 11

eHow has a step-by-step guide on how to make an image clickable

Hope that helps. Have a good day!
  • 0

Building affiliate marketing websites is a breeze:
Like us on Facebook:
Posts: 102
Joined: 13 Sep 11

Use the PHP header() function.
First, create a file named download_img.php and paste the following code:

PHP Code:

header('Content-type: image/png');
header('Content-Disposition: attachment; filename="downloaded-name.png"');

then, link to this file:
HTML Code:

<a href="download_img.php">Download this Image</a>

Clicking the link will open the download dialog box in the browser :-)
  • 0
Posts: 6
Joined: 16 Sep 11
Use the PHP header() function and HTML code u can link code on your desire location.
  • 0

This topic was started on Jun 20, 2011 and has been closed due to inactivity. If you want to discuss this topic further, please create a new forum topic.