diff --git a/getid3/getid3.php b/getid3/getid3.php index f1c05a15..0a7448cc 100644 --- a/getid3/getid3.php +++ b/getid3/getid3.php @@ -387,7 +387,7 @@ class getID3 */ protected $startup_warning = ''; - const VERSION = '1.9.23-202312292105'; + const VERSION = '1.9.23-202402191012'; const FREAD_BUFFER_SIZE = 32768; const ATTACHMENTS_NONE = false; @@ -1477,6 +1477,16 @@ public function GetFileFormatArray() { // Misc other formats + // GPX - data - GPS Exchange Format + 'gpx' => array ( + 'pattern' => '^<\\?xml [^>]+>[\s]* 'misc', + 'module' => 'gpx', + 'mime_type' => 'application/gpx+xml', + 'fail_id3' => 'ERROR', + 'fail_ape' => 'ERROR', + ), + // PAR2 - data - Parity Volume Set Specification 2.0 'par2' => array ( 'pattern' => '^PAR2\\x00PKT', diff --git a/getid3/module.misc.gpx.php b/getid3/module.misc.gpx.php new file mode 100644 index 00000000..73ba48aa --- /dev/null +++ b/getid3/module.misc.gpx.php @@ -0,0 +1,36 @@ + // +// available at https://github.com/JamesHeinrich/getID3 // +// or https://www.getid3.org // +// or http://getid3.sourceforge.net // +// see readme.txt for more details // +///////////////////////////////////////////////////////////////// +// // +// module.misc.gpx.php // +// module for analyzing gpx files // +// dependencies: NONE // +// /// +///////////////////////////////////////////////////////////////// + +if (!defined('GETID3_INCLUDEPATH')) { // prevent path-exposing attacks that access modules directly on public webservers + exit; +} + +class getid3_gpx extends getid3_handler +{ + /** + * @return bool + */ + public function Analyze() { + $info = &$this->getid3->info; + + $info['fileformat'] = 'gpx'; + + $this->error('gpx parsing not enabled in this version of getID3()'); + return false; + + } + +}