This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function parseVideo (url) { | |
// - Supported YouTube URL formats: | |
// - http://www.youtube.com/watch?v=My2FRPA3Gf8 | |
// - http://youtu.be/My2FRPA3Gf8 | |
// - https://youtube.googleapis.com/v/My2FRPA3Gf8 | |
// - Supported Vimeo URL formats: | |
// - http://vimeo.com/25451551 | |
// - http://player.vimeo.com/video/25451551 | |
// - Also supports relative URLs: | |
// - //player.vimeo.com/video/25451551 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
'#ff2233'.substr(1).match(/.{2}/g).reverse().join('') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#EXTM3U | |
#EXTINF:-1 tvg-logo="https://upload.wikimedia.org/wikipedia/commons/6/65/Animaxlogo-20160701.png" group-title="INFANTILES",ANIMAX | |
http://video7.stream.mx:1935/raxatv/raxatv/chunklist_w884577146.m3u8 | |
#EXTINF:-1 tvg-logo="http://i.imgur.com/exvuGgQ.png" group-title="INFANTILES",ANIME TV | |
http://video7.stream.mx:1935/raxatv/raxatv/chunklist_w884577146.m3u8?JoCaRoIPTV.m3u8 | |
#EXTINF:-1 tvg-logo="https://vignette.wikia.nocookie.net/logopedia/images/c/ca/Baby_TV.png/revision/latest?cb=20111201223043" group-title="INFANTILES",BABY TV | |
http://tstv.lcdn.claro.net.co/Content/hls_clear/Live/Channel(BABYTV)/index.m3u8 | |
#EXTINF:-1 tvg-logo="https://upload.wikimedia.org/wikipedia/commons/thumb/4/41/Boomerang_tv_logo.png/607px-Boomerang_tv_logo.png" group-title="INFANTILES",BOOMERANG | |
http://live.izzitv.mx/Content/HLS/Live/Channel(BOOMERANG)/index.m3u8 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
//Convert JSONfeed to RSS in a single function as a drop-in to make adding JSONfeed | |
//support to an aggregator easier | |
function convert_jsonfeed_to_rss($content = NULL, $max = NULL) | |
{ | |
//Test if the content is actual JSON | |
json_decode($content); | |
if( json_last_error() !== JSON_ERROR_NONE) return FALSE; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#EXTM3U | |
#EXTINF:0 type="stream" tvg-logo="http://cdn.idealo.com/folder/Product/61/5/61572/s11_produktbild_mid/sony-icf-c390.jpg" , Radios pelo Mundo | |
http://devimages.apple.com/iphone/samples/bipbop/bipbopall.m3u8 | |
#EXTINF:0 type="stream" tvg-logo="http://cdn.letras.com.br/arquivos/fotos/capas/46/0004553,roberto-carlos-as-baleias.jpg" , Radio Roberto Carlos | |
http://192.99.150.31:9137/stream | |
#EXTINF:0 type="stream" tvg-logo="https://static-media.streema.com/media/object-images/8227804f7f5c47d0956ffa91c0ee08ac.png" , Coca -Cola FM | |
http://s.imusicaradios.com.br:1935/imusica_radio/brasil.stream/playlist.m3u8 | |
#EXTINF:0 type="stream" tvg-logo="https://lh5.ggpht.com/CUcQeArXPT-UOS95gPQOr4OPEvyLnofZ5_SdaM8UJUFnetadqsx2L35mhuDhcR9xglbl=w300" , New Age | |
http://192.99.150.31:8353/stream | |
#EXTINF:0 type="stream" tvg-logo="https://www.programamaistorcedor.com.br/uploads/parceiro/logo/17/Mundo_dos_esportes_logo.jpg" , Mundo dos Esportes |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[ | |
{ | |
"Arts": [ | |
"Design", | |
"Fashion & Beauty", | |
"Food", | |
"Literature", | |
"Performing Arts", | |
"Visual Arts" | |
] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function hasClass(el, className) { | |
return el.classList ? el.classList.contains(className) : new RegExp('\\b' + className + '\\b').test(el.className); | |
} | |
function addClass(el, className) { | |
if (el.classList) el.classList.add(className); | |
else if (!hasClass(el, className)) el.className += ' ' + className; | |
} | |
function removeClass(el, className) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Async/Await requirements: Latest Chrome/FF browser or Babel: https://babeljs.io/docs/plugins/transform-async-to-generator/ | |
// Fetch requirements: Latest Chrome/FF browser or Github fetch polyfill: https://github.com/github/fetch | |
// async function | |
async function fetchAsync () { | |
// await response of fetch call | |
let response = await fetch('https://api.github.com'); | |
// only proceed once promise is resolved | |
let data = await response.json(); | |
// only proceed once second promise is resolved |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var fs = require('fs'); | |
var url = require('url'); | |
var exec = require('child_process').exec; | |
var spawn = require('child_process').spawn; | |
// Function to download file using wget | |
var download_file_wget = function(file_url, download_dir, file_name_to_save, onProgress, cb) { | |
// extract the file name | |
var file_name = url.parse(file_url).pathname.split('/').pop(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Simple Node.js script to turn a specific page on a Google Sheet | |
* into a JSON object for the main purpose of HTML Templating. | |
* | |
* @author jonobr1 / http://jonobr1.com | |
* | |
*/ | |
var https = require('https'); | |
var path = require('path'); |