I'm having trouble firing a click event on an . When insertIntoInsertHolder() is called it adds a link to the content of div#swf_insert_holder - I then create the click event just below. However the event doesn't fire.
$javascript = "javascript:;";
$swf_insert_box_link = "swf_insert_box_link";
echo "
function insertIntoInsertHolder( filename ) {
$('#swf_insert_holder').append('<a href=" . $javascript . " class=" . $swf_insert_box_link . ">go</a>');
//produces: <a href="javascript:;" class="swf_insert_box_link">go</a>
}
$('a.swf_insert_box_link').click( function() {
alert('hello!!'); //for testing
});
Thanks in advance!