function loadCustomSingleNews (whereShow, id, lang, hashedLinks, linkToHash) {
	
	var hash = window.location.hash;
	if (hash.slice(1,5) == 'list') {
		var link = "http://restec.ru/news-custom("  + id + ")." + lang + ".html";
		$.ajax({
		'url': link
			, 'data':{"hashedLinks": hashedLinks, "linkToHash":linkToHash}
			, 'dataType':'jsonp'
			, 'cache': false
			, 'success':function (data) {
				$(whereShow).html( data.value );
			}
		} );
		return;	
	}
	if (hash.slice(1,8) == 'archive') {
		var link = "http://restec.ru/archive-custom("  + id + ")." + lang + ".html";
		$.ajax({
		'url': link
			, 'data':{"hashedLinks": hashedLinks, "linkToHash":linkToHash}
			, 'dataType':'jsonp'
			, 'cache': false
			, 'success':function (data) {
				$(whereShow).html( data.value );
			}
		} );
		return;	
	}
	
	var id = hash.match (/newsId=([0-9]+)/)[1];
	var lang = hash.match (/lang=(ru|en).*/)[1];
	if (id) {
		var link = "http://restec.ru/details-custom("  + id + ")." + lang + ".html";
		$.ajax({
		'url': link
			, 'data':{"hashedLinks": hashedLinks, "linkToHash":linkToHash}
			, 'dataType':'jsonp'
			, 'cache': false
			, 'success':function (data) {
				$(whereShow).html( data.value );
				var tmrReady = setInterval( function () {
					if ($('#news-id-' + id).length > 0) {
						$('#news-id-' + id).addClass('active');
						clearTimeout(tmrReady);
					}
				}, 100);
				// setTimeout("$('#news-id-' + id).addClass('active')", 100
			}
		} );
	}
} 

