Twitch TV

Developer
Size
4,488 Kb
Views
36,432

How do I make an twitch tv?

Using the Twitch.tv API. What is a twitch tv? How do you make a twitch tv? This script and codes were developed by Nate Stoll on 09 September 2022, Friday.

Twitch TV Previews

Twitch TV - Script Codes HTML Codes

<!DOCTYPE html>
<html >
<head> <meta charset="UTF-8"> <title>Twitch TV</title> <meta name="viewport" content="width=device-width, initial-scale=1"> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/normalize/5.0.0/normalize.min.css"> <link rel='stylesheet prefetch' href='http://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/css/bootstrap.min.css'> <link rel="stylesheet" href="css/style.css">
</head>
<body> <div class="container"> <div class="row" id="header"> <h1>Nate's Twitch Streams</h1> <div class="menu"> <div class="selector active" id="all"> <div class="triangle"></div><p>See All</p> </div> <div class="selector" id="online"> <div class="triangle"></div><p>See Online</p> </div> <div class="selector" id="offline"> <div class="triangle"></div><p>See Offline</p> </div> </div> </div> <div id="display"> </div> <div class="row" id="footer"> <h2>Copyright Nate Stoll 2016<h2> </div>
</div> <script src='http://cdnjs.cloudflare.com/ajax/libs/jquery/2.1.3/jquery.min.js'></script>
<script src='http://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/js/bootstrap.min.js'></script>
<script src='https://cdnjs.cloudflare.com/ajax/libs/jquery/3.1.1/jquery.min.js'></script> <script src="js/index.js"></script>
</body>
</html>

Twitch TV - Script Codes CSS Codes

@import url("https://fonts.googleapis.com/css?family=Lobster|Gloria Hallelujah|Indie Flower");
body { background-color: #ecf0e7; font-family: 'Indie Flower'; font-weight: bold; font-size: 14px; color: #ecf0e7;
}
a, a:focus, a:hover, a:visited { color: #5dff3d;
}
h1 { font-family: 'Gloria Hallelujah', sans-serif; font-weight: Normal; font-variant: Small-Caps; text-align: left; margin: 15px 0px; font-size: 3.75em;
}
h2 { font-family: 'Indie Flower', sans-serif; font-weight: Normal; font-variant: Small-Caps; text-align: left; margin: 15px 0px; font-size: .75em;
}
.container { background-color: #e1e1e6; margin: 0px auto; padding: 0px; max-width: Auto; max-height: auto;
}
.row { margin: 2px 0px; padding: 5px; line-height: 50px;
}
.menu { position: absolute; right: 0px; bottom: 5px; color: #2e3b51; font-family: 'Oswald', sans-serif; font-size: 0.8em; font-weight: bold; text-transform: uppercase;
}
.menu #online .triangle { background-color: #5dff3d;
}
.menu #offline .triangle { background-color: #ecf0e7;
}
.menu .active, .menu .selector:hover { width: 105px !important; -webkit-transition: width 0.4s linear; transition: width 0.4s linear; cursor: pointer;
}
.menu .selector { line-height: 20px; height: 20px; background-color: #e1e1e6; padding: 0px 5px; margin: 2px 0px; width: 20px; overflow: hidden; float: right; clear: right; -webkit-transition: width 0.4s linear; transition: width 0.4s linear;
}
.menu .selector .triangle { background-color: transparent; float: left; margin: 5px 5px 5px 0px; width: 0; height: 0; border-left: 7px solid transparent; border-right: 7px solid transparent; border-bottom: 7px solid #2e3b51;
}
.menu .selector p { float: left; margin: 0px;
}
#header, #footer { position: relative; background-color: #2e3b51; color: #e1e1e6; padding: 5px 65px 5px 15px;
}
.logo { max-width: 50px; max-height: 50px; border-radius: 50%; border: 3px solid #e1e1e6;
}
.offline { background-color: #ff1616;
}
.online { background-color: #5dff3d; color: #2e3b51;
}
.online a, .online a:focus, .online a:hover, .online a:visited { color: #ff1616;
}
#streaming { font-style: italic;
}
#name, #streaming { line-height: 25px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; text-align: center;
}
@media (min-width: 768px) { .container { margin: 10px auto; } #name, #streaming { line-height: 50px; height: 50px; } #header { padding-left: 65px; }
}

Twitch TV - Script Codes JS Codes

var channels = ["ESL_SC2", "OgamingSC2", "cretetion", "freecodecamp", "storbeck", "habathcx", "RobotCaleb", "noobs2ninjas", "castro_1021"];
function getChannelInfo() { channels.forEach(function(channel) { function makeURL(type, name) { return 'https://wind-bow.hyperdev.space/twitch-api/' + type + '/' + name + '?callback=?'; }; $.getJSON(makeURL("streams", channel), function(data) { var game, status; if (data.stream === null) { game = "Offline"; status = "offline"; } else if (data.stream === undefined) { game = "Account Closed"; status = "offline"; } else { game = data.stream.game; status = "online"; }; $.getJSON(makeURL("channels", channel), function(data) { var logo = data.logo != null ? data.logo : "https://dummyimage.com/50x50/ecf0e7/5c5457.jpg&text=0x3F", name = data.display_name != null ? data.display_name : channel, description = status === "online" ? ': ' + data.status : ""; html = '<div class="row ' + status + '"><div class="col-xs-2 col-sm-1" id="icon"><img src="' + logo + '" class="logo"></div><div class="col-xs-10 col-sm-3" id="name"><a href="' + data.url + '" target="_blank">' + name + '</a></div><div class="col-xs-10 col-sm-8" id="streaming">'+ game + '<span class="hidden-xs">' + description + '</span></div></div>'; status === "online" ? $("#display").prepend(html) : $("#display").append(html); }); }); });
};
$(document).ready(function() { getChannelInfo(); $(".selector").click(function() { $(".selector").removeClass("active"); $(this).addClass("active"); var status = $(this).attr('id'); if (status === "all") { $(".online, .offline").removeClass("hidden"); } else if (status === "online") { $(".online").removeClass("hidden"); $(".offline").addClass("hidden"); } else { $(".offline").removeClass("hidden"); $(".online").addClass("hidden"); } })
});
Twitch TV - Script Codes
Twitch TV - Script Codes
Home Page Home
Developer Nate Stoll
Username natester13
Uploaded September 09, 2022
Rating 3
Size 4,488 Kb
Views 36,432
Do you need developer help for Twitch TV?

Find the perfect freelance services for your business! Fiverr's mission is to change how the world works together. Fiverr connects businesses with freelancers offering digital services in 500+ categories. Find Developer!

Nate Stoll (natester13) Script Codes
Create amazing web content with AI!

Jasper is the AI Content Generator that helps you and your team break through creative blocks to create amazing, original content 10X faster. Discover all the ways the Jasper AI Content Platform can help streamline your creative workflows. Start For Free!