Com php non penso proprio, con js si.

var width = screen.width;
var height = screen.height;