$(document).ready(function(){

	//Open all links with rel="external" in new window
	$('a[rel="external"]').click( function() {
			window.open( $(this).attr('href') );
			return false;
    });

	//Clear value in search input box
	$(function() {
		swapValues = [];
		$(".n_input").each(function(i){
			swapValues[i] = $(this).val();
			$(this).focus(function(){
				if ($(this).val() == swapValues[i]) {
					$(this).val("");
				}
			}).blur(function(){
				if ($.trim($(this).val()) == "") {
					$(this).val(swapValues[i]);
				}
			});
		});
	});
	
	//Fancybox Newsletter Form
	$("a.group").fancybox({
		'hideOnContentClick': false
	});

	//Blockquote
	var str = $("body.about blockquote p").text();
	var allstr = str + '<img src="images/blockquote-close.gif" alt="" />';
	$("body.about blockquote p").html(allstr);

	$('#breadcrumb li:first a').css('background-image','url(images/breadcrumb-a2.png)');
	
	//Get Tweets
	getTwitters('tweet', { 
	id: 'LyricBelfast', 
	count: 1, 
	enableLinks: true, 
	ignoreReplies: true, 
	clearContents: true,
	template: '%text%<br /><span><a href="http://twitter.com/%user_screen_name%/statuses/%id%/" target="_blank">%time%</a></span>'
	});
	
});