Video embed code verification

Tag: security , video Author: ycfling Date: 2011-02-22

I have a website where the user is able to add a youtube,vimeo etc. embed code. How can i verify if that the code submitted links really to a video and i don't risk the security of my site.

Best Answer

Since the format of the embed code is known, it would be simple for you to extract the data identifying the video clip and use that inside your own templated copy of the embed code. Just insert the video clip identifier in your template.