
var x, h;
if (self.innerHeight) // all except Explorer
{
	x = self.innerWidth;
	h = self.innerHeight;
}

else if (document.documentElement && document.documentElement.clientHeight)
	// Explorer 6 Strict Mode
{
	x = document.documentElement.clientWidth;
	h = document.documentElement.clientHeight;
}

else // other Explorers
{
	x = window.document.body.clientWidth;
	h = window.document.body.clientHeight;
}

document.write("<link rel='stylesheet' href='");

  if (x <= 960) {
    //resolution is 800x600 or less
    document.write("styles/screen-800.css'>");
  } else {
    document.write("styles/screenB.css'>");
  }
  