Solved

SWF won't scale?

Posted on 2014-01-07
4
543 Views
Last Modified: 2014-03-14
I am trying to play a swf.

This is the default code that Dreamweaver gives me, and it works. The problem is, when I change the width and height to something reasonable, (600x326) the player shrinks, but the content doesn't, so you only see the center 50% of the video.

I have tried adding:
<param name="scale" value="noscale">

Open in new window

But that doesn't do anything.
When the SWF file plays, if I hit right-click, Show All, everything can be seen just fine.

Here's the starter code I am working with.

For the points: add the paran (or whatever I need) to make the content show in the 600x326 player size. Or... show me an alternative way to play this silly swf file.

<object id="FlashID" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="1360" height="739">
	  <param name="movie" value="videos/1389146962.swf">
	  <param name="quality" value="high">
	  <param name="wmode" value="opaque">
	  <param name="swfversion" value="8.0.35.0">
	  <!-- This param tag prompts users with Flash Player 6.0 r65 and higher to download the latest version of Flash Player. Delete it if you don’t want users to see the prompt. -->
	  <param name="expressinstall" value="Scripts/expressInstall.swf">
	  <!-- Next object tag is for non-IE browsers. So hide it from IE using IECC. -->
	  <!--[if !IE]>-->
	  <object type="application/x-shockwave-flash" data="videos/1389146962.swf" width="1360" height="739">
	    <!--<![endif]-->
	    <param name="quality" value="high">
	    <param name="wmode" value="opaque">
	    <param name="swfversion" value="8.0.35.0">
	    <param name="expressinstall" value="Scripts/expressInstall.swf">
	    <!-- The browser displays the following alternative content for users with Flash Player 6.0 and older. -->
	    <div>
	      <h4>Content on this page requires a newer version of Adobe Flash Player.</h4>
	      <p><a href="http://www.adobe.com/go/getflashplayer"><img src="http://www.adobe.com/images/shared/download_buttons/get_flash_player.gif" alt="Get Adobe Flash player" width="112" height="33" /></a></p>
        </div>
	    <!--[if !IE]>-->
      </object>
	  <!--<![endif]-->
</object>

Open in new window

0
Comment
Question by:DrDamnit
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
4 Comments
 
LVL 53

Accepted Solution

by:
Scott Fell,  EE MVE earned 500 total points
ID: 39764114
Use flowplayer http://flowplayer.org/

http://flash.flowplayer.org/documentation/installation/index.html

<script src="path/to/the/flowplayer-3.2.13.min.js"></script>

Open in new window

<a href="http://www.mywebsite.com/myVideo.flv"
   style="display:block;width:425px;height:300px;"
   id="player">
</a>

Open in new window

<script language="JavaScript">
  flowplayer("player", "path/to/the/flowplayer-3.2.18.swf");
</script>

Open in new window



In the code below is where you will set your width and height

<html>
  <head>
    <title>Wow! This is video</title>
    <script src="path/to/the/flowplayer-3.2.13.min.js"></script>
  </head>
  <body>
    <a href="http://www.mywebsite.com/myVideo.flv"
       style="display:block;width:425px;height:300px;"
       id="player">
    </a>
 
    <script language="JavaScript">
      flowplayer("player", "path/to/the/flowplayer-3.2.18.swf");
    </script>
  </body>
</html>

Open in new window

0
 
LVL 53

Expert Comment

by:Scott Fell, EE MVE
ID: 39767614
Just checking in... Does using flowplayer make sense or do you want to stick with flash/object?  

I have not used the flash embed in a long time myself and have mostly used flowplayer.   If you have an older version of dreamweaver it gives you the wrong code.
0
 
LVL 32

Author Comment

by:DrDamnit
ID: 39862267
I am stuck with an SWF because it is something produced by jing. I really wish it was some other form of video because at least I can grab / transcode, do what I want, but SWF bytecode is a pain....
0
 
LVL 53

Expert Comment

by:Scott Fell, EE MVE
ID: 39862371
I tested the embed code and it does resize.  Did you change the width and height in both places?  Or did you use dreamweaver to auto generate the embed code?  I think if you use dreamweaver, it will detect the actual size and use it.  Try the code below and see what happens.   Also, does jing allow you to physically resize the video?  The reason you wan to physically resize is the actual file size will shrink and it will load faster.  More importantly, it is possible the video may not look as good as full size especially if you are using text.  

<object id="FlashID" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="600" height="326">
	  <param name="movie" value="videos/1389146962.swf">
	  <param name="quality" value="high">
	  <param name="wmode" value="opaque">
	  <param name="swfversion" value="8.0.35.0">
	  <!-- This param tag prompts users with Flash Player 6.0 r65 and higher to download the latest version of Flash Player. Delete it if you don’t want users to see the prompt. -->
	  <param name="expressinstall" value="Scripts/expressInstall.swf">
	  <!-- Next object tag is for non-IE browsers. So hide it from IE using IECC. -->
	  <!--[if !IE]>-->
	  <object type="application/x-shockwave-flash" data="videos/1389146962.swf" width="600" height="326">
	    <!--<![endif]-->
	    <param name="quality" value="high">
	    <param name="wmode" value="opaque">
	    <param name="swfversion" value="8.0.35.0">
	    <param name="expressinstall" value="Scripts/expressInstall.swf">
	    <!-- The browser displays the following alternative content for users with Flash Player 6.0 and older. -->
	    <div>
	      <h4>Content on this page requires a newer version of Adobe Flash Player.</h4>
	      <p><a href="http://www.adobe.com/go/getflashplayer"><img src="http://www.adobe.com/images/shared/download_buttons/get_flash_player.gif" alt="Get Adobe Flash player" width="112" height="33" /></a></p>
        </div>
	    <!--[if !IE]>-->
      </object>
	  <!--<![endif]-->
</object>

Open in new window


Ning is showing a different way to embed http://creators.ning.com/forum/topics/html5-tip-valid-flash-embed-code

It has been a long time since I have used this type of code. I typically have used something like flowplayer.
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction HTML checkboxes provide the perfect way for a web developer to receive client input when the client's options might be none, one or many.  But the PHP code for processing the checkboxes can be confusing at first.  What if a checkbox is…
This article demonstrates how to create a simple responsive confirmation dialog with Ok and Cancel buttons using HTML, CSS, jQuery and Promises
The goal of the tutorial is to teach the user how to how to load their YouTube profile onto Flash Media Live Encoder.
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…
Suggested Courses

630 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question