WordPress.org

Forums

download link for audio (3 posts)

  1. jaja.px
    Member
    Posted 1 year ago #

    hi
    I'm using wordpress 3.6.1
    wordpress can display a player automatically when I'm apload an audio file in a post but i want display duration and download link automatically bellow the player. powerpress plugin have these feature but i won't use plugin. how is this possible?

  2. mvieiras
    Member
    Posted 1 year ago #

    jaja.px,

    For the download link, you can just use an tag, like that:
    Download Now

    Now for the duration, I guess you'll have to write it on code.

  3. bcworkz
    Member
    Posted 1 year ago #

    mvieiras, that would work of course, but it's hardly automatic :)

    For automatic insertion of the information, you could hook 'the_content' filter and search for audio tags. The download link can be extracted from within the tag. The duration I believe is in the audio file itself, you would need a format specification in order to extract it. Once all the information is collected, the additional HTML can be injected into the content stream.

Topic Closed

This topic has been closed to new replies.

About this Topic