Visit SlideShowPro.net  Community Forums
SlideShowPro Support Wiki
  
SlideShowPro Director

Application methods

DirectorPHP's App subclass contains methods for obtaining information about the Director install.

version()

The version method returns the version of the API the Director install is running. Useful for determining if an install has the proper version of the API for the application you are building.

<?php

   include('classes/DirectorPHP.php');
   $director = new Director('your-api-key', 'your-api-path');

   $version = $director->app->version();
   echo $version;  // Example: 1.0.0 

?>

limits()

Returns the upload limits for the Director install.

<?php

   include('classes/DirectorPHP.php');
   $director = new Director('your-api-key', 'your-api-path');

   $limits = $director->app->limits();
   echo $limits->upload_limit; // Example output: 100M   

?>

totals()

Returns the total number of objects uploaded to Director and also the aggregate file size of those files.

<?php

   include('classes/DirectorPHP.php');
   $director = new Director('your-api-key', 'your-api-path');

   $totals = $director->app->totals();
   echo $totals->count; // Example output: 1000
   echo $totals->size; // Example output: 1240000

?>


Page last modified by bdaily on October 08, 2008, at 08:26 AM
© 2011 SlideShowPro. All Rights Reserved.