How to pass js value to flash parameter

Discussion in 'JavaScript' started by waickw, Sep 27, 2010.

  1. #1
    Hi,
    how to pass the var sc to para res? thanks

    <script>
    if (window.screen.width < 1000) {
    var sc = 'error';
    }
    else {
    var sc = 'ok';
    }
    //document.write(sc);
    </script>

    <object type="application/x-shockwave-flash" data="flashContent.v2.swf" width="950" height="600">
    <param name="movie" value="flashContent.v2.swf" />
    <param name=FlashVars VALUE="ver=_0015&res=" />
    </object>

    Regards,
    waickw
     
    waickw, Sep 27, 2010 IP
  2. osol

    osol Peon

    Messages:
    14
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #2
    For flash javascript interaction you need to use flash ExternalInterface library.Most of the popular browsers support flash to javascript interaction this way
     
    osol, Sep 27, 2010 IP