NameSilo

[Php] Auto sensing a .swf dimensions.

Namecheap AuctionsNamecheap Auctions
Namecheap AuctionsNamecheap Auctions
SpaceshipSpaceship
Watch

Alex.

Account Closed
Impact
5
how can you auto sense the dims of a flash file using php, if at all?

i thought that on phpbb activity mods, you can import a swf file and it auto senses its dims.

is there a way to do it?
 
0
•••
The views expressed on this page by users and staff are their own, not those of NamePros.
GoDaddyGoDaddy
You can actually use the same function that gets properties of images files to do this:

http://uk2.php.net/getimagesize

The getimagesize() function will determine the size of any GIF, JPG, PNG, SWF, SWC, PSD, TIFF, BMP, IFF, JP2, JPX, JB2, JPC, XBM, or WBMP image file and return the dimensions along with the file type and a height/width text string to be used inside a normal HTML <IMG> tag.

So for example:

PHP:
<?php
list($width, $height, $type, $attr) = getimagesize('animation.swf');

// echo $width . ' x ' . $height;
?>


Matt

?>
 
0
•••
edit: Ah, I lose. ^
 
0
•••
thanks for your help!
 
0
•••
DomainEasy: flexible LTO options. Close more domain deals with financing.

We're social

Escrow.com
Spaceship
CryptoExchange.com
Domain Recover

NamePros updates

Portfolio sites: new ways to sort, filter and group your domains
Your public portfolio page has a few new tools for visitors. Portfolio: Newest first The sort menu now has "Newest first". It shows the...
AIVikings
Catchy
  • The sidebar remains visible by scrolling at a speed relative to the page’s height.
Back