Getting Flash SWF Dimensions in RR CGI?
Posted: Wed Jul 16, 2008 1:37 am
I'm authoring Flash content to work with an RR CGI script, written by another programmer who's currently too busy to update the code himself. I'd like to take a stab at modifying it.
The other programmer's CGI generates a page with a list of possible SWF files to open. When a SWF file is selected in a list, the SWF is presented in a thumbnail size (it is the actual SWF, just reduced).
The user can then click a button to launch a new window with the SWF presented in a dynamically-generated HTML page.
We want the SWF to be presented at its actual size, so we turn off scaling in the embed and object code. However, since we don't know what each SWF's dimensions are, we've given the embed and object codes a large arbitrary number; which sort of works, except that you can have a small SWF floating in the middle of a massive embed/object area.
What I would like to do is change the RR code somehow to get the actual dimensions of the SWF and write them into the dynamically-generated HTML page's embed/object tags to perfectly fit. I've read that PHP has a function called "getimagesize" that works with SWFs. Does RR have something similar?
The other programmer's CGI generates a page with a list of possible SWF files to open. When a SWF file is selected in a list, the SWF is presented in a thumbnail size (it is the actual SWF, just reduced).
The user can then click a button to launch a new window with the SWF presented in a dynamically-generated HTML page.
We want the SWF to be presented at its actual size, so we turn off scaling in the embed and object code. However, since we don't know what each SWF's dimensions are, we've given the embed and object codes a large arbitrary number; which sort of works, except that you can have a small SWF floating in the middle of a massive embed/object area.
What I would like to do is change the RR code somehow to get the actual dimensions of the SWF and write them into the dynamically-generated HTML page's embed/object tags to perfectly fit. I've read that PHP has a function called "getimagesize" that works with SWFs. Does RR have something similar?