Selfhosted Youtube player which removes tracking and ads

nipos d229b032d2 Fixed a small bug in the README 5 years ago
LICENSE c588a824af Initial commit 5 years ago
README.md d229b032d2 Fixed a small bug in the README 5 years ago
bootstrap-responsive.css 9d05d2714b First version 5 years ago
bootstrap.css 9d05d2714b First version 5 years ago
holaplayer.js f419ac6671 Added new player with better design and more options 5 years ago
index.php f419ac6671 Added new player with better design and more options 5 years ago
ytclass.php f419ac6671 Added new player with better design and more options 5 years ago

README.md

YouPlay

YouPlay is a small Youtube player you can host on your own server. It loads media files directly from Youtube what is often required for copyright reasons but it uses a native HTML5 media object which doesn't track you that much and does not display any ads. Of course it can't prevent Google from getting your IP address and your useragent but they DO NOT get your clicks, mouse moves or other data which is not sent by a basic HTTPS request. It works similar to https://invidio.us but you can only watch videos or listen to music videos here which the owner of the YouPlay site added manually to the database. You'll see in the names of the MySQL columns that it's originally meant for music videos but it will work with every other video, too.

Requirements

  • Any webserver software
  • PHP 7 recommended but 5 should work, too
  • MySQL database
  • PHP cURL extension

Installation

Upload it, add your MySQL connection to the config variables in index.php and run the following SQL commands. This will create the YouPlay table and add some example music videos.

-- Adminer 4.3.1 MySQL dump

SET NAMES utf8;
SET time_zone = '+00:00';
SET foreign_key_checks = 0;
SET sql_mode = 'NO_AUTO_VALUE_ON_ZERO';

CREATE TABLE `youplay` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `artist` varchar(255) NOT NULL,
  `title` varchar(255) NOT NULL,
  `watchid` varchar(20) NOT NULL,
  PRIMARY KEY (`id`)
) ENGINE=MyISAM AUTO_INCREMENT=5 DEFAULT CHARSET=latin1;

INSERT INTO `youplay` (`id`, `artist`, `title`, `watchid`) VALUES
(1,	'Helene Fischer',	'Atemlos durch die Nacht',	'2czABFw6RnE'),
(2,	'Helene Fischer',	'Hallelujah',	'I234Q56Ra9w'),
(3,	'Helene Fischer',	'The Power Of Love',	'F3lUpJGSnw4'),
(4,	'Helene Fischer',	'I will always love you',	'wjHRqE0FXSE');

-- 2018-11-29 13:58:57

Credits