Web Wiz - Green Windows Web Hosting

  New Posts New Posts RSS Feed - Blank page when creating new post
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Blank page when creating new post

 Post Reply Post Reply Page  <123
Author
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: 10 October 2003 at 3:30am
I'm looking at trying to find a way to detact browser versions for the next version that doesn't require the checking of decimal numbers so hopefully people won't have this problem in future of having to edit their registery on the server.
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: 10 October 2003 at 8:30am
Here is the fix for the next release that doesn't use decimal numbers in browser identifications, so no registry fixes needed.

In the file functions_common.asp change the RTEenabled() function to:-

'********************************************
'***  Rich Text Compatible Browser type *****
'********************************************

Private Function RTEenabled()

    Dim strUserAgent    'Holds info on the users browser

    'Get the users HTTP user agent (web browser)
    strUserAgent = Request.ServerVariables("HTTP_USER_AGENT")


    '*************************************
    '***** Windows Internet Explorer *****
    '*************************************
   
    'See if the user agent is IE on Winows and not Opera trying to look like IE
    If InStr(1, strUserAgent, "MSIE", 1) > 0 AND InStr(1, strUserAgent, "Win", 1) > 0 AND InStr(1, strUserAgent, "Opera", 1) = 0 Then

        'Now we know this is Windows IE we need to see if the version number is 5
        If Trim(Mid(strUserAgent, CInt(inStr(1, strUserAgent, "MSIE", 1)+5), 1)) = "5" Then

            RTEenabled = "winIE5"
       
        'Now we know this is Windows IE we need to see if the version number is above 5
        ElseIf CInt(Trim(Mid(strUserAgent, CInt(inStr(1, strUserAgent, "MSIE", 1)+5), 1))) => 6 Then

            RTEenabled = "winIE"

        'Else the IE version is below 5 so return na
        Else

            RTEenabled = "false"
        End If
       
       
    '****************************
    '***** Mozilla Firebird *****
    '****************************
   
    'See if this is a version of Mozilla Firebird that supports Rich Text Editing under it's Midas API
    ElseIf inStr(1, strUserAgent, "Firebird", 1) Then
       
        'Now we know this is Mozilla Firebird we need to see if the version 0.6.1 or above; relase date is above 2003/07/28
        If CLng(Trim(Mid(strUserAgent, CInt(inStr(1, strUserAgent, "Gecko/", 1)+6), 8))) => 20030728 Then

            RTEenabled = "Gecko"

        'Else the Mozilla Firebird version is below 1.5 so return false
        Else

            RTEenabled = "false"
        End If
   
   
    '**************************************
    '***** Mozilla Seamonkey/Netscape *****
    '**************************************
   
    'See if this is a version of Mozilla/Netscape that supports Rich Text Editing under it's Midas API
    ElseIf inStr(1, strUserAgent, "Gecko", 1) > 0 AND inStr(1, strUserAgent, "Firebird", 1) = 0 AND isNumeric(Trim(Mid(strUserAgent, CInt(inStr(1, strUserAgent, "Gecko/", 1)+6), 8))) Then
       
        'Now we know this is Mozilla/Netscape we need to see if the version number is above 1.3 or above; relase date is above 2003/03/12
        If CLng(Trim(Mid(strUserAgent, CInt(inStr(1, strUserAgent, "Gecko/", 1)+6), 8))) => 20030312 Then

            RTEenabled = "Gecko"

        'Else the Mozilla version is below 1.3 or below 7.1 of Netscape so return false
        Else

            RTEenabled = "false"
        End If
   
   
   
    '***********************************
    '***** Non RTE Enabled Browser *****
    '***********************************
   
    'Else this is a browser that does not support Rich Text Editing
    Else
        'RTEenabled - false
        RTEenabled = "false"
    End If
   
End Function



Edited by -boRg-
Back to Top
WebKnight View Drop Down
Newbie
Newbie
Avatar

Joined: 13 October 2003
Location: Norway
Status: Offline
Points: 3
Post Options Post Options   Thanks (0) Thanks(0)   Quote WebKnight Quote  Post ReplyReply Direct Link To This Post Posted: 13 October 2003 at 5:29am

Thank You! This solution worked for me

Back to Top
huwnet View Drop Down
Senior Member
Senior Member


Joined: 30 May 2003
Location: England
Status: Offline
Points: 1375
Post Options Post Options   Thanks (0) Thanks(0)   Quote huwnet Quote  Post ReplyReply Direct Link To This Post Posted: 13 October 2003 at 10:51am
It now works fine! Please delete my account test101 on your site!
Back to Top
josk View Drop Down
Mod Builder Group
Mod Builder Group
Avatar

Joined: 10 June 2003
Location: Finland
Status: Offline
Points: 42
Post Options Post Options   Thanks (0) Thanks(0)   Quote josk Quote  Post ReplyReply Direct Link To This Post Posted: 14 October 2003 at 12:05am

Now it works for me! Thanks bOrg!

Back to Top
 Post Reply Post Reply Page  <123

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.