Web Wiz - Green Windows Web Hosting

  New Posts New Posts RSS Feed - browserDetect function problem
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

browserDetect function problem

 Post Reply Post Reply
Author
kiklop View Drop Down
Groupie
Groupie


Joined: 14 July 2005
Status: Offline
Points: 137
Post Options Post Options   Thanks (0) Thanks(0)   Quote kiklop Quote  Post ReplyReply Direct Link To This Post Topic: browserDetect function problem
    Posted: 09 December 2007 at 10:33am
This is something that won't affect many sites however i thought i may share it.
I spotted recently that a bot under the name of StackRambler/2.0 (MSIE incompatible) is visiting my site.
HTTP_USER_AGENT  info of that particular browser causes the following error

Type mismatch: 'CInt'

in the

/functions_common.asp

lines

'MSIE 6 or below

        If  CInt(Trim(Mid(strUserAgent, CInt(inStr(1, strUserAgent, "MSIE", 1)+5), 1))) <= 6 Then
            browserDetect = "MSIE6-"
        Else
            browserDetect = "MSIE"
        End If



Back to Top
WebWiz-Bruce View Drop Down
Admin Group
Admin Group
Avatar
Web Wiz Developer

Joined: 03 September 2001
Location: Bournemouth
Status: Offline
Points: 9844
Post Options Post Options   Thanks (0) Thanks(0)   Quote WebWiz-Bruce Quote  Post ReplyReply Direct Link To This Post Posted: 09 December 2007 at 12:21pm
Will look at adding more error handling for this in the next release.
Back to Top
kiklop View Drop Down
Groupie
Groupie


Joined: 14 July 2005
Status: Offline
Points: 137
Post Options Post Options   Thanks (0) Thanks(0)   Quote kiklop Quote  Post ReplyReply Direct Link To This Post Posted: 25 January 2008 at 6:03pm
I updated the functions_common.asp today (with the newest version) and saw that this is still causing problems (i disabled this check in my former file)

Error: Type mismatch: 'CLng'
browser: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; en) Opera 9.25

code: If CLng(Trim(Mid(strUserAgent, CInt(inStr(1, strUserAgent, "Opera/", 1)+6), 1))) => 9 Then

hope it helps
Back to Top
WebWiz-Bruce View Drop Down
Admin Group
Admin Group
Avatar
Web Wiz Developer

Joined: 03 September 2001
Location: Bournemouth
Status: Offline
Points: 9844
Post Options Post Options   Thanks (0) Thanks(0)   Quote WebWiz-Bruce Quote  Post ReplyReply Direct Link To This Post Posted: 26 January 2008 at 6:09pm
This has been fixed, however due to many other changes it will not be part of the release till version 10

The latest release 9.07 was a security release so only updated those page that the security vulnerability effected.
Back to Top
 Post Reply Post Reply

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.08
Copyright ©2001-2026 Web Wiz Ltd.


Become a Fan on Facebook Follow us on X Connect with us on LinkedIn Web Wiz Blogs
About Web Wiz | Contact Web Wiz | Terms & Conditions | Cookies | Privacy Notice

Web Wiz is the trading name of Web Wiz Ltd. Company registration No. 05977755. Registered in England and Wales.
Registered office: Web Wiz Ltd, Unit 18, The Glenmore Centre, Fancy Road, Poole, Dorset, BH12 4FB, UK.

Prices exclude VAT at 20% unless otherwise stated. VAT No. GB988999105 - $, € prices shown as a guideline only.

Copyright ©2001-2026 Web Wiz Ltd. All rights reserved.