﻿

function fixPrCard() {


// FIX TIL MAGICZOOM indsaettelse af DIV der kontrollere smaa billeder
  var selectorHTML = $('#Selector').html();
  var newSelectorHTML = "<div id='selectorWrap'>" + selectorHTML + "</div>";
  $('#Selector').html(newSelectorHTML);


  // FIX PRICE
  
  if (!$('.SpecialOfferPrice_ProductInfo').html() == "") {
    var price = $('.SpecialOfferPrice_ProductInfo').html();
    $('.SpecialOfferPrice_ProductInfo').html("");
    $('#priceJs').html(price);
  } else {
    var priceOriginal = $('.Price_Productinfo').html();
    $('.Price_Productinfo').html("");
    $('#priceJs').html(priceOriginal);
  }
  var priceTxt = $('#prCardBuyTD .PriceStriked_Productinfo').text();
  $('#prCardBuyTD .PriceStriked_Productinfo').text("Listepris (FØR " + priceTxt + ")");


  // FIX IF EMPTY  ( hvis magiczoom ikke er slaaet til, saa fjerner denne en topdiv der skydes ind forkert, hvis der kun er 1 billede)

  if ($('#selectorWrap').html() == "") {
    $('#selectorWrap').parent().remove();
  }


  // FIX RELATED BUYBTNS
  $('.Related_BuyButton_IMG').attr('src', '/images/design/source_asa/buybtn_fpi.gif');

  //FIX HVIS BILLEDER ER MINDRE SKYDES BILLEDET UD MED ABS DENNE FJERNER ABS
  $('.MediaViewerCanvas').find('DIV').css('position', 'relative');

 
}
