Best way to delete the id3v1 and id3v2 sections of a mp3

Locked
koolaid1551
User
Posts: 2
Joined: Wed Oct 10, 2012 6:52 pm
Are you a spambot?: no

Best way to delete the id3v1 and id3v2 sections of a mp3

Post by koolaid1551 » Wed Oct 10, 2012 6:56 pm

What's the best way to remove all of the Id3v1 and v2 tags including the album art and the webpage tags. After doing this I would like to add back in Artist, Album, and Title in the Id3v2 section.

James Heinrich
getID3() v1 developer
Posts: 1444
Joined: Fri May 04, 2001 4:00 pm
Are you a spambot?: no
Location: Northern Ontario, Canada
Contact:

Re: Best way to delete the id3v1 and id3v2 sections of a mp3

Post by James Heinrich » Wed Oct 10, 2012 7:16 pm

Code: Select all

require_once('write.id3v2.php');
$getid3_write_id3v2 = new getid3_write_id3v2;
$getid3_write_id3v2->filename = '/path/to/file.mp3';
$getid3_write_id3v2->RemoveID3v2();
Same idea for ID3v1.

koolaid1551
User
Posts: 2
Joined: Wed Oct 10, 2012 6:52 pm
Are you a spambot?: no

Re: Best way to delete the id3v1 and id3v2 sections of a mp3

Post by koolaid1551 » Thu Oct 11, 2012 9:08 pm

Actually just using $tagwriter->overwrite_tags = true; accomplished what I was trying to do.

Thanks!!

Locked