$(document).ready(function(){

var link = location.href;
link = link.replace(/#/g, "");
var expl = link.split('/');
var spot = expl[5];
spot = spot.replace(/[^0-9]/g, "");
var cat = expl[6];
cat = cat.replace(/[^0-9]/g, "");

$("#select_subcat").change(function () {
	//alert($(this).val());
	if( $(this).val() == '0' ){
		location.href = '/list/category/'+spot+'/'+cat;
	}
	else{
		location.href = '/list/subcategory/'+spot+'/'+cat+'/'+$(this).val();
	}
});

});