quinta-feira, 27 de dezembro de 2007

BrowserInfo()

Pega informações sobre o browser do usuário.

Exemplo:
var b = new BrowserInfo();
alert(b.version);


function BrowserInfo()
{

this.name = navigator.appName;

this.codename = navigator.appCodeName;

this.version = navigator.appVersion.substring(0,4);

this.platform = navigator.platform;

this.javaEnabled = navigator.javaEnabled();

this.screenWidth = screen.width;

this.screenHeight = screen.height;

}

Nenhum comentário: