SitePoint Sponsor

User Tag List

Results 1 to 2 of 2
  1. #1
    SitePoint Guru XraySierra's Avatar
    Join Date
    Jan 2002
    Location
    Ontario, Canada
    Posts
    850
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Loading new video with jQuery

    I have a client who does has a video production company. I currently have their homepage with a video embedded in a TV image, and thumbnails below the TV that link to other videos. See example at http://your-media.ca

    How would I go about using jQuery to have the Vimeo player reload with a new video when you click on the thumbnails? Possible?
    Chris Blackwell - my blog and ramblings
    Comicville - Daily News and Comic Reviews

    "web development is what I love...so that's what I do"


  2. #2
    Under Construction silver trophybronze trophy AussieJohn's Avatar
    Join Date
    Sep 2005
    Location
    Sydney, Australia
    Posts
    776
    Mentioned
    11 Post(s)
    Tagged
    0 Thread(s)
    You could probably use their Moogaloop API to accomplish what you want. Though after having a quick look at their API it doesn't look like you would be able to simply send a JS command to the player to load a new video.

    The simplest way to accomplish this would be simply to embed the video using the ID (and other parameters) of the new video you want to load using SWFObject. (So, click on a thumb that might have a rel or data attribute that you can use to store the video details, then re-embed the player using SWFObject.)

    The downside is that you're re-embedding the player every time. A much nicer implementation would be if you have a custom (or just a different) player that allows you to control with JS all aspects of the videoplaying (i.e starting/stopping/setting video source, etc.), something like JW player (and maybe even the Strobe player) could be a nice way to implement it.
    var details = {
    . . web: "afterlight.com.au",
    . . photos: "jvdl.id.au",
    . . psa: "usethelatestversion.com"
    }


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •