MetaAudio A PHP library to read and write metadata tags to audio files

Getting Started

Usage

Setup

View the API Documentation for this class

All classes are in the duncan3dc\MetaAudio namespace.

When working with the library you need to specify which types of tags you are working with (eg ID3, Ape, etc).

The easiest way to do this is to use the Tagger class like a factory:

require_once __DIR__ . "vendor/autoload.php";

use duncan3dc\MetaAudio\Tagger;

$tagger = new Tagger;
$tagger->addDefaultModules();

$mp3 = $tagger->open("/var/music/song.mp3");

The addDefaultModules() from the example above applies all the modules that ship with the library (currently ID3 and Ape). You can use specific modules like so:

use duncan3dc\MetaAudio\Modules\Id3v1;
use duncan3dc\MetaAudio\Tagger;

$tagger = new Tagger;
$tagger->addModule(new Id3v1);

Read more about modules here