diff options
author | Karl 'vollmerk' Vollmer <vollmer@ampache.org> | 2006-05-13 07:16:54 +0000 |
---|---|---|
committer | Karl 'vollmerk' Vollmer <vollmer@ampache.org> | 2006-05-13 07:16:54 +0000 |
commit | ada740ec4123cf286c8abc3a09eb62ed80716fba (patch) | |
tree | 54b301e9d030a4a218fe86833813d11371e5a839 /modules/id3 | |
parent | a4be3297d541560e1bc4291d366808fca517d49e (diff) | |
download | ampache-ada740ec4123cf286c8abc3a09eb62ed80716fba.tar.gz ampache-ada740ec4123cf286c8abc3a09eb62ed80716fba.tar.bz2 ampache-ada740ec4123cf286c8abc3a09eb62ed80716fba.zip |
wups.. yea this file isnt done yet
Diffstat (limited to 'modules/id3')
-rwxr-xr-x | modules/id3/vainfo.class.php | 63 |
1 files changed, 63 insertions, 0 deletions
diff --git a/modules/id3/vainfo.class.php b/modules/id3/vainfo.class.php new file mode 100755 index 00000000..f564b5e9 --- /dev/null +++ b/modules/id3/vainfo.class.php @@ -0,0 +1,63 @@ +<?php +/** + * Load the Getid3 Library + */ +require_once(conf('prefix') . '/modules/id3/getid3/getid3.php'); + + +/** + * vainfo + * This class takes the information pulled from getID3 and returns it in a + * Ampache friendly way. + */ +class vainfo { + + /* Default Encoding */ + var $encoding = 'UTF-8'; + + + /* Loaded Variables */ + var $filename = ''; + var $_getID3 = ''; + + + /* Returned Variables */ + var $_info = array(); + + /** + * Constructor + * This function just sets up the class, it doesn't + * actually pull the information + */ + function vainfo($file,$encoding='') { + + $this->filename = stripslashes($file); + if ($encoding) { + $this->encoding = $encoding; + } + + // Initialize getID3 engine + $this->_getID3 = new getID3(); + $this->_getID3->option_md5_data = false; + $this->_getID3->option_md5_data_source = false; + $this->_getID3->encoding = $this->encoding; + + } // vainfo + + + /** + * get_info + * This function takes a filename and returns the $_info array + * all filled up with tagie goodness or if specified filename + * pattern goodness + */ + function get_info() { + + $raw_array = $this->_getID3->analyze($this->filename); + + print_r($raw_array); + + } // get_info + +} // end class vainfo +?> |