$(function(){
	
	
	// Quick search at top of page, on focus clear text
	// and on blur restore text if value is empty
	var original_text = document.getElementById('quick_search').value;
	$("#quick_search").focus(function(){	
		this.value = (this.value == original_text) ? '' : this.value ;
	}).blur(function(){
		this.value = (this.value == '') ? original_text : this.value ;
	});

	// Activate the psuedoSelect plugin to mimic form select but with more style controls
	$('.dropdown').pseudoSelect();

	// Links within the cart pop up new windows so as not to "interrupt the cart experience"
	// Can you tell a developer did NOT come up with that phrase? :)
	$("a.cart_popup").click(function(){
		var $link = $(this).attr("href") + "#content";
		window.open($link,'lti_popup','height=610,width=850,menubar=1,scrollbars=1,status=1');
		return false;
	});
	
});
