Link to what? In your example, would that be:
Code:
. . . age" rev="targetdiv:bookloadarea1, link:http://www.amazon.com/book1"><img src=".../img/books/thumb_book1.jpg" /></a>
If so, just add this script to the head of the page:
Code:
<script type="text/javascript">
jQuery(function($){
var re = /:(?!\/\/)/;
$('a[rel=enlargeimage]').click(function(e){
var opts = {}, rev = this.rev.split(','), i = rev.length - 1;
for (i; i > -1; --i){
rev[i] = rev[i].split(re);
opts[$.trim(rev[i][0])] = $.trim(rev[i][1]);
if(opts.link){
e.preventDefault();
location.href = opts.link;
return;
}
}
});
});
</script>
If you have something else in mind, let me know.
Bookmarks