update the browsercaps section in machine.config
the agent string for safari look like:
Mozilla/5.0 (Macintosh; U; PPC Mac OS X; en-us) AppleWebKit/xx (KHTML, like
Gecko) Safari/yy
where xx is the os build number and yy is briowser build number
-- bruce (sqlwork.com)
<> wrote in message
news: oups.com...
> The code bellow must be executed under safari web-browser.
>
> I need to know how I can get the major version of the safari
> web-browser.
>
> Thanks in advance
>
> vb.net code
> Partial Class SafariTest
> Inherits System.Web.UI.Page
>
> Protected Sub Page_Load(ByVal sender As Object, ByVal e As
> System.EventArgs) Handles Me.Load
> Label1.Text = "Request.Browser.MajorVersion.ToString():" +
> Request.Browser.MajorVersion.ToString()
>
> End Sub
> End Class
>
> <%@ Page Language="VB" AutoEventWireup="false"
> CodeFile="SafariTest.aspx.vb" Inherits="SafariTest" %>
>
> aspx code
> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
> "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
>
> <html xmlns="http://www.w3.org/1999/xhtml" >
> <head runat="server">
> <title>Untitled Page</title>
> </head>
> <body>
> <form id="form1" runat="server">
> <div>
> <asp:Label ID="Label1" runat="server"
> Text="Label"></asp:Label><br />
>
> </div>
> </form>
> </body>
> </html>
>
|