click hijack iframe

HTML

<a href="http://wordpress.org">WordPress</a>
<a href="http://verindra.ga/" data-ir-location="http://cyber.law.harvard.edu/">Nothing</a>
<iframe id="test" name="test" src="" width="1000" height="600" border="1"></iframe>
<div class="iframe-output">
</div>
$("div.global div.info_line:first-child .intem_float_right").click(alert("asdasdasdasd"););

CSS

a {
    display: block;
}

JavaScript

$(function( ) {

/* iframe tests */

// doesn't look good: http://stackoverflow.com/questions/4548984/detect-if-the-iframe-content-has-loaded-successfully

$if = $('iframe');
$output = $('.iframe-output');

$("iframe div.global div.info_line:first-child .item_float_right a").css( "text-decoration", "underline" )
  .hover(function() {
    $( this ).addClass( "sogreen" );
  }, function() {
    $( this ).removeClass( "sogreen" );
  });
  
$if.on('load', function(e) {
    $output.html( $output.html() + '<br>iframe_load: ' + $if[0].readyState );
}).on('error', function(e) {
    // no event
    $output.html( $output.html() + '<br>iframe_error' );
}).on('unload', function(e) {
    // no event
    $output.html( $output.html() + '<br>iframe_unload' );
});

$if[0].onreadystatechange = function(e) {
    $output.html( $output.html() + '<br>iframe_readystatechange' );
};

/* base click handler */
$('a').click(function() {
    $if.prop('src', $(this).prop('href'));
    return false;
});
    
});