var days = new Array();
days['ca'] = new Array('dg', 'dl', 'dt', 'dc', 'dj', 'dv', 'ds');
days['es'] = new Array('dom', 'lun', 'mar', 'mié', 'jue', 'vie', 'sáb');
days['en'] = new Array('sun', 'mon', 'tue', 'wed', 'thu', 'fri', 'sat');

var month = new Array();
month['ca'] = new Array('gen', 'feb', 'mar', 'abr', 'mai', 'jun', 'jul', 'ago', 'set', 'oct', 'nov', 'des');
month['es'] = new Array('ene', 'feb', 'mar', 'abr', 'may', 'jun', 'jul', 'ago', 'sep', 'oct', 'nov', 'dic');
month['en'] = new Array('jan', 'feb', 'mar', 'apr', 'may', 'jun', 'jul', 'aug', 'sep', 'oct', 'nov', 'dec');

var categoriesName = new Array();
categoriesName['draft'] = '(Esborrany)';
categoriesName['cultura'] = 'Cultura';
categoriesName['economia'] = 'Economia';
categoriesName['esports'] = 'Esports';
categoriesName['politica'] = 'Política';
categoriesName['societat'] = 'Societat';
categoriesName['tecnologia'] = 'Tecnologia';
categoriesName['None'] = '';
categoriesName[''] = '';

setInterval(function(){
	var d = new Date();
	var hours = ('0' + d.getHours()).slice(-2);
	var minutes = ('0' + d.getMinutes()).slice(-2);
	var day = days['ca'][d.getDay()];
	var date = d.getDate();
	var mont = month['ca'][d.getMonth()];
	document.getElementById("clock").innerHTML = hours + ":" + minutes;
	document.getElementById("date").innerHTML = day + " " + date + " " + mont;
}, 1000);

(function(d, s, id) {
	var js, fjs = d.getElementsByTagName(s)[0];
	if (d.getElementById(id)) return;
	js = d.createElement(s); js.id = id;
	js.src = "//connect.facebook.net/ca_ES/sdk.js#xfbml=1&version=v2.0";
	fjs.parentNode.insertBefore(js, fjs);
}(document, 'script', 'facebook-jssdk'));

!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0];if(!d.getElementById(id)){js=d.createElement(s);js.id=id;js.src="https://platform.twitter.com/widgets.js";fjs.parentNode.insertBefore(js,fjs);}}(document,"script","twitter-wjs");

var tumblr_link_url = "http://www.example.com/permalink/my-article";
var tumblr_link_name = "My Awesome Article";
var tumblr_link_description = "Lorem ipsum...";