Passing variables into flash using Javascript

On my web page - http://lmi-inc.dev.webriverinteractive.com/ I have two menu links at the top of the page, core services and support services. If I click on either of these it loads a seperate web page and takes me to the correct spot in the flash movie. But I really only want to load one web page but funnel the id of each html link into the flash code below.

I set up a variable called qsParm to capture the query string id value but I don’t know how to code the qsParm variable into the AC_FL Run Content. All I have been able to do is hard code the id value.

‘movie’, ‘LMI-services?id=core’,

Can someone help me figure how to do this? Thanks:emb:


 <script language="JavaScript" type="text/javascript">    
                    //<!--this java script code checks the isOn state and switches the class to an selected sate-->
                    var qsParm = new Array();
                    function qs() {
                        var query = window.location.search.substring(1);
                        var parms = query.split('&');
                        for (var i=0; i<parms.length; i++) {
                            var pos = parms*.indexOf('=');
                            if (pos > 0) {
                                var key = parms*.substring(0,pos);
                                var val = parms*.substring(pos+1);
                                qsParm[key] = val;
                            }
                        }
                    }     
                    
                    qsParm['id'] = null;        
                    qs(); 
                    // document.write('You selected ' + qsParm['id']);
                    //alert("isOn="+qsParm['isOn']+ "isMedia="+qsParm['isMedia'] +"isPhoto="+qsParm['isPhoto']);    
                    //document.getElementById('ab').style.backgroundColor="#000000";                        
                    <!--
                    if (AC_FL_RunContent == 0 || DetectFlashVer == 0) {
                        alert("This page requires AC_RunActiveContent.js.");
                    } else {
                        var hasRightVersion = DetectFlashVer(requiredMajorVersion, requiredMinorVersion, requiredRevision);
                        if(hasRightVersion) {  // if we've detected an acceptable version
                            // embed the flash movie
                            AC_FL_RunContent(
                                'codebase', 'http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,115,0',
                                'width', '710',
                                'height', '500',
                                'src', 'LMI-services',
                                'quality', 'high',
                                'pluginspage', 'http://www.macromedia.com/go/getflashplayer',
                                'align', 'middle',
                                'play', 'true',
                                'loop', 'true',
                                'scale', 'showall',
                                'wmode', 'transparent',
                                'devicefont', 'false',
                                'id', 'LMI-services',
                                'bgcolor', '#ffffff',
                                'name', 'LMI-services',
                                'menu', 'true',
                                'allowScriptAccess','sameDomain',
                                'allowFullScreen','false',
                                'movie', 'LMI-services?id=core',
                                'salign', ''
                                ); //end AC code
                        } else {  // flash is too old or we can't detect the plugin
                            var alternateContent = 'Alternate HTML content should be placed here.'
                                + 'This content requires the Adobe Flash Player.'
                                + '<a href=http://www.macromedia.com/go/getflash/>Get Flash</a>';
                            document.write(alternateContent);  // insert non-flash content
                        }
                    }
                    // -->
                    </script>
                    <noscript>
                        // Provide alternate content for browsers that do not support scripting
                        // or for those that have scripting disabled.
                          Alternate HTML content should be placed here. This content requires the Adobe Flash Player.
                          <a href="http://www.macromedia.com/go/getflash/">Get Flash</a>
                    </noscript>