// JavaScript Document















var activeTabs = new Array();















	function createMainBoxWithImage(boxId, url, boxWidth) {







		boxPositionDiv = document.getElementById(boxId);







				







		boxPositionDiv.className = boxPositionDiv.className + " main-box-container";







		boxPositionDiv.style.width = boxWidth + "px";







		







		addUpperEdge(boxPositionDiv, boxWidth);







		







		addImageContainer(boxPositionDiv, url);







		







		addBottomEdge(boxPositionDiv, boxWidth);







	}















	function createMainBoxWithTabs(category, boxId, boxTitle, boxTabs, defaultTab, extraLink, boxWidth, showTabPane, customFooterSize, distinguishTitle, defaultData, request) {







		extraLink += "&cid=" + category;







		







		if (defaultData == undefined) {







			defaultData = new Array();







		}







		







		if (showTabPane == undefined) {







			showTabPane = true;







		}







		







		if (customFooterSize == undefined) {







			customFooterSize = -1;







		}







		







		if (distinguishTitle == undefined) {







			distinguishTitle = false;







		}







		







		boxPositionDiv = document.getElementById(boxId);







				







		boxPositionDiv.className = boxPositionDiv.className + " main-box-container";







		boxPositionDiv.style.width = boxWidth + "px";







		







		addUpperEdge(boxPositionDiv, boxWidth);







		







		addTitleBar(boxPositionDiv, boxTitle, boxWidth, distinguishTitle);







		







		addTabContainer(category, boxPositionDiv, boxWidth, boxTabs, defaultTab, showTabPane, defaultData, request);







		







		addBottomBar(boxPositionDiv, boxWidth, extraLink, customFooterSize);







		







		addBottomEdge(boxPositionDiv, boxWidth);







	}







	







	function createMainBoxWithLinksTabs(boxId, boxTitle, boxTabs, defaultTab, extraLink, boxWidth, showTabPane, customFooterSize, distinguishTitle, defaultData, request, pageName) {







		if (pageName == undefined) {







			pageName = "details";







		}







		if (defaultData == undefined) {







			defaultData = new Array();







		}







		







		if (showTabPane == undefined) {







			showTabPane = true;







		}







		







		if (customFooterSize == undefined) {







			customFooterSize = -1;







		}







		







		if (distinguishTitle == undefined) {







			distinguishTitle = false;







		}















		boxPositionDiv = document.getElementById(boxId);







				







		boxPositionDiv.className = boxPositionDiv.className + " main-box-container";







		boxPositionDiv.style.width = boxWidth + "px";







		







		addUpperEdge(boxPositionDiv, boxWidth);







		







		addTitleBar(boxPositionDiv, boxTitle, boxWidth, distinguishTitle);







		







		addLinksTabContainer(boxPositionDiv, boxWidth, boxTabs, defaultTab, showTabPane, defaultData, request, pageName);







		







		addBottomBar(boxPositionDiv, boxWidth, extraLink, customFooterSize);







		







		addBottomEdge(boxPositionDiv, boxWidth);







	}







	







	function createMainBoxWithCustomContentTabs(tagId, boxId, boxTitle, boxTabs, defaultTab, extraLink, boxWidth, showTabPane, customFooterSize, distinguishTitle, defaultData, request) {







		if (showTabPane == undefined) {







			showTabPane = true;







		}







		







		if (customFooterSize == undefined) {







			customFooterSize = -1;







		}







		







		if (distinguishTitle == undefined) {







			distinguishTitle = false;







		}







		







		if (defaultData == undefined) {







			defaultData = "<img src=\"\" />";







		}







		







		boxPositionDiv = document.getElementById(boxId);







				







		boxPositionDiv.className = boxPositionDiv.className + " main-box-container";







		boxPositionDiv.style.width = boxWidth + "px";







		







		addUpperEdge(boxPositionDiv, boxWidth);







		







		addTitleBar(boxPositionDiv, boxTitle, boxWidth, distinguishTitle);







		







		addCustomContentTabContainer(tagId, boxPositionDiv, boxWidth, boxTabs, defaultTab, showTabPane, defaultData, request);







		







		addBottomBar(boxPositionDiv, boxWidth, extraLink, customFooterSize);







		







		addBottomEdge(boxPositionDiv, boxWidth);







	}







	







	function createAllImagesMainBox(boxId, boxTitle, boxLinks, extraLink, boxWidth, customFooterSize, distinguishTitle, clickableLinks) {







		if (clickableLinks == undefined) {







			clickableLinks = true;







		}







		







		







		if (customFooterSize == undefined) {







			customFooterSize = -1;







		}







		







		if (distinguishTitle == undefined) {







			distinguishTitle = false;







		}















		boxPositionDiv = document.getElementById(boxId);







				







		boxPositionDiv.className = boxPositionDiv.className + " main-box-container";







		boxPositionDiv.style.width = boxWidth + "px";







		







		addUpperEdge(boxPositionDiv, boxWidth);







		







		addTitleBar(boxPositionDiv, boxTitle, boxWidth, distinguishTitle);















		addImageCompContainer(boxPositionDiv, boxLinks, boxWidth, clickableLinks);







		







		addBottomBar(boxPositionDiv, boxWidth, extraLink, customFooterSize);







		







		addBottomEdge(boxPositionDiv, boxWidth);







	}







	







	function createMainBox(boxId, boxTitle, boxLinks, extraLink, boxWidth, customFooterSize, distinguishTitle, clickableLinks) {

		if (clickableLinks == undefined) {

			clickableLinks = true;

		}

		if (customFooterSize == undefined) {

			customFooterSize = -1;

		}

		if (distinguishTitle == undefined) {

			distinguishTitle = false;

		}



		boxPositionDiv = document.getElementById(boxId);

		boxPositionDiv.className = boxPositionDiv.className + " main-box-container";

		boxPositionDiv.style.width = boxWidth + "px";

		addUpperEdge(boxPositionDiv, boxWidth);

		addTitleBar(boxPositionDiv, boxTitle, boxWidth, distinguishTitle);

		addLinksContainer(boxPositionDiv, boxLinks, boxWidth, clickableLinks);

		addBottomBar(boxPositionDiv, boxWidth, extraLink, customFooterSize);

		addBottomEdge(boxPositionDiv, boxWidth);

	}



	function createMainBoxWithNoBottomEdge(boxId, boxTitle, boxLinks, extraLink, boxWidth, customFooterSize, distinguishTitle, clickableLinks) {

		if (clickableLinks == undefined) {

			clickableLinks = true;

		}

		if (customFooterSize == undefined) {

			customFooterSize = -1;

		}

		if (distinguishTitle == undefined) {

			distinguishTitle = false;

		}



		boxPositionDiv = document.getElementById(boxId);

		boxPositionDiv.className = boxPositionDiv.className + " main-box-container";

		boxPositionDiv.style.width = boxWidth + "px";

		addUpperEdge(boxPositionDiv, boxWidth);

		addTitleBar(boxPositionDiv, boxTitle, boxWidth, distinguishTitle);

		addLinksContainer(boxPositionDiv, boxLinks, boxWidth, clickableLinks, "", true);

		addBottomEdge(boxPositionDiv, boxWidth);

	}



	







	function addUpperEdge(boxPositionDiv, boxWidth) {







		var upperEdge = document.createElement("DIV");







		upperEdge.className = "main-box-vertical-edge";







		upperEdge.style.width = boxWidth + "px";







		







		var upperLeftCorner = document.createElement("DIV");







		upperLeftCorner.className = "main-box-upper-left-corner inline-left";







		







		var upperCenderEdge = document.createElement("DIV");







		upperCenderEdge.className = "main-box-center-edge inline-left";







		upperCenderEdge.style.width = (boxWidth - 12) + "px";







		







		var upperRightCorner = document.createElement("DIV");







		upperRightCorner.className = "main-box-upper-right-corner inline-right";







		







		upperEdge.appendChild(upperLeftCorner);







		upperEdge.appendChild(upperCenderEdge);







		upperEdge.appendChild(upperRightCorner);







		







		boxPositionDiv.appendChild(upperEdge);







	}







	







	function addTitleBar(boxPositionDiv, boxTitle, boxWidth, distinguishTitle) {







		var titleBar = document.createElement("DIV");







		titleBar.className = "main-box-title-bar"







		titleBar.style.width = boxWidth + "px"; 	







			







		var titleBarCaption = document.createElement("H3");







		if (distinguishTitle) {







			titleBarCaption.className = "title-caption-distinguished";







		} else {







			titleBarCaption.className = "title-caption";







		}







		







		titleBarCaption.innerHTML = boxTitle;







	







		titleBar.appendChild(titleBarCaption);







		







		boxPositionDiv.appendChild(titleBar);







	}







	







	function addTabContainer(category, boxPositionDiv, boxWidth, boxTabs, defaultTab, showTabPane, defaultData, request) {







		if (defaultData == undefined) {







			defaultData = new Array(1);







			defaultData[0]['serial'] = -1;







			defaultData[0]['title'] = 'عنوان';







			defaultData[0]['image'] = 'صورة';







		}







		







		var tab = document.createElement('DIV');







		







		var quickDetailsContainer = document.createElement("DIV");







		quickDetailsContainer.id = boxPositionDiv.id + "_TAB_DATA";







		quickDetailsContainer.className = "main-box-quick-details-container";







		quickDetailsContainer.style.width = boxWidth + "px";







				







		var contentsLoading = document.createElement("DIV");







		contentsLoading.className = "content-loading visible-component";







		contentsLoading.id = boxPositionDiv.id + "_TAB_DATA_LOADER";







		







		var loadingImage = document.createElement("IMG");







		loadingImage.className = "loading-image-centered";















		loadingImage.src = "images/general/loader.gif";







		







		contentsLoading.appendChild(loadingImage);







		







		var contents = document.createElement("DIV");







		contents.id = boxPositionDiv.id + "_TAB_DATA_CONTENTS";







		contents.className = "invisible-component";







		







		var imageSection = document.createElement("DIV");







		imageSection.className = "main-box-quick-details-image-section inline-right";







		imageSection.style.width = "109px";







		







		var image = document.createElement("IMG");







		image.id = boxPositionDiv.id + "_TAB_DATA_IMAGE";







		







		imageSection.appendChild(image);







		







		var linkSection = document.createElement("DIV");







		linkSection.className = "main-box-quick-details-link-section inline-right";







		linkSection.style.width = boxWidth - 115 + "px";







		







		var linkSectionTitleContainer = document.createElement("DIV");







		linkSectionTitleContainer.className = "main-box-quick-details-link-section-title-container";







		







		var linkSectionTitle = document.createElement("H4");

		linkSectionTitle.id = boxPositionDiv.id + "_TAB_DATA_TITLE";

		linkSectionTitleContainer.appendChild(linkSectionTitle);

		linkSection.appendChild(linkSectionTitleContainer);

		

		var linkSectionLinkContainer = document.createElement("DIV");

		linkSectionLinkContainer.className = "main-box-quick-details-link-section-link-container";





		var linkSectionLink = document.createElement("A");

        linkSectionLink.className="detailsLink details"

		linkSectionLink.innerHTML = "التفاصيل";

		linkSectionLink.id = boxPositionDiv.id + "_TAB_DATA_LINK";

		linkSectionLinkContainer.appendChild(linkSectionLink);

		linkSection.appendChild(linkSectionLinkContainer);

		contents.appendChild(imageSection);

		contents.appendChild(linkSection);

		quickDetailsContainer.appendChild(contents);

		quickDetailsContainer.appendChild(contentsLoading);



		if (showTabPane) {







			var tabBar = document.createElement("UL");







			tabBar.className = "main-box-tab-bar";







			tabBar.style.width = boxWidth + "px";







			







			for (var i = 0; i < boxTabs.length; i++) {







				var tabOption = document.createElement("LI");







				var tabId = i;







				tabOption.className = (defaultTab != i ? "not-" : "") + "selected-tab inline-right";







				tabOption.id = boxPositionDiv.id + "_TAB" + i;







				







				addTabEvent(tabOption, boxPositionDiv.id, i, request, 0, "category=" + category + "&");







				







				var tabOptionCaption = document.createElement("H4");







				tabOptionCaption.innerHTML = boxTabs[i][0];







				







				tabOption.appendChild(tabOptionCaption);







				







				tabBar.appendChild(tabOption);







			}







			







			tab.appendChild(tabBar);







		}







		







		tab.appendChild(quickDetailsContainer);







		







		boxPositionDiv.appendChild(tab);







		







		activeTabs[boxPositionDiv.id] = 0;







		







		var otherDetailsContainer = document.createElement("DIV");







		otherDetailsContainer.className = "main-box-other-details-container";







		otherDetailsContainer.style.width = boxWidth + "px";







		







		var otherDetailsList = document.createElement("UL");







		otherDetailsList.className = "main-box-other-details-list";







		otherDetailsList.id = boxPositionDiv.id + "_TAB_DATA_LINKS";







					







		otherDetailsContainer.appendChild(otherDetailsList);







		







		boxPositionDiv.appendChild(otherDetailsContainer);







		







		fillTabData(boxPositionDiv.id, defaultData);







	}







	







	function addLinksTabContainer(boxPositionDiv, boxWidth, boxTabs, defaultTab, showTabPane, defaultData, request, pageName) {







		if (pageName == undefined) { 







			pageName = "details";







		}







		







		var tab = document.createElement('DIV');







		







		var quickDetailsContainer = document.createElement("DIV");







		quickDetailsContainer.id = boxPositionDiv.id + "_TAB_DATA";







		quickDetailsContainer.className = "main-box-other-details-container";







		quickDetailsContainer.style.width = boxWidth + "px";







				







		var contentsLoading = document.createElement("DIV");







		contentsLoading.id = boxPositionDiv.id + "_TAB_DATA_LOADER";







		contentsLoading.className = "visible-true";







		contentsLoading.style.textAlign = "center";







		







		var loadingImage = document.createElement("IMG");







		loadingImage.className = "loading-image-centered";







		loadingImage.src = "images/general/loader.gif";







		







		contentsLoading.appendChild(loadingImage);







		







		var contents = document.createElement("DIV");







		contents.id = boxPositionDiv.id + "_TAB_DATA_CONTENTS";







		contents.className = "visible-false";







		







		var linkDetailsList = document.createElement("UL");







		linkDetailsList.className = "main-box-other-details-list";







		linkDetailsList.id = boxPositionDiv.id + "_TAB_DATA_LINKS";















		contents.appendChild(linkDetailsList);







		







		quickDetailsContainer.appendChild(contents);







		quickDetailsContainer.appendChild(contentsLoading);







		







				







		if (showTabPane) {







			var tabBar = document.createElement("UL");







			tabBar.className = "main-box-tab-bar";







			tabBar.style.width = boxWidth + "px";







			







			for (var i = 0; i < boxTabs.length; i++) {







				var tabOption = document.createElement("LI");







				var tabId = i;







				tabOption.className = (defaultTab != i ? "not-" : "") + "selected-tab inline-right";







				tabOption.id = boxPositionDiv.id + "_TAB" + i;







				







				addTabEvent(tabOption, boxPositionDiv.id, i, request, 1, "", pageName);







				







				var tabOptionCaption = document.createElement("H4");







				tabOptionCaption.innerHTML = boxTabs[i][0];







				







				tabOption.appendChild(tabOptionCaption);







				







				tabBar.appendChild(tabOption);







			}







			







			tab.appendChild(tabBar);







		}







		







		tab.appendChild(quickDetailsContainer);







		







		boxPositionDiv.appendChild(tab);







		







		activeTabs[boxPositionDiv.id] = 0;







		







		fillListTab(boxPositionDiv.id, defaultData, 0, pageName);







	}







	







	function addTabEvent(tab, boxId, tabId, request, type, extraParam, pageName) {	







		if (pageName == undefined) {







			pageName = "details";	







		}







		







		tab.onclick = function (e) {







			var contents = document.getElementById(boxId + "_TAB_DATA_CONTENTS");







			var loader = document.getElementById(boxId + "_TAB_DATA_LOADER");







			







			if (contents != null && loader != null) {







				document.getElementById(boxId + "_TAB_DATA_CONTENTS").className = "invisible-component";







				document.getElementById(boxId + "_TAB_DATA_LOADER").className = "content-loading visible-component";







			}







			







			if (!e) {







				e = window.event;







			}







	







			$.getJSON("modelHandlers/JsonResponder.php?" + extraParam + "request=" + request + "&id=" + boxId + "&tabId=" + tabId, function(data) {







					displayTabContents(data.id, data.tabId, data.data, type, pageName);







			});







		};







	}







	







	function addCustomContentTabContainer(category, boxPositionDiv, boxWidth, boxTabs, defaultTab, showTabPane, defaultData, request) {







		if (defaultData == undefined) {







			defaultData = "<img src=\"\" />";







		}







		







		var tab = document.createElement('DIV');







		







		var quickDetailsContainer = document.createElement("DIV");







		quickDetailsContainer.id = boxPositionDiv.id + "_TAB_DATA";







		quickDetailsContainer.className = "main-box-other-details-container";







		quickDetailsContainer.style.width = boxWidth + "px";







				







		var contentsLoading = document.createElement("DIV");







		contentsLoading.id = boxPositionDiv.id + "_TAB_DATA_LOADER";







		contentsLoading.style.textAlign = "center";







		contentsLoading.className = "visible-true";







		







		var loadingImage = document.createElement("IMG");







		loadingImage.className = "loading-image-centered";







		loadingImage.src = "images/general/loader.gif";







		







		contentsLoading.appendChild(loadingImage);







		







		var contents = document.createElement("DIV");







		contents.id = boxPositionDiv.id + "_TAB_DATA_CONTENTS";







		contents.className = "visible-false";







		







		quickDetailsContainer.appendChild(contents);







		quickDetailsContainer.appendChild(contentsLoading);







		







				







		if (showTabPane) {







			var tabBar = document.createElement("UL");







			tabBar.className = "main-box-tab-bar";







			tabBar.style.width = boxWidth + "px";







			







			for (var i = 0; i < boxTabs.length; i++) {







				var tabOption = document.createElement("LI");







				var tabId = i;







				tabOption.className = (defaultTab != i ? "not-" : "") + "selected-tab inline-right";







				tabOption.id = boxPositionDiv.id + "_TAB" + i;







				







				addTabEvent(tabOption, boxPositionDiv.id, i, request, 2, "category=" + category + "&");







				







				var tabOptionCaption = document.createElement("H4");







				tabOptionCaption.innerHTML = boxTabs[i][0];







				







				tabOption.appendChild(tabOptionCaption);







				







				tabBar.appendChild(tabOption);







			}







			







			tab.appendChild(tabBar);







		}







		







		tab.appendChild(quickDetailsContainer);







		







		boxPositionDiv.appendChild(tab);







		







		activeTabs[boxPositionDiv.id] = 0;







		







		getTabContents(boxPositionDiv.id, defaultData, 2);







	}







	







	function addImageCompContainer(boxPositionDiv, boxLinks, boxWidth, clickableLinks, pageName) {







		if (pageName == undefined) {







			pageName = "details";







		}







		







		var otherDetailsContainer = document.createElement("DIV");







		otherDetailsContainer.className = "main-box-other-details-container";







		otherDetailsContainer.style.width = boxWidth + "px";















		for (var i = 0; i < boxLinks.length; i++) {







			var isLast = (i == boxLinks.length - 1) ? 1 : 0;







			







			var quickDetailsContainer = document.createElement("DIV");







			quickDetailsContainer.className = "main-box-quick-details-container-no-back" + (isLast == 1 ? "-no-border" : "");







			quickDetailsContainer.style.width = boxWidth + "px";







			quickDetailsContainer.style.height = "50px";







			if (i % 2 == 0) {







				quickDetailsContainer.style.background = "url(images/general/viewsBack.gif)";







			}







			







			var contents = document.createElement("DIV");







			contents.className = "invisible-component";







			







			var linkSection = document.createElement("DIV");







			linkSection.className = "main-box-quick-details-link-section inline-right";







			linkSection.style.width = boxWidth + "px";







			linkSection.style.height = "50px";







			







			var linkSectionTitleContainer = document.createElement("DIV");







			linkSectionTitleContainer.className = "main-box-quick-details-link-section-title-container";



			var linkAuthor = document.createElement("UL");

			linkAuthor.className = "main-box-other-details-list";

			linkAuthor.style.color ="#555555";

			linkAuthor.style.paddingTop ="0px";

			linkAuthor.style.paddingBottom ="0px";

			

			var linkAuthorList = document.createElement("LI");

			linkAuthorList.style.fontSize ="14px";

			linkAuthorList.style.fontWeight ="Bold";

			linkAuthorList.style.paddingTop ="0px";

			linkAuthorList.style.paddingRight ="10px";

			linkAuthorList.style.background = "url(images/general/bullet.gif) no-repeat right";

			var linkAuthorText = document.createTextNode(boxLinks[i]['author']);

            linkAuthorList.appendChild(linkAuthorText);

			linkAuthor.appendChild(linkAuthorList);

			

			var linkSectionTitle = document.createElement("A");

			linkSectionTitle.style.fontSize = "15px";

			linkSectionTitle.style.paddingRight = "20px";

			linkSectionTitle.style.display = "block";

			linkSectionTitle.innerHTML = boxLinks[i]['title'];
			
			
			

			linkSectionTitle.href = "details/" + boxLinks[i]['serial'] + "/" + boxLinks[i]['richurl'] + ".htm" ;

			linkSectionTitleContainer.appendChild(linkAuthor);

			linkSectionTitleContainer.appendChild(linkSectionTitle);

			linkSection.appendChild(linkSectionTitleContainer);

			quickDetailsContainer.appendChild(linkSection);

			otherDetailsContainer.appendChild(quickDetailsContainer);	



		}







		







		boxPositionDiv.appendChild(otherDetailsContainer);







	}







	







	function addLinksContainer(boxPositionDiv, boxLinks, boxWidth, clickableLinks, pageName, noBottomLine) {







		if (pageName == undefined) {







			pageName = "details";







		}







		







		var otherDetailsContainer = document.createElement("DIV");





		if (noBottomLine) {

			otherDetailsContainer.className = "main-box-other-details-container-internal";

			otherDetailsContainer.style.minHeight = "20px";

		} else {

			otherDetailsContainer.className = "main-box-other-details-container";

		}





		otherDetailsContainer.style.width = boxWidth + "px";







		







		var otherDetailsList = document.createElement("UL");

		otherDetailsList.id = boxPositionDiv.id + "-list";





		otherDetailsList.className = "main-box-other-details-list";















		for (var i = 0; i < boxLinks.length; i++) {







		







			var option = document.createElement("LI");







			







			if (clickableLinks) {







				var optionCaption = document.createElement("A");







				optionCaption.innerHTML = boxLinks[i]['title'];






				optionCaption.href = pageName + "/" + boxLinks[i]['serial'] + "/" + boxLinks[i]['richurl'] + ".htm" ;







				option.appendChild(optionCaption);







			} else {







				var optionCaption = document.createElement("SPAN");







				optionCaption.innerHTML = boxLinks[i]['title'];







				option.appendChild(optionCaption);







			}







			







			otherDetailsList.appendChild(option);







		}







					







		otherDetailsContainer.appendChild(otherDetailsList);







		







		boxPositionDiv.appendChild(otherDetailsContainer);







	}







	







	function addBottomBar(boxPositionDiv, boxWidth, extraLink, customFooterSize) {







		var bottomBar = document.createElement("DIV");







		bottomBar.className = "main-box-bottom-bar";







		bottomBar.style.width = boxWidth + "px";















		if (customFooterSize != -1) {







			bottomBar.style.height = customFooterSize + "px";







		}







		







		if (extraLink != "") {







			var bottomBarMore = document.createElement("A");







			bottomBarMore.innerHTML = "المزيد »";







			bottomBarMore.href = extraLink;







			







			bottomBar.appendChild(bottomBarMore);







		}







		







		boxPositionDiv.appendChild(bottomBar);







	}







	







	function addBottomEdge(boxPositionDiv, boxWidth) {







		var bottomEdge = document.createElement("DIV");







		bottomEdge.className = "main-box-vertical-edge";







		bottomEdge.style.width = boxWidth + "px";







		







		var bottomLeftCorner = document.createElement("DIV");







		bottomLeftCorner.className = "main-box-bottom-left-corner inline-left";







		







		var bottomCenderEdge = document.createElement("DIV");







		bottomCenderEdge.className = "main-box-center-edge inline-left";







		bottomCenderEdge.style.width = (boxWidth - 12) + "px";







		







		var bottomRightCorner = document.createElement("DIV");







		bottomRightCorner.className = "main-box-bottom-right-corner inline-right";







		







		bottomEdge.appendChild(bottomLeftCorner);







		bottomEdge.appendChild(bottomCenderEdge);







		bottomEdge.appendChild(bottomRightCorner);















		boxPositionDiv.appendChild(bottomEdge);







	}







	







	function addCalendarContainer(boxPositionDiv, boxName, boxWidth) {







		var otherDetailsContainer = document.createElement("DIV");







		otherDetailsContainer.className = "main-box-other-details-container";







		otherDetailsContainer.style.width = boxWidth + "px";







		







		var calendarContainer = document.createElement("DIV");







		calendarContainer.className = "calendar-container";







		calendarContainer.id = boxName + "-calendar";







					







		otherDetailsContainer.appendChild(calendarContainer);







		







		boxPositionDiv.appendChild(otherDetailsContainer);







	}







	







	function addImageContainer(boxPositionDiv, imageURL) {







		var imageContainer = document.createElement("DIV");







		imageContainer.className = "image-container";







		







		var image = document.createElement("IMG");







		image.src = imageURL;







		







		imageContainer.appendChild(image);







		







		boxPositionDiv.appendChild(imageContainer);







	}
