This is a discussion on Apache and Javascript within the Apache Web Server forums, part of the Web Server and Related Forums category; Hi All, Sorry, I'm still learning. Does Apache read the header information sent by a users browser, or do ...
|
|||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
|
|||
|
Hi All,
Sorry, I'm still learning. Does Apache read the header information sent by a users browser, or do I have to configure it to do so? If I have to configure it, how do I do it? I have run into several problems which I suspect are related to this issue. For example, I need to detect the browser type which is accessing a website. The following is a browser detection page, but the variable 'navigator.appname' always returns a value of "undefined", no matter which browser I use. I can't find any reference to this issue in the manual, so any guidance you can provide, I'd really appreciate. Thanks in advance, Jim <DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <title>Browser Type</title> </head> <body bgcolor="#FFFFFF"> <h1> <script language="Javascript" type="text/javascript"> <!-- hide script document.write(navigator.appname) //stop hiding script --> </script> </h1> </body> </html> |
|
|||
|
"James Warren" <noSpamNews@jdwarren.us> schreef in bericht
news:4fBte.994204$w62.214451@bgtnsc05-news.ops.worldnet.att.net... > Hi All, > Sorry, I'm still learning. > Does Apache read the header information sent by a users browser, Yes, it will take notice of things like character set, prefered language and the ability to recieve compressed data. Some headers, like browser name, are usually just logged. > or do I have to configure it to do so? > If I have to configure it, how do I do it? You do not want to know ... > I have run into several problems which I suspect are related to this issue. > For example, I need to detect the browser type which is accessing a website. > The following is a browser detection page, but the variable > 'navigator.appname' always returns a value of "undefined", no matter which > browser I use. I can't find any reference to this issue in the manual, so > any guidance you can provide .... JavaScript runs on the client computer as part of the browser and has about nothing to do with the server running apache. > <DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"> > <html xmlns="http://www.w3.org/1999/xhtml"> > <head> > <title>Browser Type</title> > </head> > <body bgcolor="#FFFFFF"> > <h1> > <script language="Javascript" type="text/javascript"> > <!-- hide script > > document.write(navigator.appname) > > //stop hiding script > --> > </script> > </h1> > </body> > </html> > Object names are case sensitive : document.write(navigator.appName) works fine with me http://www.mozilla.org/docs/dom/domr...dow_ref38.html HansH |
|
|||
|
Thanks Hans!
I continue to learn! Being a Visual Basic programmer has made me very lazy about watching cases. I entered your correction, and well...problem solved. Again, thanks Jim "HansH" <hans@niet.op.het.net> wrote in message news:42b6ff0e$0$14048$e4fe514c@news.xs4all.nl... > "James Warren" <noSpamNews@jdwarren.us> schreef in bericht > news:4fBte.994204$w62.214451@bgtnsc05-news.ops.worldnet.att.net... >> Hi All, >> Sorry, I'm still learning. >> Does Apache read the header information sent by a users browser, > Yes, it will take notice of things like character set, prefered language > and > the ability to recieve compressed data. > Some headers, like browser name, are usually just logged. > >> or do I have to configure it to do so? > >> If I have to configure it, how do I do it? > You do not want to know ... > >> I have run into several problems which I suspect are related to this > issue. > >> For example, I need to detect the browser type which is accessing a > website. >> The following is a browser detection page, but the variable >> 'navigator.appname' always returns a value of "undefined", no matter >> which >> browser I use. I can't find any reference to this issue in the manual, >> so >> any guidance you can provide > ... JavaScript runs on the client computer as part of the browser and has > about nothing to do with the server running apache. > >> <DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"> >> <html xmlns="http://www.w3.org/1999/xhtml"> >> <head> >> <title>Browser Type</title> >> </head> >> <body bgcolor="#FFFFFF"> >> <h1> >> <script language="Javascript" type="text/javascript"> >> <!-- hide script >> >> document.write(navigator.appname) >> >> //stop hiding script >> --> >> </script> >> </h1> >> </body> >> </html> >> > Object names are case sensitive : > document.write(navigator.appName) works fine with me > http://www.mozilla.org/docs/dom/domr...dow_ref38.html > > HansH > > |