//'+ ''+ ''+ ''+ '
'+ '' + '' + obj.name.substr(0,this.li_name_size) + ': '+ obj.description.substr(0,this.li_description_size) + '
'+ ''; alink = document.createElement("a"); alink.href="#"; alink.className="em"; alink.onclick = function(){widgetSilkfairStore297_364.widgetShowItem(idx);return false;} alink.innerHTML = strOut; return alink; } this.widgetDrawItems = function(){ if(this.Items.length <= this.itemsToShow) { i = 0; to = this.Items.length; } else { i = this.currentItem; if ((this.currentItem + this.itemsToShow) <= this.Items.length){ to = this.currentItem + this.itemsToShow; }else{ to = this.Items.length; } } document.getElementById(this.el_items_list).innerHTML = ""; for (i;i<=to;i++){ obj = this.Items[i]; strOut = this.widgetDrawItem(i); document.getElementById(this.el_items_list).appendChild(strOut); } } this.widgetShowItem = function(idx){ this.thumbHighlight(idx); container = document.getElementById(this.el_image_preview); str_image = ""; container.innerHTML = str_image; document.getElementById(this.el_widget_item_name).innerHTML = this.Items[idx].name.substr(0, this.item_name_size); document.getElementById(this.el_widget_item_description).innerHTML = this.Items[idx].description.substr(0, this.item_description_size); document.getElementById(this.el_item_price).innerHTML = this.Items[idx].price; document.getElementById(this.el_item_link).href = this.storeDomain + "/" + this.Items[idx].id; } this.widgetShowNullItem = function(){ container = document.getElementById(this.el_image_preview); str_image = ""; container.innerHTML = str_image; document.getElementById(this.el_widget_item_name).innerHTML = "Lil` Angel Gifts".substr(0, this.store_name_size); document.getElementById(this.el_items_list).innerHTML = "\"Instruction Manual for Babies\", was developed in 2000 by a very tired mom of a newborn, during the wee hours of the morning. It was originally designed for her personal use, but it soon became a hit with family and friends. When this newborn was later determined to have Angelman Syndrome, this mom then developed another book out of necessity called \"Organizing Your Child\'s Special Needs\". This...".substr(0, this.store_description_size); } this.thumbHighlight = function(idx){ if(this.Items.length <= this.itemsToShow) { i = 0; to = this.Items.length; } else { i = this.currentItem; to = this.currentItem + this.itemsToShow; } for (i;i<=to;i++){ obj = this.Items[i] if ( document.getElementById(this.el_thumb_prefix + i) ){ document.getElementById(this.el_thumb_prefix + i).className = "wg_thumb"; } } document.getElementById(this.el_thumb_prefix + idx).className = "wg_thumb_high"; } // Default html : version = 1 this.widgetDrawHtml = function(){ strOut = '
' + '' + '' + '' + '' + '' + '' + '
avatarLil` Angel Gifts
' + '
' + '' + '' + '
' + '
' + '
' + '
' + '
' + '' + '' + '' + '
Click for details
' + '
' + '
' + '' + '' + '' + '' + '
'; if ( document.getElementById("widget_preview") ){ document.getElementById("widget_preview").innerHTML = strOut; }else{ document.write(strOut); } } this.drawCssLink = function(){ var objCss=document.createElement('link'); objCss.rel='stylesheet'; objCss.type='text/css'; objCss.href='http://silkfair.com/widget/style.css'; //objCss.href='http://silkfair.com/widget/style.css'; objCss.media='all'; document.lastChild.firstChild.appendChild(objCss); } this.widgetDrawWidget = function(){ this.setupElements(); if (document.getElementById(this.el_container)!= undefined){ return false; } this.drawCssLink(); this.widgetDrawHtml(); this.widgetDrawItems(); if(this.Items.length >= 0){ this.widgetShowItem(this.currentItem); }else{ this.widgetShowNullItem(); } } }//widgetSilkfairStore Class widgetSilkfairStore297_364 = new widgetSilkfairStore(); widgetSilkfairStore297_364.suffix = "297_364"; widgetSilkfairStore297_364.item_name_size = 25; widgetSilkfairStore297_364.item_description_size = 30; widgetSilkfairStore297_364.li_name_size = 12; widgetSilkfairStore297_364.li_description_size = 24; widgetSilkfairStore297_364.widgetDrawWidget(); // google-analytics var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www."); document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E")); gaTracker = function(){ if (typeof(_gat) == "object"){ var pageTracker = _gat._getTracker("UA-3580677-1"); pageTracker._initData(); pageTracker._trackPageview(); } } gaTracker(); //]]>