function displayCategory(dictionary) {
  catId = dictionary.items["category_id"];
  $("#newSkinCategoryList").load("/products/eon/skinstore/skincategory.php", { cat: catId }, showNewCategories);
}

function showNewCategories() {
  $("#skinCategoryList").showHtml($("#newSkinCategoryList").html());
}

function download(skinId) {
  window.location = "../skinstore/download.php?sid=" + skinId;
}

function search() {
  delta = $("input[name='search']").text();
  window.location = "../skinstore/index.php?search=" + delta;
}
function blockWithTagDiv(div) {
  $.blockUI({ message: $("#"+div) });
}
function addTags(skinId) { 
    // update the block message 
    $.blockUI({
      message: "<label>Please Wait...</label><label>While Retrieving Tags...</label>"
    }); 

    $("#tags").load("/products/eon/skinstore/add_tags.php", { sid: skinId }, loadTags()); 
}
function loadTags() {
  $.blockUI({ message: $("#tags") });
}
  
function cancelTags() { 
    $.unblockUI(); 
    return false; 
}
function attachTags(skinId) {
    
    tagsString = "";
    $("input:checked").each(function (i) {
      if ( i > 0 ) tagsString = tagsString + ",";
      tagsString = tagsString + $(this).val();
    });
    
    $.ajax({    url: 'attachTags.php',
                data: {skin_id: skinId, tags: tagsString},
                cache: false, 
                complete: function() { 
                
                $("#tag_links").load("/products/eon/skinstore/tags.php", { skin_id: skinId }, null);
                $.unblockUI();
                 } });
                
    return false;
}


$(document).ready(function() { 
   opts = {
      distances : [40,40],
      leftShifts : [-10,-10],
      bubbleTimes : [400,400],
      hideDelays : [0,0],
      bubbleWidths : [200,200],
      bubbleImagesPath : "/images/skins/classic",
      msieFix : false
   };
   $('.coda_bubble').codaBubble(opts);
});