//$Id: color.php,v 95841a8db07c 2012/01/20 23:47:51 Mike $ function TurnOffPrId(prId) { if(jQuery) { //console.log('hate something else'); $('[id='+prId+']').css('display', 'none'); } else { var elementtohide = document.getElementById(prId); if(elementtohide != undefined) elementtohide.style.display = 'none'; } } function exchange(idOne, idTwo, tableID) { if(tableID == 'dynamicShop') { if(parseInt(idOne) != parseInt(idTwo) ) { $('div#dynamicShop div#'+idTwo).before($('#'+idOne)); } idTwo = $('div#dynamicShop div.colorMaster_'+idTwo+'.colorSelected').attr('id'); $('div#dynamicShop div#'+idOne).css('display', ''); $('div#dynamicShop div#'+idTwo).removeClass('colorSelected'); $('div#dynamicShop div#'+idOne).addClass('colorSelected'); } else if (tableID == 'accTable') { if(parseInt(idOne) != parseInt(idTwo) ) { $('#'+idTwo).before($('#'+idOne)); } $('#'+idOne).css('display', ''); } else if (tableID == 'promo') { if(idOne != idTwo) { $('li#'+idTwo).before($('#'+idOne)); } $('li#'+idTwo).addClass('visibilityNo'); $('li#'+idOne).css('display', ''); $('li#'+idOne).removeClass('visibilityNo'); } else { var rowOne = document.getElementById(idOne); var rowTwo = document.getElementById(idTwo); var currentTable = document.getElementById(tableID); var trs = currentTable.tBodies[0].getElementsByTagName("tr"); var i = rowOne.rowIndex; var j = rowTwo.rowIndex; if(trs[i] != undefined && trs[j] != undefined && tableID != 'accTable') { currentTable.tBodies[0].insertBefore(rowOne, rowTwo); } rowOne.style.display = ''; } }