jekyll/octopress embedded youtube videos caching issue - youtube

I have an octopress site http://irlnathan.github.io/sailscasts/ that embeds different screencasts from youtube. The correct video is displayed when the site is initially loaded, however, when a particular post is selected and one goes back from the browser all of the embedded videos point to the same single video.
I'm hosting the pages on github and I can't figure out why the pages are I think being cached in this way. Has anyone run into this problem?

I don't see the problem you described for your site.
But You might want to add <!--more--> before your videos so that videos are not shown in the blog list page. All these videos made the page loading a bit slow, which kinda defeat the purpose of using static page.

Related

Adding multiple youtube playlists to site just like youtube has em

this is desired output for site
this is how youtube displays multiple playlist...how can I add this just like they have it to my site AND to linkedin profile?
embedding the share html link just brings in playlist but it does not display properly....I need it to appear exactly like it does in attached pic???
Linking to your LinkedIn profile, I have not tried. So perhaps someone else can tell you.
As to having a section like the one you showed to be on your own site is doable.
Firstly you will need to collect the playlist ID's that you are going to use.
Then you will need to get the video ID's from the video's in each Playlist.
This can be done with the API.
As to the displaying it like on youtube, you will need to do that yourself with one or more combination of table's, div's and CSS. Then With the information you grabbed in the APi, populate it.
Best to do it in a loop so as to be done all at the same time. Then put it to the page where you require it to be.

Embed YouTube on site, to open in a NEW PAGE (NOT within the same page)

OK, I have thoroughly searched for an answer, and have not found one that WORKS correctly. I have a page full of videos - listing training videos, each will have a link to a youtube video (all videos have been uploaded to youtube), but will open up in a NEW PAGE on my site. I am a novice website designer, and the problem seems to be that people are anxious to give me half of the code, rather than being explicit with it. Can you help, please?
You need to get the embedding url.
For instance, instead of: https://www.youtube.com/watch?v=JPx3A6XEUF0
use this: https://www.youtube.com/embed/JPx3A6XEUF0

Patterns between YouTube m. and normal site urls

My site is not able to show uploaded youtube videos when the url is a mobile (m.) site, but it works for the normal youtube site. It seems to me that the mobile and normal urls differ in a pattern, as shown below:
http://www.youtube.com/watch?v=5ILbPFSc4_4
http://m.youtube.com/#/watch?v=5ILbPFSc4_4&desktop_uri=%2Fwatch%3Fv%3D5ILbPFSc4_4
obviously, the m. is added, as is the /#, and all the &desktop_uri... stuff.
and again:
http://www.youtube.com/watch?v=8To-6VIJZRE
http://m.youtube.com/#/watch?v=9To-6VIJZRE&desktop_uri=%2Fwatch%3Fv%3D8To-6VIJZRE
What we hope to do is check to see if the url is mobile site, and if it is, parse it so it shows as the normal site.
Does any one know if all youtube urls work this way--if this similar pattern works for all the same videos on mobile and normal sites?
In general, any time you attempt to parse URLs for sites (as opposed to web APIs) by hand, you're leaving yourself open to breakage. There's no "contract" in place that states that a common format will always be used for watch page URLs on the mobile site, or on the desktop site.
The oEmbed service is what you should use whenever you want to take a YouTube watch page URL as input and get information about the underlying video resource as output in a programmatic fashion. That being said, the oEmbed response doesn't include a canonical link to the desktop YouTube watch page, so it's not going to give you exactly what you want in this case. For many use cases, such as when you want to get the embed code for a video given its watch page URL, it's the right choice.
If you do code something by hand, please ensure that your code is deployed somewhere where it would be easy to update if the format of the watch pages ever do change.

search for and embed youtube videos in ruby on rails application

I have a website where I want to basically allow people to display several youtube videos onto the same page.
For example, I have a friend who has 3 different videos. Instead of sending a link to the three videos individually, they would go to my site see the 3 search boxes, search for the videos individually (the search is done on youtube), then they can pick the videos and click "done", at which point, the 3 videos would be embedded on their page.
I'm trying to figure out how to approach this in ruby on rails, but I'm not finding much information on how.
Here's a link from 2009 of a guy who's saying that he can actually do the search and retrieve from youtube: http://railsforum.com/viewtopic.php?id=30443
But I don't know how to do the search & retrieve, and I don't know how to do the embed. I think I can figure out the embed, but what's the best way to do the search/display results?
Thanks a lot for your help stackoverflow, you're my only hope (besides google, but google failed me today).
all you need to know about the search feature is described in YouTube Data Api. You will need your app to communicate with this API. The best thing to do may be to look after a gem specialized in this ; there is a list available in another StackOverflow question.

Youtube player for multiple videos from various accounts

I have a page that has many videos on it and the page has become so slow it is unusable. These are all Youtube videos and I changed to the new iFrame tags hoping that would help the loading. I need a solution to make this page more useable.
I would be happy if I could just pull a frame from the video and display that, when clicked it would load the video. Or I would be happy with a multi-video player. The custom play from Youtube will not work because the videos I am serving are not all from my account and as I understand the custom player you reference a group from your account. I have also considered using AJAX to load the iframe, which would be okay too if I could figure out how to get a thumbnail of the video to show as a link.
Ideas and suggestions are welcome. Thanks in advance for any ideas.
YouTube API is made up of 2 different sets - one for the player and one for the data.
You can start here ...
http://code.google.com/apis/youtube/overview.html
... then click on "Data API" link and after looking over that page, click on the "Reference Guide" link.
In essence, the gData API will allow you to get videos in numerous ways (feeds, channels, tops, etc) in chunks of up to 100 videos at a time, using a startIndex (or whatever it may be called) option for paging. What you get is an XML document with parts or everything that YT has about a video, including not one but several different thumbnail images.
HTH helps you and/or another Web 0.2 Fellow (like me)

Resources