#1
  1. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Apr 2008
    Posts
    58
    Rep Power
    16

    Help with javascript (php?)


    I'm using a script on an html page, to record a flash video. Part of the code is this:

    Code:
    <script type="text/javascript">
                   // <![CDATA[
                   var so = new SWFObject("recorder.swf", "recorder", "620", "470", "9", "#000000");
           	       so.addParam('flashvars','filename=sample&rtmpPath=rtmp://6tv610x0z6k.rtmphost.com/sa/&finishURL=play.html')
                   so.write("recorder");
                   // ]]>
                   </script>
    I'd like to add the ability to have each recording get a different file name. I was told "every record will have different name if you will put unique "filename" variable for each record. (using php for example)"

    Can you give me some guidance/example as how to 'put unique "filename" variable"?
    thanks
  2. #2
  3. No Profile Picture
    Gotta get to the next screen..
    Devshed Supreme Being (6500+ posts)

    Join Date
    Nov 2003
    Location
    Legion of Dynamic Discord
    Posts
    6,678
    Rep Power
    3165
    Hi, a snippet like this should do it:
    Code:
    so.addParam('flashvars','filename=<?php echo 'some-file-name' ?>&rtmpPath=rtmp://6tv610x0z6k.rtmphost.com/sa/&finishURL=play.html')
    Basically just sticking some PHP tags in there and then echo/printing out the filename for each swf.
    Quis custodiet ipsos custodes?

IMN logo majestic logo threadwatch logo seochat tools logo