Web Wiz - Green Windows Web Hosting

  New Posts New Posts RSS Feed - FLASHVARS needed...
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

FLASHVARS needed...

 Post Reply Post Reply
Author
doggiepowers View Drop Down
Newbie
Newbie
Avatar

Joined: 07 August 2006
Location: United States
Status: Offline
Points: 3
Post Options Post Options   Thanks (0) Thanks(0)   Quote doggiepowers Quote  Post ReplyReply Direct Link To This Post Topic: FLASHVARS needed...
    Posted: 07 August 2006 at 6:34pm
ok so i'm looking at the coding for FLASH insertion into the forum, but i want to have a way where they can include FLASHVARS into the Flash coding. the only thing is i have no idea how to put it together. anyone have a code to put it into the functions_format_post.asp file?

to help the flash format is around line 712
Back to Top
doggiepowers View Drop Down
Newbie
Newbie
Avatar

Joined: 07 August 2006
Location: United States
Status: Offline
Points: 3
Post Options Post Options   Thanks (0) Thanks(0)   Quote doggiepowers Quote  Post ReplyReply Direct Link To This Post Posted: 07 August 2006 at 7:00pm
Ok I figured it out but for anyone else who would like to include following RED 9 lines into their code do the following from lines 712 to 830:

[code]

'******************************************
'***       Format Flash File Support    ***
'******************************************

'This function formats falsh codes
Function formatFlash(ByVal strMessage)


    'Declare variables
    Dim lngStartPos        'Holds search start postions
    Dim lngEndPos        'Holds end start postions
    Dim saryFlashAttributes 'Holds the features of the input flash file
    Dim intAttrbuteLoop    'Holds the attribute loop counter
    Dim strFlashWidth    'Holds the string value of the width of the Flash file
    Dim intFlashWidth    'Holds the interger value of the width of the flash file
    Dim strFlashHeight    'Holds the string value of the height of the Flash file
    Dim intFlashHeight    'Holds the interger value of the height of the flash file
    Dim strBuildFlashLink    'Holds the converted BBcode for the flash file
    Dim strTempFlashMsg    'Tempoary store for the BBcode
    Dim strFlashLink    'Holds the link to the flash file
    Dim strFlashVars    'Holds the FLASHVARS for the flash file



    'Loop through all the codes in the message and convert them to formated flash links
    Do While InStr(1, strMessage, "[FLASH", 1) > 0 AND InStr(1, strMessage, "[/FLASH]", 1) > 0

        'Initiliase variables
        intFlashWidth = 50
        intFlashHeight = 50
        strFlashLink = ""
        strFlashVars = ""
        strBuildFlashLink = ""
        strTempFlashMsg = ""

        'Get the Flash BBcode from the message
        lngStartPos = InStr(1, strMessage, "[FLASH", 1)
        lngEndPos = InStr(lngStartPos, strMessage, "[/FLASH]", 1) + 8

        'Make sure the end position is not in error
        If lngEndPos < lngStartPos Then lngEndPos = lngStartPos + 6

        'Get the original Flash BBcode from the message
        strTempFlashMsg = Trim(Mid(strMessage, lngStartPos, lngEndPos-lngStartPos))




        'Get the start and end in the message of the attributes of the Flash file
        lngStartPos = InStr(1, strTempFlashMsg, "[FLASH", 1) + 6
        lngEndPos = InStr(lngStartPos, strTempFlashMsg, "]", 1)

        'Make sure the end position is not in error
        If lngEndPos < lngStartPos Then lngEndPos = lngStartPos

        'If there is something returned get the details (eg. dimensions) of the flash file
        If strTempFlashMsg <> "" Then

            'Place any attributes for the flash file in an array
            saryFlashAttributes = Split(Trim(Mid(strTempFlashMsg, lngStartPos, lngEndPos-lngStartPos)), " ")

            'Get the dimensions of the Flash file
            'Loop through the array of atrributes that are for the falsh file to get the dimentions
            For intAttrbuteLoop = 0 To UBound(saryFlashAttributes)

                'If this is the width attribute then read in the width dimention
                If InStr(1, saryFlashAttributes(intAttrbuteLoop), "WIDTH=", 1) Then

                    'Get the width dimention
                    strFlashWidth = Replace(saryFlashAttributes(intAttrbuteLoop), "WIDTH=", "", 1, -1, 1)

                    'Make sure we are left with a numeric number if so convert to an interger and place in an interger variable
                    If isNumeric(strFlashWidth) Then intFlashWidth = CInt(strFlashWidth)
                End If

                'If this is the height attribute then read in the height dimention
                If InStr(1, saryFlashAttributes(intAttrbuteLoop), "HEIGHT=", 1) Then

                    'Get the height dimention
                    strFlashHeight = Replace(saryFlashAttributes(intAttrbuteLoop), "HEIGHT=", "", 1, -1, 1)

                    'Make sure we are left with a numeric number if so convert to an interger and place in an interger variable
                    If isNumeric(strFlashHeight) Then intFlashHeight = CInt(strFlashHeight)
                End If

                'If this is the flashvars attribute then read in the flashvars dimention
                If InStr(1, saryFlashAttributes(intAttrbuteLoop), "FLASHVARS=", 1) Then

                    'Get the flashvars dimention
                    strFlashVars = Replace(saryFlashAttributes(intAttrbuteLoop), "FLASHVARS=", "", 1, -1, 1)
                End If


            Next



            'Get the link to the flash file
            lngStartPos = InStr(1, strTempFlashMsg, "]", 1) + 1
            lngEndPos = InStr(lngStartPos, strTempFlashMsg, "[/FLASH]", 1)

            'Make sure the end position is not in error
            If lngEndPos < lngStartPos Th
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.