Questions tagged [httpbrowsercapabilities]
35 questions
31
votes
12 answers
how do I detect user operating system
I have the following code to obtain user details:
HttpBrowserCapabilities bc = HttpContext.Current.Request.Browser;
string UserAgent = HttpContext.Current.Request.UserAgent;
ENT_TrackingData ret = new ENT_TrackingData()
{
IPAddress =…

Funky
- 12,890
- 35
- 106
- 161
11
votes
2 answers
How to get browser "Document Mode"
I am developing some kind of JavaScript library. And i cause the problem that i have some specific issues for:
Browser : IE8 / IE9 and Document Mode : IE7
I found the solution, but i don't want to use it in all situation, and want to use it just…

Mikhail
- 759
- 2
- 9
- 26
4
votes
4 answers
Backspace or Delete key In TextBox with Masked Edit Extender in ASP.NET not working in Chrome

Boss
- 445
- 2
- 8
- 24
4
votes
1 answer
How definitions for browser capabilities are updated in .NET Framework?
I want to use HttpBrowserCapabilities in order to gather statistics about the devices used to access a website.
As far as I know, HttpBrowserCapabilities is based on .browser files in %SystemRoot%\Microsoft.NET\Framework\version\CONFIG\Browsers…

Arseni Mourzenko
- 50,338
- 35
- 112
- 199
3
votes
1 answer
.NET Request Browser identifies Opera as Chrome
So in my code I have:
return Request.Browser.Browser + " " + Request.Browser.MajorVersion
When I user Opera, I've had version 21 and now the latest version 33, but my code always returns Chrome. It returned "Chrome 34" for Opera 21, and "Chrome…

Ben
- 2,388
- 4
- 18
- 16
3
votes
1 answer
Request Browser returning InternetExplorer instead of IE with Default user agent
According to Microsoft's documentation for HttpCapabilitiesBase.Browser Property, you can check for Internet Explorer using the following code.
System.Web.HttpBrowserCapabilities myBrowserCaps = Request.Browser;
if…

Zach L
- 1,277
- 4
- 18
- 37
3
votes
1 answer
what is the default Cacheability of a page ? asp.net IE
After having this issue on our websites over secure SSL connections for Office file download with Cacheability setting. I am wondering what would be the correct setting to use.
If I completely remove this following line of code, what would be the…

Laurence
- 7,633
- 21
- 78
- 129
2
votes
3 answers
Can I detect IE Document Mode on the server side using the HttpBrowserCapabilities object
I can find out the browser version and specific capabilities using the HttpBrowserCapabilities object, but is there a way I can find the Document Mode that the browser is using to render?
The equivalent of the JavaScript property…

Andy McCluggage
- 37,618
- 18
- 59
- 69
2
votes
1 answer
Is there a chance to use App_Browsers to detect support of the HTML5 File API?
Using the HTML5 File API to upload files, I am currently using some hardcoded checking of the browsers that support them, depending on the user agent string:
internal bool IsHtml5FileUploadCapable
{
get
{
var browser =…

Uwe Keim
- 39,551
- 56
- 175
- 291
2
votes
1 answer
inconsistent browser type value from request object
I am writing a C# application in which I need to retrieve the users browser type.
I get the above from the Request object, specifically from: Request.Browser.Type which a member of System.Web.HttpBrowserCapabilitiesBase.
The result I get from this…

amateur
- 43,371
- 65
- 192
- 320
2
votes
3 answers
check if browser supports data uri at run time
I am looking to use data uri base 64 strings in my asp.net c# web application. I know only some browsers support this, so at runtime I will need to check if the current browser supports base 64 strings.
From the users request object, I can access…

amateur
- 43,371
- 65
- 192
- 320
2
votes
1 answer
Browser capabilities in TestCafe
I have been using a web app in chrome (a meeting client) which makes use of webRTC (Need mic and camera access) while trying to use locally installed chrome browser for executing tests.
Chrome instance triggered by Testcafe is not allowing the…

Bharadwaj Pendyala
- 324
- 1
- 3
- 16
2
votes
1 answer
Detect whether the ie8 xss filter is enabled
Is there a method by which we can detect if a user using ie8 has the XSS filter enabled?
As far as I can tell, nothing changes in the User Agent or in the http headers when ie8 has the XSS filter enabled vs when it does not. That leaves some…

Bernard Chen
- 6,437
- 5
- 23
- 27
2
votes
5 answers
alternative to get_browser?
I have been using php's get_browser() function to do some light analytics of my users, mostly for debugging. However, it seems that the maintainer for browsercap.ini, the data that powers get_browser has quit the project, and while some folks seem…

Matt
- 1,287
- 2
- 11
- 25
1
vote
2 answers
HttpBrowserCapabilities Custom Browser file parsing
If I have a custom .browser file, and I want to evaluate what will happen if it is given a particular User Agent, is there any way to do that through the .NET API?
I was attempting to use HttpBrowserCapabilites, but I'm not sure how to load a custom…

DevinB
- 8,231
- 9
- 44
- 54