• I’m new to wordpress and apparently I’ve made a procedural mistake…

    I’ve been adding photos to my blog via the WP gallery. I actually quite like it, concise and easy to use.

    However there aren’t many options to it, and I just want to make one SIMPLE change. Or it should be simple. Getting the thumbnail images to open to target=”_blank” instead of the same window.

    Now I could go and re-do all of my images, or I could just quickly change the code controlling the gallery shortcode so that they all open to a new window.

    Any insight on how to go about doing this?

Viewing 4 replies - 1 through 4 (of 4 total)
  • Thread Starter djtodd

    (@djtodd)

    I hate doing this, but BUMP.

    I would like to know this too 🙂

    got it.

    U have to add target=’_blank’ to the href in post-template.php on line 945

    return apply_filters( 'wp_get_attachment_link', "<a href='$url' target='_blank' title='$post_title'>$link_text</a>", $id, $size, $permalink, $icon, $text );

    scoobasteve have you found any other issues this might create? It seems to be working well, I just think maybe someone should put this in as a solution to this issue.

    Nicholas

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Gallery Shortcode’ is closed to new replies.