SuperManifolds / alientube

Reddit comments, in your YouTube!
Other
59 stars 39 forks source link

AlienTube will not work when browsing within YouTube - Possible solution here #177

Open kashinoda opened 8 years ago

kashinoda commented 8 years ago

Absolutely fantastic extension but since YouTube changed how pages load within the site it doesn't work at all unless you hit refresh or visit from an external link.

There's actually a script that (for the most part) fixes this issue, could you implement it into AlienTube? https://greasyfork.org/en/scripts/11576-youtube-link-fix-for-addons-scripts

With this running in TamperMonkey (Chrome Extension), AlienTube seems to work when normally browsing within the site.

It will not work when clicking videos from within a channel (via. 'Uploads'), I believe this is because the links are formatted differently.

Standard Link <a href="/watch?v=YQHsXMglC9A" class="yt-uix-sessionlink yt-uix-tile-link yt-ui-ellipsis yt-ui-ellipsis-2 spf-link " data-sessionlink="itct=CEYQ3DAYAiITCMKqq7WukMsCFRWRHAodIpQLbyj0JFIFdmlkZW8" title="Adele - Hello" rel="spf-prefetch" aria-describedby="description-id-555294" dir="ltr">Adele - Hello</a>

Link Within A Channel (i.e http://i.imgur.com/M03D7x9.jpg) <a class="yt-uix-sessionlink yt-uix-tile-link spf-link yt-ui-ellipsis yt-ui-ellipsis-2" dir="ltr" title="Adele - Hello" aria-describedby="description-id-403257" data-sessionlink="ei=FJ3NVsaqKY-IcqrJlaAB&amp;feature=c4-videos-u&amp;ved=CDsQvxsiEwjGhPPQrpDLAhUPhBwKHapkBRQomxw" href="/watch?v=YQHsXMglC9A">Adele - Hello</a>

Someone with some JavaScript know-how could probably edit the script above to fix this.

Also, if Auto-Play or Playlist automatically plays another video then you'll have to refresh before the script will work again.

kashinoda commented 8 years ago

Also, you may have issues replicating this issue as YouTube don't roll out the updates to everyone at the same time. This explains why some people are still using this without a hitch. My friends was working fine but he now experiences the same issue as of yesterday.

Fastjur commented 8 years ago

Can confirm, this issue is also affecting me. I searched youtube for video's of pewdiepie (to be 100% sure that it would be linked somewhere on reddit). Alientube doesn't seem to load the reddit comments.

Steps to reproduce:

  1. Search for a video on YouTube (preferably a highly viewed one, to make sure it is posted somewhere on reddit)
  2. Alientube will not load, it will only show google+ comments.
  3. Refresth page, alientube will now load correctly
RayBB commented 8 years ago

I also would really like to see this fixed.

LitDub commented 7 years ago

I've been dealing with this for a year and just got around to trying to find a manual solution. This fix doesn't work for me. Has anyone found any other solution?

AjaxGb commented 7 years ago

Ah, didn't see this issue when I made Pull Request #197. It should completely fix this issue in one line of code. Basically, YouTube fires a custom event when it finishes doing its custom page-loading thing. We can just treat that event the same as a normal page-load event.