$(function() {

	// Custom Category Filter
	$("#ebay_sales_cat_subset").on("change",function(){
		var location = document.URL.replace(/&?page=[0-9]/,"");
		location = location.replace('#inv_settings', "");
		location = location.replace(/&?ebay_sales_cat_id=([^&]$|[^&]*)/i, "");
		location = location+"&ebay_sales_cat_id="+$(this).val()+"#inv_settings";
		window.location.replace(location);
	});
});
