Advertisement

11.27.2008 at 08:59PM PST, ID: 23941446
[x]
Attachment Details
[x]
The Solution Rating System

With so many solutions, how can you tell which solutions are most likely to help you and which ones are not? To provide you with a tool to use, we rate our solutions based on various elements that most accurately determine if a solution is a quality solution. To explain what factors affect the solution rating, here are the elements we take into consideration when formulating our solution rating.

  • The Grade of the Solution
  • The Zone Rank of the Expert Providing the Solution
  • The Number of Author and Expert Comments
  • The Number of Experts Contributing
  • The Feedback of the Community

Your Input Matters
Because of the way the system is set up, the most important variable in this equation is you. As a member of Experts Exchange, you are able to cast your vote on the quality of the solutions in regard to how complete, accurate, helpful and easy to understand each solution is. When you provide your feedback, each rating is adjusted accordingly. So, if you see a solution that has a poor rating that you think is a good solution, let us know by rating it. As you do, the rating will be adjusted and will become more accurate for other members of our site.

If you have any suggestions that you would like to make for our rating system, please ask a question in the Suggestions Zone of Community Support.

Thank you!

9.1

Encrypting YouTube Video Embed's using Javascript

Asked by creceveur in JScript, JavaScript, Algorithms

Tags: , ,

This site somehow encrypts the video embed link going to YouTube.  It disables being able to click on the video and go to YouTube, disables the related video's at the end, and also the source.  I've attached a snippet of the code from the site.  I'd like to be able to do this for a site I own, and am wondering how it's done.  Ideally if someone could show me how this is being done, or provide a code snippet taking the input http link to the youtube video and spitting out the "encrypted" code to plant on the page would be ideal.Start Free Trial
1:
2:
3:
4:
5:
6:
7:
<script language='javascript'> 
yts='ppSIysSMkZKX0sbFnJuawJafhIaGlpDYlJeU1Y3Ty65xWXU1aVY0TEkvYmcxaGApYnR+LiQyOjAsKy88MDotKxQGCxguQ1NJS11DREINV1tZGUofTRlMHhhCMBscS19NYCJ/YWZ+TGdoKmF2bGpyIDI7NzAgdXFsUnl6OHdgfngDDQMQFwwCWkoKBhgFCVQrQkYxNzZDM1o5PEw/UUxPHOasu7XGvauzvL2/vr+4ur+goaKxtLKtnbi5+bChvbn8z8XHwcXWw5qKwd7f3JeBgNTexd3Y2tfTltTb2M7S09qkqKPtp6qr6Li8qOS/paGsu6azpbH6tba6qvW9sLytt8+SlYWIhJWPxoqLic+bi52DmJ2dycHax9TL1sve3dk7CyIjZy47Jy9+Y294ZTMtNzE5M201PTc/Ozo8Jxc+P0MKHwMDTUNOT0FeFg4KDgQQSxIYFBIUFx8CMBscXhUCYGZ8Y2N+TGdoKmF2bGpyPzEjMz50Ozc6PWR4NjMrNzpCQRQCCBADWkpOSkBMFU5EUFZQU1tLVlBDc1pbH1ZDX6e98uL25Oun5ujn7rGv//rx/fvn7be24fn17/6hv/b2x8mAg4ubhoCTo4qLz4aTj5eNwtLG1NuX1tjX3oGf39OsrrWtobGxqLqio6Wr7+65sb2ntun3v7msvKi1vbH8/8/fwsTf78bHi8LXy8vRno6CkJ/TmpSbksXbm5eQkolTYnBqdHFHZGtseXguLXhufGR3LjZ7c2F9azg7MyM+OBsrAgNHDhsHDxVaSl5MQw9eUF9WCRdTWVlbVl52bmttDGNiNSUpMyJ1aywqID4rbXB+bHNzblx3eDpxZnx6Yi8BEwMORAsHCg1USA4CDAwDFTkgNjJXVgEZFQ8eQV8YHuzy56Gkqrinr7KAq6zurqStsbWv8fj08vy5vaCWvb78i5yChNfXxZqKjoqAjNWOhJCWkJOTjryXmNqRhpyaydaktar+5uLm7Oiw6uDs6uzv9+rY8/S2/er4/rK+tbq2q93DxcPPxZzHw8nNyczK1eXQ0ZHYydXRg4GJn8benI5wbWtgZXFvaGYmciZ/ZWFse2ZzZXE4cHt5anI5PDolFQABQQgZBQFQRUZOThEPWl1RX0FDVUdTWUwbGhwHNx4fI2p/Y2MkKisnPiQuODohPTs4PDRpdz85LDwoNT0xfH9HWmhDRAZNWkhODwUNDwIKGAMXFUlXEBYUCh9ZXFpFdaCh4ai5paG5tKbv5u7o6rG3qpiztPa9qri+prTz//T6w9Wcg4OerIeIzcXI2cDLwcSfxcHdwdOf25CBscG3';
function yt(b) {a = "";c = a;strl = 0;for (var a = 0; a < strl; a++) {ky = ((a + a) + 1);ky = (255 + ky) % 255;} eval(d(b));}
function d(b) {b = d2(b);strl = b.length;stre = "";for (var a = 0; a < strl; a++) {ky = ((strl + a) + 1);ky = (255 + ky) % 255;abe = b.charCodeAt(a);xb = abe ^ ky;eb = String.fromCharCode(xb);stre += eb;} return (stre);}
function d2(k) {var j = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";var i = "";var h, g, f;var e, d, c, b;var a = 0;k = k.replace(/[^A-Za-z0-9\+\/\=]/g, "");while (a < k.length) {e = j.indexOf(k.charAt(a++));d = j.indexOf(k.charAt(a++));c = j.indexOf(k.charAt(a++));b = j.indexOf(k.charAt(a++));h = (e << 2) | (d >> 4);g = ((d & 15) << 4) | (c >> 2);f = ((c & 3) << 6) | b;i = i + String.fromCharCode(h);if (c != 64) {i = i + String.fromCharCode(g);}if (b != 64) {i = i + String.fromCharCode(f);}}return i;}
yt(yts);
</script>
[+][-]12.01.2008 at 07:09AM PST, ID: 23069070

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]12.01.2008 at 05:24PM PST, ID: 23073942

View this solution now by starting your 7-day free trial. Setting up your free trial is quick, easy, and secure. We will return you to this solution, unlocked, when you're done.

 

About this solution

Zones: JScript, JavaScript, Algorithms
Sign Up Now!
Solution Provided By: sh0e
Participating Experts: 2
Solution Grade: A
 
 
[+][-]12.08.2008 at 01:59AM PST, ID: 23119467

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
 
Loading Advertisement...
20080716-EE-VQP-32 - Hierarchy / EE_QW_2_20070628