window.onresize = fixIndexLayout;

function fixIndexLayout()
{
  var width = document.getElementById("body").clientWidth;
  var height = window.innerHeight;
  if (!height) { height = document.documentElement.clientHeight; } /* Fix for IE 7 */

  if (width % 2 != 0) width++;
  if (height % 2 != 0) height++;

  document.getElementById("mannHeaderIndex").style.left = ((width / 2) - 512) + "px";
  document.getElementById("indexBox").style.left = ((width / 2) - 512) + "px";

  cookieOperations(width, height);
}
