7 Replies Latest reply on Sep 6, 2009 1:41 PM by __antonio__

    2 flash elements on a page but only 1 loads

    Nicholas M Level 1

      Hi there,

       

      I'm a relative newbie, and have purchased 2 flash elements - a video player and an accordion menu - to fit on the index page of a site i am building.  Individually they work perfectly fine on the page, but with both of them together coded into the page, only the video player works and it actually physically moves over to where the accordion sits (on the left hand side).  I've tried everything i can think of to get it to work.  The SWF files sits in different folders.  Can anyone suggest why this might be happening and a possible remedy?

       

      The page is here : http://www.overloadweb.com.au/demo/clique/flash_test.html

       

      I'd appreciate any help!
      Thanks
      Nic

        • 1. Re: 2 flash elements on a page but only 1 loads
          __antonio__ Level 3

          I just took a look, didnt get it to replicate the issues.

           

          using Firefox and FP 10

          • 2. Re: 2 flash elements on a page but only 1 loads
            Nicholas M Level 1

            Hi,

            Thanks Antonio,

            You'll be looking at 2 panels at the moment which are both part of the video.  Beneath the left panel (ie the video menu), there should actually be another accordion menu.

             

            So in effect, there should be 3 boxes from the left - an accordion menu, the video menu, and the video player...It's the accordion that has disappeared but i can't understand why...


            Thanks

            Nic

            • 3. Re: 2 flash elements on a page but only 1 loads
              __antonio__ Level 3

              Do they both have the same instance names or Base Class ids?

               

              Usually youll get a compiler error if this is the case.

              • 4. Re: 2 flash elements on a page but only 1 loads
                Nicholas M Level 1

                Hmm, a bit confused about what this is - however, both use swfobject and i can see a classid that is the same on both (maybe that's okay?)(the class id is classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\ )...

                 

                I'm not gettin any error though - it just doesn't appear on the page...

                 

                This is the code on the HTML page:

                <div id="mainBody">  <div class="leftColumn">
                 
                  <div id="flashcontent"> You need to upgrade your Flash Player</div>
                <script type="text/javascript">
                  // <![CDATA[
                   
                  var so = new SWFObject("accordion/accordion.swf", "flash", "260", "100%", "8", "#000000");
                  so.addVariable("xml", "data.xml?time="+new Date().getTime())
                  so.write("flashcontent");
                 
                  // ]]>
                </script>
                 

                  </div>
                 
                  <div class="rightColumn">

                   
                   <div id="flashcontent"  style= "width: 100%; height: 100%; margin: 0!important;">
                   
                    <script type="text/javascript">
                  var so = new SWFObject("preview.swf", "multi flash video gallery", "740", "360", "9", "#ffffff");
                  so.addParam("quality", "high");
                  so.addParam("allowFullScreen", "true");
                                so.addParam("flashvars",GetUrlParms());
                  so.addParam("loop", "false");
                  so.write("flashcontent");

                function GetUrlParms(){

                     var args=new Object();  
                     var query=location.search.substring(1);  
                     var pairs=query.split("&"); 
                     for(var i=0;i<pairs.length;i++){  
                         var pos=pairs[i].indexOf('='); 
                            if(pos==-1)   continue; 
                             var argname=pairs[i].substring(0,pos); 
                            var value=pairs[i].substring(pos+1); 
                            args[argname]=unescape(value);
                   
                    }
                flahsVar = "menuID="+args["menuID"]+"&subMenuID="+args["subMenuID"]+"&flvID="+args["flvID"];
                        return flahsVar;

                </script></div></div>
                  </div>

                 

                 

                Thanks for your help!
                Nic

                • 5. Re: 2 flash elements on a page but only 1 loads
                  __antonio__ Level 3

                  ok, so based on your html, and based on your decription of how its supposed to work, I see nothing wrong.

                   

                  Heres what I see:

                  When I click on the top of the left column I get a drop down with 2 buttons. Click on one of those buttons and I get more videos to chose from. Click on a thumbnail and get the video player to swap video. Is this how it is supposed to work?

                   

                  your code doesnt show three swfs

                  • 6. Re: 2 flash elements on a page but only 1 loads
                    Nicholas M Level 1

                    Hi Antonio,

                     

                    What you're seeing is the second flash element - there are 2 parts of this element (a menu section and the actual player).  What's missing is the first flash element which has for some reason disappeared from the page (even though it shows in the HTML).  This first flash element (which is missing) is a vertical accordion drop down with 3 images.

                     

                    Thanks again,
                    Nic

                    • 7. Re: 2 flash elements on a page but only 1 loads
                      __antonio__ Level 3

                      OK I get you now. Easy fix. The <div> with preview swf is simply overlaying the <div> with accordian.swf. Try giving your divs and swfs absolute values for width. Then, move the column right div to the right in your style: <div class="rightColumn" style="margin:0 260px 0 0"> or something simliar

                       

                      The first one - leftColumn - didnt disappear, its just being overlayed by rightColumn.