WP YouTube Lyte - Version 0.6.5

Version Description

  • updated images for html5-version to new look&feel
  • disabled "watch later" by adding variable "probably_logged_in=false" to youtube embed
  • changed lyte/lyte.css (move margin from .lt to .lyte) to allow changes to positioning of player
  • changed name of js-variable in options.php to solve small bug in rss display
  • added an (experimental) bonus feature
Download this release

Release Info

Developer futtta
Plugin Icon 128x128 WP YouTube Lyte
Version 0.6.5
Comparing to
See all releases

Code changes from version 0.6.4 to 0.6.5

external/donottrack-min.js ADDED
@@ -0,0 +1 @@
 
1
+ domwrite=document.write;document.write=sanitizer;var spy=['quantserve.com','media6degrees.com'];function sanitizer(tS){ttS=tS.toLowerCase();if((ttS.indexOf(unescape('%3Cscript'))!=-1)&&(ttS.indexOf(unescape('src='))!=-1)){for(x in spy){if(ttS.indexOf(spy[x])!=-1){tS=ttS.replace(/</g,'<!--').replace(/>/g,'-->');break;}}} writeOut(tS);} function writeOut(tS){document.write=domwrite;document.write(tS);document.write=sanitizer;} var a2a_config = a2a_config || {};a2a_config.no_3p = 1;
lyte/controls-newtube-425.png CHANGED
Binary file
lyte/controls-newtube-480.png CHANGED
Binary file
lyte/controls-newtube-560.png CHANGED
Binary file
lyte/controls-newtube-640.png CHANGED
Binary file
lyte/controls-newtube-853.png CHANGED
Binary file
lyte/lyte-min.js CHANGED
@@ -1 +1 @@
1
- var doc=document;var cI='lytecss';if(!doc.getElementById(cI)){var lk=doc.createElement('link');lk.id=cI;lk.rel='stylesheet';lk.type='text/css';lk.href=bU+'lyte.css';doc.getElementsByTagName('head')[0].appendChild(lk);}function lyte(){lytes=getElementsByClassName("lyte","div");for(var i=0;i<lytes.length;i++){lyte_id=lytes[i].id;p=doc.getElementById(lyte_id);p.className+=" lP";pW=p.clientWidth;pH=p.clientHeight;if(p.className.indexOf('widget')==-1){jsonUrl="http://gdata.youtube.com/feeds/api/videos/"+lyte_id+"?fields=id,title&alt=json-in-script&callback=parseMe";loadScript(jsonUrl)}pl=doc.createElement('div');p.appendChild(pl);p.onclick=nolyte;setStyle(p,'width:'+pW+'px;height:'+pH+'px;');pl.id="lyte_"+lyte_id;pl.className="pL";setStyle(pl,'height:'+pH+'px;width:'+pW+'px;background:url("http://img.youtube.com/vi/'+lyte_id+'/0.jpg") no-repeat scroll center -10px rgb(0, 0, 0);background-size:contain;');pl.innerHTML="<img src=\""+bU+"play.png\" alt=\"Click to play this video\" style=\"margin-top:"+((pH/2)-30)+"px;opacity:0.7;\" onmouseover=\"this.style.opacity=1;\" onmouseout=\"this.style.opacity=0.8;\"/><img src=\""+bU+"controls-"+pW+".png\" width=\"100%\" alt=\"\" id=\"ctrl\" style=\"max-width:"+pW+"px;\"/>";}}function nolyte(){this.onclick="";this.innerHTML="<embed src=\"http://www.youtube-nocookie.com/v/"+this.id+"&amp;autoplay=1&amp;rel=0&amp;egm=0&amp;fs=1&amp;iv_load_policy=3\" type=\"application/x-shockwave-flash\" allowfullscreen=\"true\" id=\"lyte_"+this.id+"\" wmode=\"transparent\" width=\""+this.clientWidth+"\" height=\""+this.clientHeight+"\" allowscriptaccess=\"always\"></embed>"}function parseMe(r){title=r.entry.title.$t;idu=r.entry.id.$t;p=doc.getElementById("lyte_"+idu.substring((idu.length-11)));c=doc.createElement('div');c.className="tC";p.appendChild(c);setStyle(c,"margin:-"+((p.clientHeight/2)+15)+"px 5px;");t=doc.createElement('div');t.className="tT";c.appendChild(t);t.innerHTML=title;}function setStyle(e,s){if(typeof e.setAttribute==="function")e.setAttribute('style',s);else if(typeof e.style.setAttribute==="object")e.style.setAttribute('cssText',s)}function loadScript(url){scr=doc.createElement('script');scr.src=url;scr.type='text/javascript';doc.getElementsByTagName('head')[0].appendChild(scr)}var getElementsByClassName=function(className,tag,elm){if(doc.getElementsByClassName){getElementsByClassName=function(className,tag,elm){elm=elm||doc;var elements=elm.getElementsByClassName(className),nodeName=(tag)?new RegExp("\\b"+tag+"\\b","i"):null,returnElements=[],current;for(var i=0,il=elements.length;i<il;i+=1){current=elements[i];if(!nodeName||nodeName.test(current.nodeName)){returnElements.push(current)}}return returnElements}}else if(doc.evaluate){getElementsByClassName=function(className,tag,elm){tag=tag||"*";elm=elm||doc;var classes=className.split(" "),classesToCheck="",xhtmlNamespace="http://www.w3.org/1999/xhtml",namespaceResolver=(doc.documentElement.namespaceURI===xhtmlNamespace)?xhtmlNamespace:null,returnElements=[],elements,node;for(var j=0,jl=classes.length;j<jl;j+=1){classesToCheck+="[contains(concat(' ', @class, ' '), ' "+classes[j]+" ')]"}try{elements=doc.evaluate(".//"+tag+classesToCheck,elm,namespaceResolver,0,null)}catch(e){elements=doc.evaluate(".//"+tag+classesToCheck,elm,null,0,null)}while((node=elements.iterateNext())){returnElements.push(node)}return returnElements}}else{getElementsByClassName=function(className,tag,elm){tag=tag||"*";elm=elm||doc;var classes=className.split(" "),classesToCheck=[],elements=(tag==="*"&&elm.all)?elm.all:elm.getElementsByTagName(tag),current,returnElements=[],match;for(var k=0,kl=classes.length;k<kl;k+=1){classesToCheck.push(new RegExp("(^|\\s)"+classes[k]+"(\\s|$)"))}for(var l=0,ll=elements.length;l<ll;l+=1){current=elements[l];match=false;for(var m=0,ml=classesToCheck.length;m<ml;m+=1){match=classesToCheck[m].test(current.className);if(!match){break}}if(match){returnElements.push(current)}}return returnElements}}return getElementsByClassName(className,tag,elm)};lyte();
1
+ var doc=document;var cI='lytecss';if(!doc.getElementById(cI)){var lk=doc.createElement('link');lk.id=cI;lk.rel='stylesheet';lk.type='text/css';lk.href=bU+'lyte.css';doc.getElementsByTagName('head')[0].appendChild(lk);}function lyte(){lytes=getElementsByClassName("lyte","div");for(var i=0;i<lytes.length;i++){lyte_id=lytes[i].id;p=doc.getElementById(lyte_id);p.className+=" lP";pW=p.clientWidth;pH=p.clientHeight;if(p.className.indexOf('widget')==-1){jsonUrl="http://gdata.youtube.com/feeds/api/videos/"+lyte_id+"?fields=id,title&alt=json-in-script&callback=parseMe";loadScript(jsonUrl)}pl=doc.createElement('div');p.appendChild(pl);p.onclick=nolyte;setStyle(p,'width:'+pW+'px;height:'+pH+'px;');pl.id="lyte_"+lyte_id;pl.className="pL";setStyle(pl,'height:'+pH+'px;width:'+pW+'px;background:url("http://img.youtube.com/vi/'+lyte_id+'/0.jpg") no-repeat scroll center -10px rgb(0, 0, 0);background-size:contain;');pl.innerHTML="<img src=\""+bU+"play.png\" alt=\"Click to play this video\" style=\"margin-top:"+((pH/2)-30)+"px;opacity:0.7;\" onmouseover=\"this.style.opacity=1;\" onmouseout=\"this.style.opacity=0.8;\"/><img src=\""+bU+"controls-"+pW+".png\" width=\"100%\" alt=\"\" id=\"ctrl\" style=\"max-width:"+pW+"px;\"/>";}}function nolyte(){this.onclick="";this.innerHTML="<embed src=\"http://www.youtube-nocookie.com/v/"+this.id+"&amp;autoplay=1&amp;rel=0&amp;egm=0&amp;fs=1&amp;iv_load_policy=3&amp;probably_logged_in=false\" type=\"application/x-shockwave-flash\" allowfullscreen=\"true\" id=\"lyte_"+this.id+"\" wmode=\"transparent\" width=\""+this.clientWidth+"\" height=\""+this.clientHeight+"\" allowscriptaccess=\"always\"></embed>"}function parseMe(r){title=r.entry.title.$t;idu=r.entry.id.$t;p=doc.getElementById("lyte_"+idu.substring((idu.length-11)));c=doc.createElement('div');c.className="tC";p.appendChild(c);setStyle(c,"margin:-"+((p.clientHeight/2)+15)+"px 5px;");t=doc.createElement('div');t.className="tT";c.appendChild(t);t.innerHTML=title;}function setStyle(e,s){if(typeof e.setAttribute==="function")e.setAttribute('style',s);else if(typeof e.style.setAttribute==="object")e.style.setAttribute('cssText',s)}function loadScript(url){scr=doc.createElement('script');scr.src=url;scr.type='text/javascript';doc.getElementsByTagName('head')[0].appendChild(scr)}var getElementsByClassName=function(className,tag,elm){if(doc.getElementsByClassName){getElementsByClassName=function(className,tag,elm){elm=elm||doc;var elements=elm.getElementsByClassName(className),nodeName=(tag)?new RegExp("\\b"+tag+"\\b","i"):null,returnElements=[],current;for(var i=0,il=elements.length;i<il;i+=1){current=elements[i];if(!nodeName||nodeName.test(current.nodeName)){returnElements.push(current)}}return returnElements}}else if(doc.evaluate){getElementsByClassName=function(className,tag,elm){tag=tag||"*";elm=elm||doc;var classes=className.split(" "),classesToCheck="",xhtmlNamespace="http://www.w3.org/1999/xhtml",namespaceResolver=(doc.documentElement.namespaceURI===xhtmlNamespace)?xhtmlNamespace:null,returnElements=[],elements,node;for(var j=0,jl=classes.length;j<jl;j+=1){classesToCheck+="[contains(concat(' ', @class, ' '), ' "+classes[j]+" ')]"}try{elements=doc.evaluate(".//"+tag+classesToCheck,elm,namespaceResolver,0,null)}catch(e){elements=doc.evaluate(".//"+tag+classesToCheck,elm,null,0,null)}while((node=elements.iterateNext())){returnElements.push(node)}return returnElements}}else{getElementsByClassName=function(className,tag,elm){tag=tag||"*";elm=elm||doc;var classes=className.split(" "),classesToCheck=[],elements=(tag==="*"&&elm.all)?elm.all:elm.getElementsByTagName(tag),current,returnElements=[],match;for(var k=0,kl=classes.length;k<kl;k+=1){classesToCheck.push(new RegExp("(^|\\s)"+classes[k]+"(\\s|$)"))}for(var l=0,ll=elements.length;l<ll;l+=1){current=elements[l];match=false;for(var m=0,ml=classesToCheck.length;m<ml;m+=1){match=classesToCheck[m].test(current.className);if(!match){break}}if(match){returnElements.push(current)}}return returnElements}}return getElementsByClassName(className,tag,elm)};lyte();
lyte/lyte-newtube-min.js CHANGED
@@ -1 +1 @@
1
- var doc=document;var cI='lytecss';if(!doc.getElementById(cI)){lk=doc.createElement('link');lk.id=cI;lk.rel='stylesheet';lk.type='text/css';lk.href=bU+'lyte.css';doc.getElementsByTagName('head')[0].appendChild(lk);}function lyte(){lytes=getElementsByClassName("lyte","div");for(var i=0;i<lytes.length;i++){lyte_id=lytes[i].id;p=doc.getElementById(lyte_id);p.className+=" lP";pW=p.clientWidth;pH=p.clientHeight;if(p.className.indexOf('widget')===-1){jsonUrl="http://gdata.youtube.com/feeds/api/videos/"+lyte_id+"?fields=id,title&alt=json-in-script&callback=parseMe";loadScript(jsonUrl)}pl=doc.createElement('div');p.appendChild(pl);p.onclick=nolyte;pl.id="lyte_"+lyte_id;pl.className="pL";setStyle(pl,'height:'+pH+'px;width:'+pW+'px;background:url("http://img.youtube.com/vi/'+lyte_id+'/0.jpg") no-repeat scroll center -10px rgb(0, 0, 0);background-size:contain;');pl.innerHTML="<img src=\""+bU+"play.png\" alt=\"Click to play this video\" style=\"margin-top:"+((pH/2)-30)+"px;opacity:0.7;\" onmouseover=\"this.style.opacity=1;\" onmouseout=\"this.style.opacity=0.8;\"/><img src=\""+bU+"controls-newtube-"+pW+".png\" width=\"100%\" id=\"ctrl\" alt=\"\" style=\"max-width:"+pW+"px;\"/>";}}function nolyte(){this.onclick="";this.innerHTML="<iframe class=\"youtube-player\" type=\"text/html\" width=\""+this.clientWidth+"\" height=\""+this.clientHeight+"\" src=\"http://www.youtube.com/embed/"+this.id+"?autoplay=1&amp;rel=0&amp;egm=0&amp;iv_load_policy=3\" frameborder=\"0\"></iframe>"}function parseMe(r){title=r.entry.title.$t;idu=r.entry.id.$t;p=doc.getElementById("lyte_"+idu.substring((idu.length-11)));c=doc.createElement('div');c.className="tC";p.appendChild(c);setStyle(c,"margin:-"+((p.clientHeight/2)+15)+"px 5px;");t=doc.createElement('div');t.className="tT";c.appendChild(t);t.innerHTML=title;}function setStyle(e,s){if(typeof e.setAttribute==="function")e.setAttribute('style',s);else if(typeof e.style.setAttribute==="object")e.style.setAttribute('cssText',s)}function loadScript(url){scr=doc.createElement('script');scr.src=url;scr.type='text/javascript';doc.getElementsByTagName('head')[0].appendChild(scr)}var getElementsByClassName=function(className,tag,elm){if(doc.getElementsByClassName){getElementsByClassName=function(className,tag,elm){elm=elm||doc;var elements=elm.getElementsByClassName(className),nodeName=(tag)?new RegExp("\\b"+tag+"\\b","i"):null,returnElements=[],current;for(var i=0,il=elements.length;i<il;i+=1){current=elements[i];if(!nodeName||nodeName.test(current.nodeName)){returnElements.push(current)}}return returnElements}}else if(doc.evaluate){getElementsByClassName=function(className,tag,elm){tag=tag||"*";elm=elm||doc;var classes=className.split(" "),classesToCheck="",xhtmlNamespace="http://www.w3.org/1999/xhtml",namespaceResolver=(doc.documentElement.namespaceURI===xhtmlNamespace)?xhtmlNamespace:null,returnElements=[],elements,node;for(var j=0,jl=classes.length;j<jl;j+=1){classesToCheck+="[contains(concat(' ', @class, ' '), ' "+classes[j]+" ')]"}try{elements=doc.evaluate(".//"+tag+classesToCheck,elm,namespaceResolver,0,null)}catch(e){elements=doc.evaluate(".//"+tag+classesToCheck,elm,null,0,null)}while((node=elements.iterateNext())){returnElements.push(node)}return returnElements}}else{getElementsByClassName=function(className,tag,elm){tag=tag||"*";elm=elm||doc;var classes=className.split(" "),classesToCheck=[],elements=(tag==="*"&&elm.all)?elm.all:elm.getElementsByTagName(tag),current,returnElements=[],match;for(var k=0,kl=classes.length;k<kl;k+=1){classesToCheck.push(new RegExp("(^|\\s)"+classes[k]+"(\\s|$)"))}for(var l=0,ll=elements.length;l<ll;l+=1){current=elements[l];match=false;for(var m=0,ml=classesToCheck.length;m<ml;m+=1){match=classesToCheck[m].test(current.className);if(!match){break}}if(match){returnElements.push(current)}}return returnElements}} return getElementsByClassName(className,tag,elm)};lyte();
1
+ var doc=document;var cI='lytecss';if(!doc.getElementById(cI)){lk=doc.createElement('link');lk.id=cI;lk.rel='stylesheet';lk.type='text/css';lk.href=bU+'lyte.css';doc.getElementsByTagName('head')[0].appendChild(lk);}function lyte(){lytes=getElementsByClassName("lyte","div");for(var i=0;i<lytes.length;i++){lyte_id=lytes[i].id;p=doc.getElementById(lyte_id);p.className+=" lP";pW=p.clientWidth;pH=p.clientHeight;if(p.className.indexOf('widget')===-1){jsonUrl="http://gdata.youtube.com/feeds/api/videos/"+lyte_id+"?fields=id,title&alt=json-in-script&callback=parseMe";loadScript(jsonUrl)}pl=doc.createElement('div');p.appendChild(pl);p.onclick=nolyte;pl.id="lyte_"+lyte_id;pl.className="pL";setStyle(pl,'height:'+pH+'px;width:'+pW+'px;background:url("http://img.youtube.com/vi/'+lyte_id+'/0.jpg") no-repeat scroll center -10px rgb(0, 0, 0);background-size:contain;');pl.innerHTML="<img src=\""+bU+"play.png\" alt=\"Click to play this video\" style=\"margin-top:"+((pH/2)-30)+"px;opacity:0.7;\" onmouseover=\"this.style.opacity=1;\" onmouseout=\"this.style.opacity=0.8;\"/><img src=\""+bU+"controls-newtube-"+pW+".png\" width=\"100%\" id=\"ctrl\" alt=\"\" style=\"max-width:"+pW+"px;\"/>";}}function nolyte(){this.onclick="";this.innerHTML="<iframe class=\"youtube-player\" type=\"text/html\" width=\""+this.clientWidth+"\" height=\""+this.clientHeight+"\" src=\"http://www.youtube.com/embed/"+this.id+"?autoplay=1&amp;rel=0&amp;egm=0&amp;iv_load_policy=3&amp;probably_logged_in=false\" frameborder=\"0\"></iframe>"}function parseMe(r){title=r.entry.title.$t;idu=r.entry.id.$t;p=doc.getElementById("lyte_"+idu.substring((idu.length-11)));c=doc.createElement('div');c.className="tC";p.appendChild(c);setStyle(c,"margin:-"+((p.clientHeight/2)+15)+"px 5px;");t=doc.createElement('div');t.className="tT";c.appendChild(t);t.innerHTML=title;}function setStyle(e,s){if(typeof e.setAttribute==="function")e.setAttribute('style',s);else if(typeof e.style.setAttribute==="object")e.style.setAttribute('cssText',s)}function loadScript(url){scr=doc.createElement('script');scr.src=url;scr.type='text/javascript';doc.getElementsByTagName('head')[0].appendChild(scr)}var getElementsByClassName=function(className,tag,elm){if(doc.getElementsByClassName){getElementsByClassName=function(className,tag,elm){elm=elm||doc;var elements=elm.getElementsByClassName(className),nodeName=(tag)?new RegExp("\\b"+tag+"\\b","i"):null,returnElements=[],current;for(var i=0,il=elements.length;i<il;i+=1){current=elements[i];if(!nodeName||nodeName.test(current.nodeName)){returnElements.push(current)}}return returnElements}}else if(doc.evaluate){getElementsByClassName=function(className,tag,elm){tag=tag||"*";elm=elm||doc;var classes=className.split(" "),classesToCheck="",xhtmlNamespace="http://www.w3.org/1999/xhtml",namespaceResolver=(doc.documentElement.namespaceURI===xhtmlNamespace)?xhtmlNamespace:null,returnElements=[],elements,node;for(var j=0,jl=classes.length;j<jl;j+=1){classesToCheck+="[contains(concat(' ', @class, ' '), ' "+classes[j]+" ')]"}try{elements=doc.evaluate(".//"+tag+classesToCheck,elm,namespaceResolver,0,null)}catch(e){elements=doc.evaluate(".//"+tag+classesToCheck,elm,null,0,null)}while((node=elements.iterateNext())){returnElements.push(node)}return returnElements}}else{getElementsByClassName=function(className,tag,elm){tag=tag||"*";elm=elm||doc;var classes=className.split(" "),classesToCheck=[],elements=(tag==="*"&&elm.all)?elm.all:elm.getElementsByTagName(tag),current,returnElements=[],match;for(var k=0,kl=classes.length;k<kl;k+=1){classesToCheck.push(new RegExp("(^|\\s)"+classes[k]+"(\\s|$)"))}for(var l=0,ll=elements.length;l<ll;l+=1){current=elements[l];match=false;for(var m=0,ml=classesToCheck.length;m<ml;m+=1){match=classesToCheck[m].test(current.className);if(!match){break}}if(match){returnElements.push(current)}}return returnElements}} return getElementsByClassName(className,tag,elm)};lyte();
lyte/lyte.css CHANGED
@@ -1 +1 @@
1
- .lyte img {border:0px;padding:0px;spacing:0px;margin:0px;display:inline;} .lL {margin:0px 0px 10px 0px;} .lP {margin:5px 0px;background-color:#000;} .pL {cursor:pointer;text-align:center;overflow:hidden;position:relative;margin:0px;} .tC {position:relative;padding:5px;background-color:rgba(0,0,0,0.3);-moz-border-radius:7px;-webkit-border-radius:7px;border-radius:7px;} .tT {font-weight:bold;font-size:16px;color:#ffffff;font-family:sans-serif;text-align:left;} #ctrl {position:absolute;left:0px;bottom:0px;}
1
+ .lyte img {border:0px;padding:0px;spacing:0px;margin:0px;display:inline;} .lL {margin:0px 0px 10px 0px;} .lyte {margin:5px 0px;} .lP {background-color:#000;} .pL {cursor:pointer;text-align:center;overflow:hidden;position:relative;margin:0px;} .tC {position:relative;padding:5px;background-color:rgba(0,0,0,0.3);-moz-border-radius:7px;-webkit-border-radius:7px;border-radius:7px;} .tT {font-weight:bold;font-size:16px;color:#ffffff;font-family:sans-serif;text-align:left;} #ctrl {position:absolute;left:0px;bottom:0px;}
options.php CHANGED
@@ -14,12 +14,13 @@ function register_lyte_settings() {
14
  register_setting( 'lyte-settings-group', 'newTube' );
15
  register_setting( 'lyte-settings-group', 'show_links' );
16
  register_setting( 'lyte-settings-group', 'size' );
 
17
  }
18
 
19
  function lyte_admin_scripts() {
20
  global $wp_lyte_plugin_url;
21
- wp_enqueue_script('zrssfeed',$wp_lyte_plugin_url.'external/jquery.zrssfeed.min.js',array(jquery),null,true);
22
- wp_enqueue_script('cookie',$wp_lyte_plugin_url.'external/jquery.cookie.min.js',array(jquery),null,true);
23
  }
24
 
25
  function lyte_admin_styles() {
@@ -77,6 +78,16 @@ function lyte_settings_page() {
77
  </fieldset>
78
  </td>
79
  </tr>
 
 
 
 
 
 
 
 
 
 
80
  </table>
81
 
82
  <p class="submit">
@@ -104,12 +115,12 @@ function lyte_settings_page() {
104
  feed[1]="http://feeds.feedburner.com/futtta_wp-youtube-lyte";
105
  feed[2]="http://feeds.feedburner.com/futtta_wordpress";
106
  feed[3]="http://feeds.feedburner.com/futtta_webtech";
107
- cookie="wp-youtube-lyte_feed";
108
 
109
  jQuery(document).ready(function() {
110
  jQuery("#feed_dropdown").change(function() { show_feed(jQuery("#feed_dropdown").val()) });
111
 
112
- feedid=jQuery.cookie(cookie);
113
  if(typeof(feedid) !== "string") feedid=1;
114
 
115
  show_feed(feedid);
@@ -122,7 +133,7 @@ function lyte_settings_page() {
122
  header: false
123
  });
124
  jQuery("#feed_dropdown").val(id);
125
- jQuery.cookie(cookie,id,{ expires: 365 });
126
  }
127
  </script>
128
 
14
  register_setting( 'lyte-settings-group', 'newTube' );
15
  register_setting( 'lyte-settings-group', 'show_links' );
16
  register_setting( 'lyte-settings-group', 'size' );
17
+ register_setting( 'lyte-settings-group', 'donottrack' );
18
  }
19
 
20
  function lyte_admin_scripts() {
21
  global $wp_lyte_plugin_url;
22
+ wp_enqueue_script('jqzrssfeed',$wp_lyte_plugin_url.'external/jquery.zrssfeed.min.js',array(jquery),null,true);
23
+ wp_enqueue_script('jqcookie',$wp_lyte_plugin_url.'external/jquery.cookie.min.js',array(jquery),null,true);
24
  }
25
 
26
  function lyte_admin_styles() {
78
  </fieldset>
79
  </td>
80
  </tr>
81
+ <tr valign="top">
82
+ <th scope="row">Bonus feature: <a href="http://blog.futtta.be/tag/donottrack" target="_blank">DoNotTrack</a></th>
83
+ <td>
84
+ <fieldset>
85
+ <legend class="screen-reader-text"><span>Activate DoNotTrack</span></legend>
86
+ <label title="Enable DoNotTrack"><input type="radio" name="donottrack" value="1" <?php if (get_option('donottrack')==="1") echo "checked" ?> />Disable 3rd party tracking.</label><br />
87
+ <label title="Leave DoNotTrack disabled (default)"><input type="radio" name="donottrack" value="0" <?php if (get_option('donottrack')!=="1") echo "checked" ?> />I don't mind 3rd party tracking (default)</label>
88
+ </fieldset>
89
+ </td>
90
+ </tr>
91
  </table>
92
 
93
  <p class="submit">
115
  feed[1]="http://feeds.feedburner.com/futtta_wp-youtube-lyte";
116
  feed[2]="http://feeds.feedburner.com/futtta_wordpress";
117
  feed[3]="http://feeds.feedburner.com/futtta_webtech";
118
+ cookiename="wp-youtube-lyte_feed";
119
 
120
  jQuery(document).ready(function() {
121
  jQuery("#feed_dropdown").change(function() { show_feed(jQuery("#feed_dropdown").val()) });
122
 
123
+ feedid=jQuery.cookie(cookiename);
124
  if(typeof(feedid) !== "string") feedid=1;
125
 
126
  show_feed(feedid);
133
  header: false
134
  });
135
  jQuery("#feed_dropdown").val(id);
136
+ jQuery.cookie(cookiename,id,{ expires: 365 });
137
  }
138
  </script>
139
 
readme.txt CHANGED
@@ -3,7 +3,7 @@ Contributors: futtta
3
  Tags: youtube, video, lyte, lite youtube embeds, html5 video, html5, widget
4
  Requires at least: 2.9
5
  Tested up to: 3.1
6
- Stable tag: 0.6.4
7
 
8
  "Lite YouTube Embeds" look like normal YouTube embeds but don't use Flash, thus reducing download size & page rendering time.
9
 
@@ -53,6 +53,13 @@ As opposed to some of the [most important](http://blog.futtta.be/2010/12/15/word
53
  * [Rate my plugin on wordpress.org](http://wordpress.org/extend/plugins/wp-youtube-lyte/), even if you think it stinks ;-)
54
 
55
  == Changelog ==
 
 
 
 
 
 
 
56
  = 0.6.4 =
57
  * happy New Year & thanks for the 10.000 downloads so far!
58
  * solved an [issue with pre-5.2.1 versions of PHP which caused errors in widget.php](http://wordpress.org/support/topic/plugin-wp-youtube-lyte-parse_url-error-in-widget-version)
3
  Tags: youtube, video, lyte, lite youtube embeds, html5 video, html5, widget
4
  Requires at least: 2.9
5
  Tested up to: 3.1
6
+ Stable tag: 0.6.5
7
 
8
  "Lite YouTube Embeds" look like normal YouTube embeds but don't use Flash, thus reducing download size & page rendering time.
9
 
53
  * [Rate my plugin on wordpress.org](http://wordpress.org/extend/plugins/wp-youtube-lyte/), even if you think it stinks ;-)
54
 
55
  == Changelog ==
56
+ = 0.6.5 =
57
+ * updated images for html5-version to new look&feel
58
+ * disabled "watch later" by adding variable "probably_logged_in=false" to youtube embed
59
+ * changed lyte/lyte.css (move margin from .lt to .lyte) to allow changes to positioning of player
60
+ * changed name of js-variable in options.php to solve small bug in rss display
61
+ * added an (experimental) bonus feature
62
+
63
  = 0.6.4 =
64
  * happy New Year & thanks for the 10.000 downloads so far!
65
  * solved an [issue with pre-5.2.1 versions of PHP which caused errors in widget.php](http://wordpress.org/support/topic/plugin-wp-youtube-lyte-parse_url-error-in-widget-version)
wp-youtube-lyte.php CHANGED
@@ -4,7 +4,7 @@ Plugin Name: WP YouTube Lyte
4
  Plugin URI: http://blog.futtta.be/tag/lyte
5
  Description: WordPress Lite YouTube Embeds (with optional HTML5 video) in posts.
6
  Author: Frank Goossens (futtta)
7
- Version: 0.6.4
8
  Author URI: http://blog.futtta.be/
9
  */
10
 
@@ -59,4 +59,16 @@ function lyte_parse($the_content) {
59
  }
60
 
61
  add_filter('the_content', 'lyte_parse', 90);
 
 
 
 
 
 
 
 
 
 
 
 
62
  ?>
4
  Plugin URI: http://blog.futtta.be/tag/lyte
5
  Description: WordPress Lite YouTube Embeds (with optional HTML5 video) in posts.
6
  Author: Frank Goossens (futtta)
7
+ Version: 0.6.5
8
  Author URI: http://blog.futtta.be/
9
  */
10
 
59
  }
60
 
61
  add_filter('the_content', 'lyte_parse', 90);
62
+
63
+ /* donottrack */
64
+ $donottrack_js=$wp_lyte_plugin_url."external/donottrack-min.js";
65
+
66
+ function init_lyte_donottrack() {
67
+ global $donottrack_js;
68
+ wp_enqueue_script( 'donottrack',$donottrack_js );
69
+ }
70
+
71
+ if (get_option('donottrack')==="1") {
72
+ add_action('init', 'init_lyte_donottrack');
73
+ }
74
  ?>