function mxWebshopSelectValue(select, value_id, value_ids, page_id, page_filename){
	// Remove the values from this selectbox
	for(var i = 1; i < select.options.length; i++){
		for(key in value_ids){
			if(value_ids[key] == select.options[i].value){
				value_ids.splice(key, 1);
			}
		}
	}

	// Add the value from this selectbox
	value_ids.splice(1, 0, value_id);

	// Sort the new array
	value_ids.sort();

	// Make a string value
	var value_ids_string = "";
	for(key in value_ids){
		if(value_ids[key] != ''){
			value_ids_string += "-" + value_ids[key];
		}
	}

	document.location.href = './' + (value_ids.length > 1 ? page_id + value_ids_string + '-' : '') + page_filename + '.html';
}

function ctrl_z(e){
	var filename = document.location.href;
	while(filename.indexOf('/') != -1){
		filename = filename.substring(filename.indexOf('/')+1,filename.length);
	}
	if(filename.indexOf('.html') != -1){
		filename = filename.substring(0,filename.indexOf('.html'));
	}else{
		filename = 'index';
	}

	if(((!window.event && ((e && e.which) || e.keyCode==26) && (e.keyCode==26 || ( e.which==122 && e.ctrlKey))) || (window.event && window.event.keyCode == 26)) && confirm("Wilt u de inhoud van de website bewerken?")){
		document.location = 'http://www.musicservice.nl/admin/login.html?referer=' + escape(document.location.href);
	}
}

document.onkeypress = ctrl_z;


