• Does anyone have a workaround for the bug that disallows the comma character in titles/artist names? For example:

    [audio:file_1.mp3,file_2.mp3,file_3.mp3|titles=Title 1,This title, has a comma which doesn't work,Title 3]

    I’ve tried to replace the comma with its character code (& #44;) but this doesn’t work, so I’m replacing it with a semi-colon as in interim solution.

Viewing 10 replies - 1 through 10 (of 10 total)
  • I think in that situation, commas are interpreted by the player as a “seperator” of file titles rather than track title punctuation.

    Have you considered editing the Metadata for the mp3 file itself? That way the punctuation appears in the track information, but doesn’t need to appear in the file name.

    Just an after thought…. If you do it the way I suggested, you don’t need to list the track titles. Just the file names, like this:

    [audio:file_1.mp3,file_2.mp3,file_3.mp3]

    The track title info is pulled from the metatags in the mp3 and shows titles (with punctuation) automatically.

    Thread Starter Damien du Toit

    (@codacoza)

    I’ll try that, thanks

    Thread Starter Damien du Toit

    (@codacoza)

    When I remove the titles, then the player shows “Track #1” until I click Play, at which point it loads the id3 meta. Is there something I’m missing? I’m using the standard method for embedding (via the [audio] tag) and also the standalone player and both do this. I need to have the titles showing when the player loads as there are multiple instances of the player on a page and they all say “Track #1”.

    You are using this player?

    I click on the player in my post ( which is closed/off by default ) and the instant it opens I see “1: The song title” and run time, and have forward and back buttons that allow me to do the obvious. Fast forward shows “2: song title two”.

    My guess would be, that in order to use the method I suggested above, you will have to check/edit the metadata tags on the actual mp3 file itself. Then you can name the file whatever you want, and it will still show the artist and song title in the player.

    It works fine for me, but perhaps your circumstances are different. I use Audacity to edit my tracks and the metadata tags, but I’m sure there are many good mp3 taggers available.

    This is the actual code in my test post using the real file names I uploaded for testing: [audio:blah.mp3,no.mp3]

    What shows up in the player is this:

    1:Alabama – She Ain’t Your Ordinary, Girl 0:00 2:Rod Stewart – We’ll Be Together Again 0:00 ( Note the intentional inclusion of various punctuations just for testing purposes. )

    So just editing the meta tags in the mp3 file before uploading is the solution for me.

    But if you are using the stand-alone version, maybe the answer is something more complicated.

    By the way, here is the explanation for the comma related concern expressed in first post.

    “You can also add titles for these tracks:

    [audio:your_mp3_file_1.mp3,your_mp3_file_2.mp3|titles=The title 1,The title 2|artists=The artist 1,The artist 2]

    Note: Titles and artist names are currently comma-delimited. I know this isn’t perfect as a title may contain a comma. I will try ti fix this in the future.”

    Source: http://wpaudioplayer.com/frequently-asked-questions

    Thread Starter Damien du Toit

    (@codacoza)

    @claytonjones: Does your player show the titles if you set “animation” to “no” ? ie. when the player is always open, and the track info is displayed. That’s how my player is configured. I get “Track #1” for all tracks, until I click play, and only then are the correct track names displayed.

    Otherwise it works fine when I have “animation” to “yes”, so that the player is closed and when you click play, it slides open and the track name is correctly displayed.

    There isn’t a problem with my id3 tags.

    I’m aware of the limitation with using commas in titles because of the comma delimiter. That’s the problem I’m trying to find a solution for, since my track info isn’t displaying on load, and I therefore want to send the track titles to the player so that they are.

    Ahh… Now we’re communicating. I can now duplicate your symptoms exactly by turning off my player animation and forcing the player to be “open” by default. Using this code: [audio:blah.mp3,no.mp3]

    However, when I changed my code to this:

    [audio:blah.mp3,no.mp3|titles=song one,song two]

    this is exactly what showed in the player when I viewed it:

    1:song one 0:00 2:song two 0:00

    Once I clicked play, it loaded the ID3 tags as would be expected, and showed the real artist and title info.

    I can only guess that the behavior is because although the player is exposed when the post is viewed, it doesn’t actually load any ID3 info until the mp3 is requested/loaded by pressing the play button. However, the only time I actually duplicated the words “Track #1” “Track #2” in the player was when I didn’t provide the titles in the code.

    So I guess we’re back to square one with what we both already knew, and you won’t be able to use commas in the embed code for your song titles if you use the player in non-animated mode.

    Best wishes!

    Thread Starter Damien du Toit

    (@codacoza)

    @claytonjames: Thanks for confirming, I thought I was doing something wrong.

    there is a solution to the first post.

    you CAN use a comma in a filename. but you have to url-encode it. two times.

    comma url encoded is %2C. but flash decodes it and flash script receives value decoded to actual comma and then splits string using that comma as a separator. to avoid this we “escape” that %2C, that is we encode it another time and get %252C. in that case flash decodes to %2C and the flash script does not split it. then %2C remains in url until player asks server for that file.

    example from my code:

    $filename = MEDIASERVER . str_replace(",", "%252C", str_replace(" ", "%20", $filename));

    good luck

Viewing 10 replies - 1 through 10 (of 10 total)

The topic ‘[Plugin: Audio Player] Comma in mp3 title’ is closed to new replies.