How to redirect image URL link to image permalink? (3 posts)

  1. TC.K
    Posted 7 years ago #

    I have create a image.php template for views image in my blog. I did this because want visitor keep in my site instead of just view the .jpg files and go away.

    To view the image in the particular image template, it need the image permalink. So the problem is i used to post the image by its original image url. It's mean the code is like

    "<"a href="http://localhost/wordpress/wp-content/uploads/2008/10/image1.jpg">><src="http://localhost/wordpress/wp-content/uploads/2008/10/image.jpg" alt="" width="130" height="275">, "

    if i would like to use the image.php template i have to change the herf image url link to image permalink. Yes, i can manually change it, but the question is there are hundreds of image in my blog, it is take many time to make it complete.

    So, is it anyway to redirect the image URL to image permalink automatically? Or, have any ideals to view the image in a specific template?

  2. plinth
    Posted 7 years ago #

    I'd be very interested in this too - did you find a way to do it?

  3. James Mehorter
    Posted 6 years ago #

    Anyone have an answer to this?

Topic Closed

This topic has been closed to new replies.

About this Topic