Open Image in New Tab
A lot of people have been asking about opening the link on the main image in a new tab or window. This is a pretty easy fix, so I thought I’d walk through the steps here.
Getting Started
All the setup should be the same as a regular PikaChoose setup.
API Hook
We’re going to change how you can PikaChoose slightly to take advantage of a hook. This way we can inject our code in where we want it.
$(document).ready(function (){
var a = function(self){
self.anchor.attr('target','_blank');
};
$("#pikame").PikaChoose({buildFinished:a});
});
Example
See wasn’t that simple? It’s almost too easy! You can view an example below:


