We help IT Professionals succeed at work.

private youtube video embeding in a website

2,864 Views
Last Modified: 2017-07-21
Hi there!

The problem is directly related to this other one EE question:

https://www.experts-exchange.com/Web_Development/Components/Q_27780145.html

but the solution presented there is "not enough" for my purposes...

I have created a channel in YouTube and I want to upload small videos that should be seen ONLY by my customers that login in my website. They may or may not be YouTube users, they may or may not have a Google account.

I know how to upload the YouTube video, put it as unlisted and see it through my site. It works perfectly and the user cannot download the video through my website, what is also good. On the other hand, as Gary put it in the other EE post, people could get the link for the video and pass this link to friends, for instance.

To avoid the passing-link thing, I thought about changing the video type to "private" but, when I do so, the video embedded does not appear, only a message saying "this video is private"... how should I proceed?

In other words, I would like to "tell YouTube" that my site is always able to "see all videos" embedded in my website, even the private ones (especially those), and all my customers, logged-in in my website, should be able to see these videos, but they could not see the same videos in the YouTube channel, and they should not be able to let their friends see the videos (If their friends are not my students, too. The videos are webinar math exercise problems/solutions.)

Is that possible? If yes or no, how should I proceed to be able to do something like that, please?

Thanks,
fskilnik.
Comment
Watch Question

CERTIFIED EXPERT
Expert of the Year 2014
Top Expert 2014

Commented:
The info is still true
https://support.google.com/youtube/answer/157177?hl=en

If you have a login why not just restrict the markup for the video for logged in users only i.e.
if they are logged in then you add the youtube markup (the HTML)
if they are not logged in then you don't

(and geez that is an old question)

Author

Commented:
Hi, Gary!

Thanks for the reply and for the link (very informative)!

I guess I did not understand what is "the markup for the video" you mentioned... let me explain my point:

If the user is logged, (only then) he/she has access to the page in which the YouTube video is embedded, and the HTML string (at this moment) at this page is the following:

<iframe width="640" height="390" src="//www.youtube-nocookie.com/embed/<%= rsRECORDSET.Fields.Item("MediaObject")%>?rel=0" frameborder="0" allowfullscreen></iframe>

In other words, the system tries to hide the name of the link for the YouTube video, and that´s good, but the user could see it at the source code of the page...

But the main problem is that I would like to put the video at YouTube as private, so that if no gmail accounts are authorized, even with the proper link the potencial viewer would not succeed...

The problem, as I mentioned, is that when I change for "private", my own website cannot see the embedded video... got it?

Author

Commented:
Hi again, Gary.

I found a (potential) marvellous solution with two letters: Google Drive.

This was found in this EE post (Scott suggestion): https://www.experts-exchange.com/Web_Development/Social_Networking/Q_28316468.html

I will try to implement it tomorrow (now 22h52min here) and will be back to give you my feedback.

If you have another idea or comments on this idea, please do leave it here till I´m back!

Thanks a lot,
fskilnik.

Author

Commented:
Hi, Gary. I could not implement the Google Drive idea... the problem is of the same type... I cannot see the video at my webpage, because in a certain way my Google account does not relates to my website, so to speak...

Please help!  

(I guess through YouTube would be better, if possible, by the way...)

Author

Commented:
Now I must really go home... found this (below), will look tomorrow...

https://katz.co/embed-protected-video/
CERTIFIED EXPERT
Expert of the Year 2014
Top Expert 2014
Commented:
This one is on us!
(Get your first solution completely free - no credit card required)
UNLOCK SOLUTION
CERTIFIED EXPERT
Expert of the Year 2014
Top Expert 2014
Commented:
This one is on us!
(Get your first solution completely free - no credit card required)
UNLOCK SOLUTION

Author

Commented:
Hi, Gary.

Thank you for your absolutely complete answer (this seems to be your trademark, right)?!

I guess I have to deal with unlisted videos and potential students of mine sharing through reuploadings... to be sincere, this could also be a positive (I hope!) marketing, because the videos are just part of my course, and the exercises and mocks are not able to be accessed without proper login/password/orderID/etc credentials...   :)

Before considering this post closed (and your answers rewarded), could you please have a quick look at the link I posted (https://katz.co/embed-protected-video/) and tell me if you think I should invest some time trying to follow that recipe?  (In other words, do you believe it could really protect my videos as if they were private, without the possibility of my students sharing the link or being able to reupload?)

Thanks a lot for your time and expertise in all that!
CERTIFIED EXPERT
Expert of the Year 2014
Top Expert 2014

Commented:
Reading the comments it seems like that is a premium service now.
Regardless anyone with a bit of know how would be still able to download the video

Author

Commented:
Perfect, Garry.

Thanks a lot, really.

Best wishes in all your projects and see you in other EE posts!
fskilnik.

Gain unlimited access to on-demand training courses with an Experts Exchange subscription.

Get Access
Why Experts Exchange?

Experts Exchange always has the answer, or at the least points me in the correct direction! It is like having another employee that is extremely experienced.

Jim Murphy
Programmer at Smart IT Solutions

When asked, what has been your best career decision?

Deciding to stick with EE.

Mohamed Asif
Technical Department Head

Being involved with EE helped me to grow personally and professionally.

Carl Webster
CTP, Sr Infrastructure Consultant
Empower Your Career
Did You Know?

We've partnered with two important charities to provide clean water and computer science education to those who need it most. READ MORE

Ask ANY Question

Connect with Certified Experts to gain insight and support on specific technology challenges including:

  • Troubleshooting
  • Research
  • Professional Opinions
Unlock the solution to this question.
Join our community and discover your potential

Experts Exchange is the only place where you can interact directly with leading experts in the technology field. Become a member today and access the collective knowledge of thousands of technology experts.

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

OR

Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.