WordPress.org

Ready to get started?Download WordPress

Forums

Easy FancyBox
playing mp3 in fancybox (5 posts)

  1. cellobrutos
    Member
    Posted 3 years ago #

    Hi,

    I know several plugins already exist for playing mp3, and I've actually already tried quite a few. But I would like to keep a coherent look and feel for my whole page between images, videos, and audi. How would I go about adding a mp3 to my fancybox content? I would guess using an iframe somehow?

    Thanks,
    F.

  2. RavanH
    Member
    Plugin Author

    Posted 3 years ago #

    or inline content maybe? i never tried it though...

    interesting thought. what kind of player are you planning to use? a flash player? or do you do straight embeds and leave it up to the visitors browser to decide what to do with it?

  3. cellobrutos
    Member
    Posted 3 years ago #

    I have no idea actually. I was kind of hoping you would know. I'll try something out and let you know - I've heard good stuff about jplayer, so I'll start there...

  4. RavanH
    Member
    Plugin Author

    Posted 3 years ago #

    Very interesting!

    I found http://wordpress.org/support/topic/mp3-player-plugin-3 where the dev of http://wordpress.org/extend/plugins/mp3-jplayer/ says it does not conflict. That's at least a good thing to start with.

    Then I'd try (with the Flash option enabled) two approaches:
    1. Create a manual link to the player so that your desired MP3 is included and give that link class="fancybox-swf" to make sure FancyBox will regard it as a flash player...
    2. Use the MP3-Jplayer shortcode in your post content but hide the content by wrapping it with <div class="fancybox-hidden"><div id="MyInlineContentID-1">....</div></div> end then create a manual link to open that hidden player as inline content in FancyBox. Something like <a href="#MyInlineContentID-1" class="fancybox">Play it!</a>

    I think the second option (if you can make it work) would be the best because that will leave it up to MP3-Jplayer to decide if it is going to play in Flash or HTML5's WebM :)

  5. cellobrutos
    Member
    Posted 3 years ago #

    Well, I couldn't get it to work as I wanted.
    And actually I figured my client wanted something different: since audio is not like video or photos where you have to actually watch the image on screen, if you overlay the audio player, it prevents you from doing something else while it's playing, like... watching the pictures.

    So not a good idea in the end, for that project at least. But if you come up with a good idea about this one day, I'll check it out. As I'm working with musicians all the time it could be very interesting indeed.

    Fantastic plugin, great support. Very nice work there!

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic