var	 project_id = '';
var registration_url = '';

var setProjectId = function(id){
	project_id = id;
}

var setRegistrationURL = function(path){
	registration_url = path;
}


$(window).ready(function(e){



	$("#btn_registration").bind('click',function(e){
		e.preventDefault();
		$.ajax({		
			url : registration_url,
			type : "POST",
			dataType : 'json',
			data : {project_id:project_id},
			success : function(resp){
				if (resp.success){
					show_message('success', resp.message, '');
					$(".project_registration_box").hide();
				}else{
					show_message('danger', resp.message, '');
				}
			},
            error : function (xhr, status, error){
		        show_message('danger', error, '');
            }
		})
	})	


})