Jump to content


[PHP] Get mp3 song length


3 replies to this topic

#1 Towz

    Young Padawan

  • Members
  • Pip
  • 13 posts

Posted 07 April 2008 - 12:44 PM

Hi,
Can anyone tell me how to get mp3 length using php
I try to use getId3() but i didn't understand it so can anyone give my a link or write in were a tutorial for get mp3 length plz ;]

#2 fycnrdths

    Young Padawan

  • Members
  • Pip
  • 16 posts
  • Location:stuck to my desk chair
  • Interests:programming.

Posted 07 April 2008 - 01:34 PM

View PostTowz, on Apr 7 2008, 12:44 PM, said:

Hi,
Can anyone tell me how to get mp3 length using php
I try to use getId3() but i didn't understand it so can anyone give my a link or write in were a tutorial for get mp3 length plz ;]

http://getid3.org
I used this last year. It's the only thing that I could find at the time. You'll have to upload all of the files and look in the demo pages for the code for the length, artist name, etc.

Edited by fycnrdths, 07 April 2008 - 01:35 PM.


#3 Towz

    Young Padawan

  • Members
  • Pip
  • 13 posts

Posted 07 April 2008 - 01:42 PM

hm... i can find the demo can you plz help me to find it and i dont know how to use this id3

#4 fycnrdths

    Young Padawan

  • Members
  • Pip
  • 16 posts
  • Location:stuck to my desk chair
  • Interests:programming.

Posted 07 April 2008 - 01:55 PM

View PostTowz, on Apr 7 2008, 01:42 PM, said:

hm... i can find the demo can you plz help me to find it and i dont know how to use this id3

You can't find it? I haven't used it in a year, but I think this is it: http://getid3.org/so...demo.basic.phps

This line shows the file length:
echo @$ThisFileInfo['playtime_string'];

You need to download all of the files though.

Edited by fycnrdths, 07 April 2008 - 01:56 PM.






1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users