We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 14867
    • 65 Posts
    I have a Problem with including a Flash file.
    I tried to put the original code from the html file generated by flash into my sourcecode : doesn’t work
    I tried to include the file with my FCKEditor but no effect.

    when i start the original html file or include it with an iframe its working. But thats not the way i want it to work...
    Is this a known problem or can someone help me ?

    here ist the test page where i includet 2 swf files and an iframe ( swf above iframe )
    maybe you could help me ...
    (sorry for my bad english)
    http://www.cleverontour.de/index.php?id=25
      42
      • 2762
      • 1,198 Posts
      Very strange issue .. can you post the cose you’re using to embed Flash file?
        Free MODx Graphic resources and Templates www.tattoocms.it
        -----------------------------------------------------

        MODx IT  www.modx.it
        -----------------------------------------------------

        bubuna.com - Web & Multimedia Design
        • 2762
        • 1,198 Posts
        you can try to use this old eto snippet:
        // --------------------
        // Snippet: InsertFlash
        // --------------------
        // Version: 0.6b
        // Date: 2004.12.20
        // [email protected]
        //
        // This snippet was designed as an easy means to insert Flash
        // movies. This is particularly useful if you have a multitude of swf
        // files sharing the same dimensions, in a common folder, etc.
        
        // Config
        
           // $baseFolder [ string ]
           // The base FOLDER where all swf files are held. You can just leave
           // this as "/" if you want to declare the site root.
           $baseFolder = 'flash/';
        
           // $swf [ string ]
           // Set ONLY in snippet call. This is the tail end of the file path
           // to your swf file. For example, if you have a file
           // assets/flash/2004/promo.swf
           // and your $baseFolder is "assets/flash/" then you would call the 
           // snippet like so:
           // [[InsertFlash?swf=2004/promo.swf]]
        
           // $height, $width [ int ]
           // If you have a standard height and width to use, declare so here.
           // These can be overridden in the snippet call for different cases
           // using h and w:
           // [[InsertFlash?swf=2004/promo.swf&h=300&w=400]]
           $height = '300';
           $width = '354';
        
           // $includePluginLink [ true | false ]
           // Toggle to include (or not) a "get Flash" plugin link. This will
           // appear directly under the flash movie. Override in snippet call
           // with plugin=0 (false) or plugin=1 (true).
           $includePluginLink = true;
        
        
        // ############
        // End config #
        // ############
        
        // Get variables
        $height = (isset($h))? $h : $height ;
        $width = (isset($w))? $w : $width ;
        $includePluginLink = (isset($plugin))? $plugin : $includePluginLink ;
        
        $newline = "\n";
        
        // Make sure a movie is selected and valid
        if (isset($swf)){
          $output = '';
          $output .= '<object height="'.$height.'" width="'.$width.'" ';
          $output .= 'codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0" ';
          $output .= 'classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000">'.$newline;
          $output .= '<param value="'.$baseFolder.$swf.'" name="movie" />'.$newline;
          $output .= '<param value="high" name="quality" />'.$newline;
          $output .= '<embed height="'.$height.'" width="'.$width.'" type="application/x-shockwave-flash" ';
          $output .= 'pluginspage="http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash" ';
          $output .= 'quality="high" src="'.$baseFolder.$swf.'" />'.$newline;
          $output .= '</object>'.$newline;
        
          if ($includePluginLink){
            $output .= '<a href="http://www.macromedia.com/go/getflashplayer" target="_blank" class="IF_flashPlugin">';
            $output .= '<img border="0" src="http://www.macromedia.com/images/shared/download_buttons/get_flash_player.gif" /></a>';
          }
        
          return $output;
        
        } else {
          return false;
        }
          Free MODx Graphic resources and Templates www.tattoocms.it
          -----------------------------------------------------

          MODx IT  www.modx.it
          -----------------------------------------------------

          bubuna.com - Web & Multimedia Design
          • 14867
          • 65 Posts
          ok, will test this.....thanx

          the flash file just uses some pictures in the folder....

          *edit*
          so... i made a simple flash file ( http://www.cleverontour.de/assets/flash/fla.swf ) and tried to include it.
          i used the script and did as written :

          [[InsertFlash?swf=fla.swf&amp;h=100&amp;w=100]]

          i placed it some times and it says: movie not loaded...

          so... nothing working.... is there a possibility to deactivate flash files ?
          im stuck...
            42
            • 7455
            • 2,204 Posts
            why do you not use the insertflash option in TinyMCE That works for me
              follow me on twitter: @dimmy01
              • 14867
              • 65 Posts
              Doesn’t work.... TinyMCE places me an object and it doesn’t work...
              Thats crazy !

              and when i place the identical code as in my iframe html into my testDocument it doesn’t work....
              here is the path to the flash... maybe you could try it ...

              http://www.cleverontour.de/assets/flash/images.swf --> doesn’t work 725 x 345
              http://www.cleverontour.de/assets/flash/fla.swf --> works with tinyMCE when i deactivate richtext and make the paty by myself. Its just a blue square 100 x 100

              modx version : 0.9.1 rev 646
              do i have to activate sth to use a flash?
              cachesomething ?


              *edit*:
              i think i found sth.
              i think modx doesn’t allow flash to use folders.... the flashfile uses a folder that lies in assets/flash/ --> "images"
                42
                • 33453
                • 141 Posts
                Did you set "$baseFolder" correctly in the above snippet?

                I am using this FlashVideo snippet and it works fine with paths. Maybe it will do as you want.
                  • 14867
                  • 65 Posts
                  lets have a try tomorrow..... (23:11 in germany now )
                    42
                    • 14867
                    • 65 Posts
                    ... tested and isn’t working.
                    the snippet above is fine. it shows me the "getflash" button so it works...
                    i tried some path variations but none is working.

                    i give up.

                    i think the problem is the path.
                    The html file i includet into my iframe is in the same folder as the flash file and the images folder so has no problem to access and open it.
                    Maybe the flash file isn’t able to load the images from the images folder. i have to make a different image gallery. maybe someone knows one
                    i could change...
                    for this one i used a flash component : http://www.flashcomponents.net/components/preview/preview.php?id=387
                    ( it generates a gallery from a XML file with the paths )

                    so ... maybe there is a better way ( as always for me smiley )

                    thank you for your help but i think its the flash file. other flashfiles are working..

                    i have tried some and have used a
                      42
                      • 26439
                      • 104 Posts
                      ... ?

                      No idea what is going on, but nice pics.

                      http://www.cleverontour.de/assets/flash/images.swf