¿Eres nuevo? ¡Lee el FAQ y ponte al día!
916 visitas

How to get the dimensions of a .swf file in PHP

You may think that it is quite hard do get the width and height of a .swf file using PHP. However, it is extremely easy using the getimagesize function.

PHP
  1. $swfDimensions = getimagesize($pathToSwf);
  2.  
  3. if($imageSize)
  4. {
  5.     $width  = $swfDimensions[0];
  6.     $height = $swfDimensions[1];
  7. }
  8. else
  9. {
  10.     throw new Exception("It has been imposible to retrieve the dimensions of the swf file ".$pathToSwf);
  11. }
  12.  

­

Etiquetas: PHP flash swf

Insertar: