View Full Version : Code for playing YouTube through your own domain, without the distractions

05-06-2014, 11:01 PM
Putting this code (http://mesdomaines.nu/cleantube/cleantube.txt) on a page of your site allows you to play YouTube videos without the distractions around them (and without the ads) THROUGH YOUR OWN DOMAIN.

You'll have a page that dynamically adapts to the video url you put in the address bar. The '? button' on your page will tell you how the url should look like.

It will also tell you how you can turn your page into a data base for YouTube videos (without the distractions, because the videos are played through your domain). In that case you don't put video urls in the address bar yourself, but let links do the job.

It's recommended to name your page 'index.html' and to put it in a separate folder, but this is not a requirement.

The video urls accept a parameter info=..., which allows you to provide info about the videos at the top of the page. Other features include a stop button, a replay button that can be used even if the videos is still playing, a share button and parameters for playlists and chopping the videos.

Your own page will serve as a demo. Just copy the code above, paste it into your page and click on the '? button' for info. For people who cannot create their own page I've created http://mesdomaines.nu/cleantube.

05-22-2014, 08:03 AM
There was nothing in the demo link?

05-22-2014, 12:08 PM
Right, there's nothing in the demo link because you are supposed to do something first. Click on '?' at the top of the demo to see what you can / should do. For instance, you could put this in the address bar:
That will display a YouTube video (without the distractions) through http://mesdomaines.nu/cleantube. (In this case, the video starts at 20 secs and stops at 70 secs). But http://mesdomaines.nu/cleantube allows you to do a lot of other things. Read the instructions by clicking on '?'.

08-20-2014, 06:27 PM
As mentioned by DD-visitors, my info on how to use the script I wrote for playing YouTube videos without the ads and other distractions was not very clear. So I revised the whole thing. Everything should be much clearer now, follow this link (http://mesdomaines.nu/cleantube/).