Print Page | Close Window

browserDetect function problem

Printed From: Web Wiz Forums
Category: Web Wiz Web App Support Forums
Forum Name: Web Wiz Forums
Forum Description: Support forum for Web Wiz Forums application.
URL: https://forums.webwiz.net/forum_posts.asp?TID=24969
Printed Date: 04 April 2026 at 2:14am
Software Version: Web Wiz Forums 12.08 - https://www.webwizforums.com


Topic: browserDetect function problem
Posted By: kiklop
Subject: browserDetect function problem
Date 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





-------------
http://www.dyxum.com" rel="nofollow - dyxum.com



Replies:
Posted By: WebWiz-Bruce
Date Posted: 09 December 2007 at 12:21pm
Will look at adding more error handling for this in the next release.

-------------
https://www.webwiz.net/web-wiz-forums/forum-hosting.htm" rel="nofollow - Web Wiz Forums Hosting
https://www.webwiz.net/web-hosting/windows-web-hosting.htm" rel="nofollow - ASP.NET Web Hosting


Posted By: kiklop
Date 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


-------------
http://www.dyxum.com" rel="nofollow - dyxum.com


Posted By: WebWiz-Bruce
Date 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.


-------------
https://www.webwiz.net/web-wiz-forums/forum-hosting.htm" rel="nofollow - Web Wiz Forums Hosting
https://www.webwiz.net/web-hosting/windows-web-hosting.htm" rel="nofollow - ASP.NET Web Hosting



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.08 - https://www.webwizforums.com
Copyright ©2001-2026 Web Wiz Ltd. - https://www.webwiz.net