Solved

Flashvars and FLV

Posted on 2009-04-11
3
376 Views
Last Modified: 2013-11-11
I'm using Flash 8 and trying to pass a video path to a FLVPlayback component.  I've set the instance name to vendorVid and the actionscript looks like this:
vendorVid.contentPath = theFile

In my html code i have:
<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0" width="480" height="307" id="heritage" align="middle">
<param name="allowScriptAccess" value="sameDomain" />
<param name="movie" value="michigan/vendorvids/heritage.swf" /><param name="quality" value="high" /><param name="bgcolor" value="#333333" />
<param name="theFile" value="http://myserver/video/thevideo.flv/smil" />
<embed src="vendorvids/heritage.swf" quality="high" bgcolor="#333333" width="480" height="307" name="heritage" align="middle" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" flashvars="theFile=http://myserver/video/thevideo.flv/smil" />
</object>

It doesn't load.  If i copy the file path and put it right in the swf, the video plays fine, so it's something with the way i'm passing or retreiving the flahsvars...  but i don't know what it is.

Any ideas?  Thanks!
0
Comment
Question by:steverguy
3 Comments
 
LVL 5

Expert Comment

by:john_hollings
ID: 24127013
Hi, couple of things.

Firstly, are missing the semi-colon at the end? (e.g.)

vendorVid.contentPath = theFile;

Second - I assume you are using AS2 and as far as I can tell this looks fine.  Can I suggest you make use of the trace() method to ensure that the flash variable is coming through.  Or add a dynamic text fields to your stage and send the variable to this text field, this way you will be able to clearly see if the path is coming though.  If there is any error it will be undefined.

0
 
LVL 8

Accepted Solution

by:
wal_toor earned 500 total points
ID: 24137366
Hello Steve,

Your param flashvars code is wrong. Use these instead:

<PARAM NAME=FlashVars VALUE="theFile=http://myserver/video/thevideo.flv/smil">

Hope this works for you.

greetz,
walter
0
 
LVL 1

Author Closing Comment

by:steverguy
ID: 31569164
Thanks, that was it. :)
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say 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

Suggested Solutions

I come across a lot of question about how to access things in the document class from a movieclip, or accessing something from a movieclip in the document class. It took me a while to figure this out but once I did it makes life so much easier. …
I have been doing hardcore actionscripting for some time; and needless to say I have faced a lot of problems in just understanding others' code rather than understanding what the code executes. A programmer's life can become hell when there are a lo…
The goal of the tutorial is to teach the user how to use the auto adjust feature and what the different options do. When your video is not working right you can choose the auto adjust feature to help choose your settings.
This Micro Tutorial will teach to how to utilize bit rate in Adobe Flash Media Live Encoder.

808 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