// this function works in combination with product extension
// it uses the productConf array created by the product extension
// so it may not work anywhere else than productdetail pages...
function articleRecommendLinkThickbox(uid, id, url) {
	var artNumber 		= '';
	var variation		= '';
	var size			= '';
	var color			= '';

	if (id) {
		// find currently selected article number
		variation	= currentVariation(uid, id);
		size		= currentSize(uid, id, variation);
		color		= currentColor(uid, id, variation, size);

		/* START: ELEGANCE specific modification */
		// Selects the first value of the array if no size is selected
		var sizeForm = document.getElementById('productSizeForm_' + uid + '_' + id);
		if(sizeForm && sizeForm.value == 0) {
			size	= firstSize(uid, id, variation);
			color	= firstColor(uid, id, variation, size);
		} // end: if
		/* END: ELEGANCE specific modification */

		artNumber	= productConf[uid][id]['articles'][variation][size][color]['artNumber'];
	} // end: if

	//change/render document.location
	//document.location.href = url.replace('%s', artNumber);
	popupurl = url.replace('%s', artNumber)+'?TB_iframe=true&placeValuesBeforeTB_=savedValues&modal=true&width=600&height=450&scrollbars=no';
	tb_show('', popupurl, '', 'Fenster schliessen');
}

