Problem hiding a gridColumn after cloned


#1

www.mydubaidream.com/dubai4
select media in the hamburger.
I am using the following code to clone the gridColum (GCanim) then hide the original one

function returnedIframes() {
     //alert( 'returned iframes');
     var i =0;
     var newID;
     var newImage;
     var newTitle;
     var newURL;
     if (iframesReturned1.status == 200) { //success
          //alert('data back '+ iframesReturned1.responseText);
          dataReturned = JSON.parse(iframesReturned1.responseText);
          var newArray = [];
          newArray = dataReturned['data'];

        //for (var i = 0; i < newArray.length; i++) {
        for (var i = newArray.length - 1; i >= 0; --i) {
        newID =  'animID'+newArray[i]['anims']['animID'];
        newDiv = $('#GCanim')
        .clone(true,true)
        .attr('id', newID)   // <-- Note this line
        .insertAfter("#GRanim");
        newImage = newArray[i]['anims']['thumbnail']; //'http://www.mydubaidream.com/imageAssets/blogPage3.svg';
        newTitle = newArray[i]['anims']['title'];
        newURL = newArray[i]['anims']['url'];
        $(newDiv).find("img").attr("src",'http://'+newImage);
        $(newDiv).find(".cont1").html(newTitle);
        $(newDiv).find(".cont2").text(newURL);
            console.log(newArray[i]['anims']);
            console.log(newArray[i]['anims']['animID']);
            console.log(newArray[i]['anims']['thumbnail']);
        
      
}
        //GCanim.Height = 0;
        //GCanim.hidden = true;
        GCanim.style.display = 'none';
        
}
}

So this works as expected except in the inspector I still there is a value for GCanim height which moves the gridRow down slightly.

If I edit in the console and set it to 0 I get the correct result

How do I ensure the GCanim is ‘completely’ cleared.

Cheers

Steve Warby