Print Page | Close Window

User’s CPU

Printed From: Web Wiz Forums
Category: General Discussion
Forum Name: Classic ASP Discussion
Forum Description: Discussion on Active Server Pages (Classic ASP).
URL: https://forums.webwiz.net/forum_posts.asp?TID=2609
Printed Date: 29 March 2026 at 9:21am
Software Version: Web Wiz Forums 12.08 - https://www.webwizforums.com


Topic: User’s CPU
Posted By: zMaestro
Subject: User’s CPU
Date Posted: 11 May 2003 at 2:53pm

Is there a way I can know the Processor of my web page visitor? just for collecting statisics

I read in an IBM book a ServerVariable that can do the job but didn't work:

 

HTTP_UA_CPU (I.E. 3+ only) Client's computer CPU type.

can anyone help




Replies:
Posted By: MadDog
Date Posted: 11 May 2003 at 3:51pm

Ive never heard of any coding type getting the comps info (like cpu and ram). You would have to have like an ActiveX script to do that.



-------------
http://www.iportalx.net" rel="nofollow">


Posted By: michael
Date Posted: 11 May 2003 at 4:20pm
You are corrent this servervariable does exit but it has been taken off from MS since IE 4.x, and it was only reported with IE anyway so netscape etc users would always be blank. You could theoretically use a javascript function which is extremely in-accurate though. It all depends on cpu, ram, load etc. but you might wanna use it as a benchmark.
function test_cpu(force){
var d=doc;dc=d.cookie,dcr=/CpuSpeed=([^;]+);/,r=dcr.exec(dc)

if (r&&!force){
  mhz = r[1]
} else {
  var average,t1,t2,t,l,report=0,passes,offset=d.all?110:150

  passes = 40

  for (l=0;l<passes;l++){
   t1 = new Date().getTime()
   for (t=0;t<20000;t++){}
   t2 = new Date().getTime()
   report += t2-t1
  }
  average = report/passes

  mhz = parseInt((65/average)*offset)
  d.cookie = 'CpuSpeed=' + mhz + ';'
} return mhz
}


-------------
http://baumannphoto.com" rel="nofollow - Blog | http://mpgtracker.com" rel="nofollow - MPG Tracker


Posted By: zMaestro
Date Posted: 11 May 2003 at 4:22pm

I read this in an IBM Training book.

ProsoftTraining.com
Active Server Pages
Appendix-10
Version 2.17

 



Posted By: michael
Date Posted: 11 May 2003 at 6:09pm
Well if they still tech that the book is obsolete.

-------------
http://baumannphoto.com" rel="nofollow - Blog | http://mpgtracker.com" rel="nofollow - MPG Tracker



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.08 - https://www.webwizforums.com
Copyright ©2001-2026 Web Wiz Ltd. - https://www.webwiz.net