WordPress.org

Ready to get started?Download WordPress

Forums

Where and how do I edit the template for this page? (3 posts)

  1. cykeltomte
    Member
    Posted 2 years ago #

    Hi, when an image is attached to a post, the image acts like a link to a sort of gallery page.

    Example:
    http://fashionfield.nu/2012/05/28/all-of-these-emotions-of-mine-keep-holding-me/ when pressing one of the images, it links to this page: http://fashionfield.nu/2012/05/28/all-of-these-emotions-of-mine-keep-holding-me/1-7/

    How can i edit the look of this page?

  2. patv
    Member
    Posted 2 years ago #

    When you include an image in a post or page through WordPress' editor, it automatically wraps the image in an anchor tag pointing to either the image source or a listing of images (i think this is it in your case). To remove the anchor, you can do one of the following:

    1- in the HTML editor, you can manually remove the anchor tags around your images.

    2- When including images, and you are in your image interface (before clicking on 'insert image' button), you can remove the link value. Putting its value to empty will remove the link.

    If you want to edit the template file of those images, check this link. I believe that what you are looking for is attachment.php. Have a look at the other template files types available at the same level of attachment.php in case you want to scope down the template. At the moment, you're either taking in the default attachment.php file or it's defaulting to your index.php.

  3. cykeltomte
    Member
    Posted 2 years ago #

    Thanks! Making i file called image.php did the trick :)

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.