我使用了 getid3_write_lyrics3库。不工作
这是我的代码:
// Enter your filename here
$filename = 'C:\xampp\htdocs\source2\test.mp3';
//Include getID3() library (can be in a different
directory if full path is specified)
require_once('getid3.php');
// Include desired writer module
require_once('write.lyrics3.php');
//Instantiate desired tag class
$tw = new getid3_write_lyrics3($filename);
// Attempt to write new tag -- NOTE: all values must be in ISO-8859-1
try
{
$tw->title = 'bhavi';
$tw->artist = 'asas';
$tw->album = 'A new album';
$tw->author = 'bhavi author';
$tw->comment = 'bhavika commment';
$tw->images = 'C:\xampp\htdocs\source2\image.jpg';
$tw->synched = true;
$tw->lyrics = "[00:02]Let's talk about time\r\n[00:02]tickin' away
every day\r\n[00:05]so wake on up before it's gone away\r\n";
if(!$tw->write())
{
echo "not success";
}else{
print 'New tag written<br>';
}
}catch (Exception $e)
{
print $e->message;
}
输出
新标签写入
但 MP# 文件显示空白 MP3 标签。显示我下面的屏幕截图。
截屏: