Gallery2:Modules:getid3 - Gallery Codex
Personal tools


From Gallery Codex

Getid3 Module

Shows embedded meta data for mp3 files (artist, title, ...).


Author: Don Willingham.

getid3() is written by James Heinrich.

Shows embedded meta data for mp3 files (artist, title, ...), video files and some archive (zip) formats too. The getid3 module that ships with Gallery 2 does not support video or archive files since it would make the download quite large. If you want to add support for video and archive files or other omitted formats, you'll have to add the appropriate getid3 modules in the modules/getid3/libs/ module (get the original getid3 library from the above link).


  • Extracts ID3 and other meta data tags from audio, video and archive files. For more information see: getid3()
  • Add the getid3 block to your photo pages to show the ID3 information related to that item on its page in G2


  • Download the module from the download page if necessary. The minimal and typical package of G2 don't include this module.
  • Install and activate the module in Site Admin -> Plugins
  • Add the getid3 block to your photo pages in Site Admin -> Themes -> Matrix (or for any other active/used theme)
  • Add some mp3 files to your G2 (or other supported files) and browse to the corresponding item page in G2 to see the related ID3 data

Requested Features

Currently there are no feature requests for this module.


Currently, this module does NOT work on Microsoft Windows Servers.

File Types / Supported Meta Data

  • audio/mp3
    • Artist
    • Album
    • Track
    • Title
    • Bit Rate
    • Bit Rate Mode

To Do

  • Priority
    • test/data should be under 50 K max.
      • Directory was under 50K until 57K isotest.iso was added. The first try was over 300K.
    • lib/getid3 should not have *any* unnecessary files
      • OR make every file necessary
      • Some files like archive.rar and audio.mod inc files are just place holders anyway.
      • Graphic and Database caching are not necessary, except for maybe the tiff one.
    • we should not be calling getid3 unless we're highly confident that there'll be data in the file we're checking
      • This goes hand in hand with configuring properties per mime type. (see below)
  • Archive types
    • Limit number of files displayed at a time, and allow the user to page (25 at a time, for example).
    • Display more archive file data, such as datestamps.
  • Operations
    • Implement 'dimensions'
    • Implement 'dimensions-and-duration'
  • Configure Properties per mime type?
    • Audio Bit Rate should be Bit Rate for Audio only types.
    • Wave files don't have a lot of the meta data types mp3 files have.
    • Archives have vastly different information that Audio and/or Video types.
    • If the mime type doesn't have any properties configured don't call getid3.
    • Information block should be titled Audio, Audio/Video, or Archive Properties.
  • Sorting by track number like origination timestamp.
  • Extract id3v2 art and use as thumbnail. (if possible)
  • Add "unsupported" files back in
    • modules.archive.szip
    • module.archive.rar (if/when implemented, it's currently a place holder)
    • write.* (if we decide we want to provide acces to this functionality through gallery)
    • module.misc.exe
    • module.graphic.* (maybe once unit tested)
    •, ac3, au, avr, bonk, la, lpac, midi, mod, monkey, mpc, optimfrog, rkau, shorten, tta, voc, vqf)
    •, bink, matroska, mpeg, nsv, real, swf)

Development Notes

Getid3 needed slight modification to pass unit tests. Some getid3 modules are omitted because we don't unit test them. Version 1.7.5 (Released December 29, 2005) is currently used, and it is not necessary to separately download and/or install it. Getid3 supports much more than ID3 tags from mp3 files, it supports other audio formats such as ogg, flac, and wave. Video formats such as MOV and AVI are supported. Finally, archive formats such as iso, tar, and zip.