YePpHa / YouTubeCenter

YouTube Center is a userscript designed to expand the functionality of YouTube. It includes the ability to download the video you're watching, auto selecting your preferred video quality and much more.
MIT License
2.89k stars 520 forks source link

YTC not working since firefox v36. #1691

Open mq31 opened 9 years ago

mq31 commented 9 years ago

hi guys, for me the issue occures even with the developer version. happened since firefox 36 or since the youtube page design update, not exactly sure which update caused it. besides the addon appearing in the addon menu of firefox, no other sign of activity.

the YTC button does not actualy appear on youtube, if i press options in the addon menu it just opens youtube. i have tried disableing all other addons and even a firefox fresh install.

i would really appreciate some help. thank you!

YePpHa commented 9 years ago

I will try to figure out why it happens.

YePpHa commented 9 years ago

How did you install YouTube Center? Did you install the xpi file or using the userscript version with Greasemonley?

S-ed commented 9 years ago

I had this problem with Greasemonkey, maybe this helps:

var support = (function(){
...
    return {
      localStorage: localStorageTest(),
      //Greasemonkey: (typeof GM_setValue !== "undefined" && (typeof GM_setValue.toString === "undefined" || GM_setValue.toString().indexOf("not supported") === -1)),
      Adguard: (typeof AdguardSettings === "object"),
      cloneInto: (typeof cloneInto === "function"),
      CustomEvent: customEvent()
 };
 })();

Commenting Greasemonkey line could help to run YTC. Since in FFox access to GM_setValue.toString was disabled this call cause:

Permission denied to access property "toString"

FFox just stops parsing .js file on that line.

mq31 commented 9 years ago

i had the xpi installed . i have tried now the userscript with Greasemonkey and i got YTC back on my browser :smile:

it didnt even cross my mind to test with Greasemonkey, sorry

notlamprey commented 9 years ago

Edited my userscript as described above by S-ed, and YouTube Center works correctly. Using Firefox 37.0.2 here.

ghost commented 9 years ago

On me YTC doesn't work either. Same Problem as OP.

I've installed it normally over the Firefox Addon Site.

I tryed it with Greasmonkey and It didn't worked. And I'm not sure where to put the Code from S-ed so I can't tell if it works or not.

Using Firefox 37.0.2

S-ed commented 9 years ago

@Ghost1607 My solution for GM version, In the list of Greasemonkey scripts, usually under addons (about:addons) a User Scripts tab exist. Select a YouTube Center and right click it > Edit screenshot 203 find a following line

Greasemonkey: (typeof GM_setValue !== "undefined" && (typeof GM_setValue.toString === "undefined" || GM_setValue.toString().indexOf("not supported") === -1)),

put a comment on it (double slash //)

ghost commented 9 years ago

Ah amazing I got it :-)

Thank you very much, it works now!

ghost commented 9 years ago

Oh now I have a little thingy: The settings won't be saved. I set firefox, that it deletes all Cookies. I Assume that the Settings are saved in a Cookie? Wich should I put in the whitelist?

S-ed commented 9 years ago

YTC could use:

Greasemonkey's GM_getValue
FFox's localStorage
Cookies

In my case it's localStorage, and Cookies not working in my case (even if I force to use them, YTC only creates them but not reads). Make sure You've updated to last GM version.