Asp. NET-written browser spy

Source: Internet
Author: User
Tags tostring win32
Here is an example of an application I wrote about the HttpBrowserCapabilities component.

Examples of program execution in http://aspx1.brinkster.com/feidao/code/BrowserSpy.aspx

The following are the source programs:

<script runat= "Server" language= "C #" >
public void Page_Load (Object Source, EventArgs E)
{
HttpBrowserCapabilities bc= Request.Browser;

Welcome.text = "Hello, you are using" + BC. Browser + "v." + BC. Version + ", your running platform is" + BC. Platform;


activexcontrols.text = BC. Activexcontrols.tostring ();
Aol. Text = BC. Aol. ToString ();
backgroundsounds.text = BC. Backgroundsounds.tostring ();
beta.text = BC. Beta.tostring ();
browser.text = BC. Browser.tostring ();
Cdf. Text = BC. Cdf. ToString ();
cookies.text = BC. Cookies.tostring ();
crawler.text = BC. Crawler.tostring ();
frames.text = BC. Frames.tostring ();
javaapplets.text = BC. Javaapplets.tostring ();
javascript.text = BC. Javascript.tostring ();
majorversion.text = BC. Majorversion.tostring ();
minorversion.text = BC. Minorversion.tostring ();
platform.text = BC. Platform.tostring ();
tables.text = BC. Tables.tostring ();
type.text = BC. Type.tostring ();
vbscript.text = BC. Vbscript.tostring ();
version.text = BC. Version.tostring ();
win16.text = BC. Win16.tostring ();
win32.text = BC. Win32.tostring ();
}
</script>
<asp:label id= "Css1" runat= "Server"/>
<body>
<form runat= "Server" method= "POST" >
Your browser information has been completely in our hands ^&^:<br>
<p><asp:label runat= "Server" id= "Welcome" font-bold= "True"/></p>
<table border= "1" width= "bordercolor=" Black "cellpadding=" 4 "cellspacing=" 0 ">
<tr class= "Evenrow" bgcolor= "Skyblue" >
&LT;TD width= "50%" ><b> Browser Properties </b></td>
&LT;TD width= "50%" ><b> test results </b></td>
</tr>
<tr class= "Oddrow" >
&LT;TD width= "50%" ><b>ActiveXControls:</b></td>
&LT;TD width= "50%" ><asp:label runat= "Server" id= "ActiveXControls"/></td>
</tr>
<tr class= "Evenrow" bgcolor= "Skyblue" >
&LT;TD width= "50%" ><b>AOL:</b></td>
&LT;TD width= "50%" ><asp:label runat= "Server" id= "AOL"/></td>
</tr>
<tr class= "Oddrow" >
&LT;TD width= "50%" ><b>BackgroundSounds:</b></td>
&LT;TD width= "50%" ><asp:label runat= "Server" id= "Backgroundsounds"/></td>
</tr>
<tr class= "Evenrow" bgcolor= "Skyblue" >
&LT;TD width= "50%" ><b>Beta:</b></td>
&LT;TD width= "50%" ><asp:label runat= "Server" id= "Beta"/></td>
</tr>
<tr class= "Oddrow" >
&LT;TD width= "50%" ><b>Browser:</b></td>
&LT;TD width= "50%" ><asp:label runat= "Server" id= "Browser"/></td>
</tr>
<tr class= "Evenrow" bgcolor= "Skyblue" >
&LT;TD width= "50%" ><b>CDF:</b></td>
&LT;TD width= "50%" ><asp:label runat= "Server" id= "CDF"/></td>
</tr>
<tr class= "Oddrow" >
&LT;TD width= "50%" ><b>Cookies:</b></td>
&LT;TD width= "50%" ><asp:label runat= "Server" id= "Cookies"/></td>
</tr>
<tr class= "Evenrow" bgcolor= "Skyblue" >
&LT;TD width= "50%" ><b>Crawler:</b></td>
&LT;TD width= "50%" ><asp:label runat= "Server" id= "Crawler"/></td>
</tr>
<tr class= "Oddrow" >
&LT;TD width= "50%" ><b>Frames:</b></td>
&LT;TD width= "50%" ><asp:label runat= "Server" id= "Frames"/></td>
</tr>
<tr class= "Evenrow" bgcolor= "Skyblue" >
&LT;TD width= "50%" ><b>JavaApplets:</b></td>
&LT;TD width= "50%" ><asp:label runat= "Server" id= "Javaapplets"/></td>
</tr>
<tr class= "Oddrow" >
&LT;TD width= "50%" ><b>JavaScript:</b></td>
&LT;TD width= "50%" ><asp:label runat= "Server" id= "JavaScript"/></td>
</tr>
<tr class= "Evenrow" bgcolor= "Skyblue" >
&LT;TD width= "50%" ><b>MajorVersion:</b></td>
&LT;TD width= "50%" ><asp:label runat= "Server" id= "MajorVersion"/></td>
</tr>
<tr class= "Oddrow" >
&LT;TD width= "50%" ><b>MinorVersion:</b></td>
&LT;TD width= "50%" ><asp:label runat= "Server" id= "MinorVersion"/></td>
</tr>
<tr class= "Evenrow" bgcolor= "Skyblue" >
&LT;TD width= "50%" ><b>Platform:</b></td>
&LT;TD width= "50%" ><asp:label runat= "Server" id= "Platform"/></td>
</tr>
<tr class= "Oddrow" >
&LT;TD width= "50%" ><b>Tables:</b></td>
&LT;TD width= "50%" ><asp:label runat= "Server" id= "Tables"/></td>
</tr>
<tr class= "Evenrow" bgcolor= "Skyblue" >
&LT;TD width= "50%" ><b>Type:</b></td>
&LT;TD width= "50%" ><asp:label runat= "Server" id= "Type"/></td>
</tr>
<tr class= "Oddrow" >
&LT;TD width= "50%" ><b>VBScript:</b></td>
&LT;TD width= "50%" ><asp:label runat= "Server" id= "VBScript"/></td>
</tr>
<tr class= "Evenrow" bgcolor= "Skyblue" >
&LT;TD width= "50%" ><b>Version:</b></td>
&LT;TD width= "50%" ><asp:label runat= "Server" id= "Version"/></td>
</tr>
<tr class= "Oddrow" >
&LT;TD width= "50%" ><b>Win16:</b></td>
&LT;TD width= "50%" ><asp:label runat= "Server" id= "Win16"/></td>
</tr>
<tr class= "Evenrow" bgcolor= "Skyblue" >
&LT;TD width= "50%" ><b>Win32:</b></td>
&LT;TD width= "50%" ><asp:label runat= "Server" id= "Win32"/></td>
</tr>
</table>
</form>
</body>


Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.