demo.cache.mysql.php 1.3 KB

12345678910111213141516171819202122232425262728293031
  1. <?php
  2. /////////////////////////////////////////////////////////////////
  3. /// getID3() by James Heinrich <info@getid3.org> //
  4. // available at https://github.com/JamesHeinrich/getID3 //
  5. // or https://www.getid3.org //
  6. // or http://getid3.sourceforge.net //
  7. // //
  8. // /demo/demo.cache.mysql.php - part of getID3() //
  9. // Sample script demonstrating the use of the DBM caching //
  10. // extension for getID3() //
  11. // see readme.txt for more details //
  12. // ///
  13. /////////////////////////////////////////////////////////////////
  14. die('For security reasons, this demo has been disabled. It can be enabled by removing line '.__LINE__.' in demos/'.basename(__FILE__));
  15. require_once('../getid3/getid3.php');
  16. require_once('../getid3/getid3.lib.php');
  17. getid3_lib::IncludeDependency(GETID3_INCLUDEPATH.'extension.cache.mysql.php', __FILE__, true);
  18. $getID3 = new getID3_cached_mysql('localhost', 'database', 'username', 'password');
  19. $r = $getID3->analyze('/path/to/files/filename.mp3');
  20. echo '<pre>';
  21. var_dump($r);
  22. echo '</pre>';
  23. // uncomment to clear cache
  24. //$getID3->clear_cache();