├── .gitignore ├── .idea ├── Radio.iml ├── codeStyles │ └── codeStyleConfig.xml ├── discord.xml ├── modules.xml ├── prettier.xml ├── vcs.xml └── workspace.xml ├── README.md ├── about.html ├── app.js ├── contact.html ├── featured-radios.json ├── index.css ├── index.html ├── index.js ├── legacy ├── legacy.css ├── legacy.html └── legacy.js └── radios.json /.gitignore: -------------------------------------------------------------------------------- 1 | node_modules -------------------------------------------------------------------------------- /.idea/Radio.iml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /.idea/codeStyles/codeStyleConfig.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 5 | -------------------------------------------------------------------------------- /.idea/discord.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 6 | -------------------------------------------------------------------------------- /.idea/modules.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /.idea/prettier.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 7 | -------------------------------------------------------------------------------- /.idea/vcs.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /.idea/workspace.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 64 | 65 | 66 | 67 | 68 | 69 | 70 |
71 | 86 |
87 | 88 | 89 | 90 | 91 | -------------------------------------------------------------------------------- /app.js: -------------------------------------------------------------------------------- 1 | const featuredStationsContainer = document.getElementsByClassName('featured-stations-container')[0] 2 | 3 | // FEATURED STATIONS 4 | fetch('https://raw.githubusercontent.com/web-radio/webradio/master/featured-radios.json') 5 | .then(response => response.json()) 6 | .then(data => { 7 | const featuredRadios = data 8 | 9 | featuredRadios.forEach(radio => { 10 | console.log(radio.name) 11 | 12 | // UI PART 13 | const stationDiv = document.createElement('div') // create div element 14 | stationDiv.classList = 'bd-example h-100 m-1 col-xs-6' // add classes and css styles (inline css currently only for testing) 15 | stationDiv.style = 'width: 175px;' 16 | if (radio.id == 3) { 17 | stationDiv.innerHTML = ` 18 | ${radio.name} logo 19 | ${radio.name}
20 | ` // INNER HTML TEMPLATE, SAME AS index.html L73 21 | } else { 22 | stationDiv.innerHTML = ` 23 | ${radio.name} logo 24 | ${radio.name}
25 | ` // INNER HTML TEMPLATE, SAME AS index.html L73 26 | } 27 | 28 | featuredStationsContainer.appendChild(stationDiv) 29 | 30 | // TECHNIC PART 31 | const playbtn = document.querySelector(`.play-btn-${radio.id}`) 32 | let playing = false 33 | let station = new Audio(radio.link) 34 | 35 | playbtn.addEventListener('click', () => { 36 | let icon = playbtn.childNodes[0] 37 | 38 | if(playing == false) { 39 | playing = true 40 | station.play() 41 | icon.classList = 'bi-pause' 42 | } else { 43 | playing = false 44 | station.pause() 45 | icon.classList = 'bi-play' 46 | } 47 | }) 48 | }); 49 | }); 50 | 51 | // SEARCHING 52 | const submitBtn = document.getElementsByClassName('btn-submit')[0] 53 | const searchField = document.getElementsByClassName('search-field')[0] 54 | const searchResultContainer = document.getElementsByClassName('search-result-container')[0] 55 | const featuredStationsSection = document.getElementsByClassName('featured-stations')[0] 56 | const searchResultSection = document.getElementsByClassName('search-result')[0] 57 | const searchResultHeader = document.getElementsByClassName('search-result-header')[0] 58 | 59 | submitBtn.addEventListener('click', () => { 60 | const searchedRadio = searchField.value 61 | 62 | // MAKE FEATURED STATIONS INVISIBLE 63 | featuredStationsSection.style = 'display: none;' 64 | searchResultSection.style = 'display: block;' 65 | // FETCH STATIONS FROM API 66 | fetch(`https://de1.api.radio-browser.info/json/stations/byname/${searchedRadio}`) 67 | .then(response => response.json()) 68 | .then(data => { 69 | console.log(data) 70 | searchResultContainer.innerHTML = "" // REMOVE SEARCH RESULT CONTAINER HTML 71 | data.forEach(radio => { 72 | // UI PART 73 | searchResultHeader.innerText = `Wyniki wyszukiwania dla "${searchedRadio}"` 74 | const stationDiv = document.createElement('div') // create div element 75 | stationDiv.classList = 'bd-example h-100 m-1 col-xs-6' // add classes and css styles (inline css currently only for testing) 76 | stationDiv.style = 'width: 175px; max-height: 190px;' 77 | if (!radio.favicon) { 78 | stationDiv.innerHTML = ` 79 | No icon for ${radio.name} logo 80 | ${radio.name}
81 | ` // INNER HTML TEMPLATE, SAME AS index.html L73 82 | } else { 83 | stationDiv.innerHTML = ` 84 | ${radio.name} logo 85 | ${radio.name}
86 | ` // INNER HTML TEMPLATE, SAME AS index.html L73 87 | } 88 | 89 | searchResultContainer.append(stationDiv) 90 | 91 | // TECHNIC PART 92 | const playbtn = document.querySelector(`.play-btn-${radio.stationuuid}`) 93 | let playing = false 94 | let station = new Audio(radio.url_resolved) 95 | 96 | playbtn.addEventListener('click', () => { 97 | let icon = playbtn.childNodes[0] 98 | 99 | if(playing == false) { 100 | playing = true 101 | station.play() 102 | icon.classList = 'bi-pause' 103 | } else { 104 | playing = false 105 | station.pause() 106 | icon.classList = 'bi-play' 107 | } 108 | }) 109 | }) 110 | }) 111 | }) 112 | 113 | // additional back feature 114 | document.getElementsByClassName('navbar-brand')[0].addEventListener('click', () => { 115 | featuredStationsSection.style = 'display: block;' 116 | searchResultSection.style = 'display: none;' 117 | }) 118 | -------------------------------------------------------------------------------- /contact.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | Webradio 8 | 9 | 10 | 11 | 42 | 43 | 44 | 69 | 70 |
71 | 83 |
84 | 85 | 86 | 87 | 88 | -------------------------------------------------------------------------------- /featured-radios.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "id": 0, 4 | "name": "RMF FM", 5 | "icon": "http://www.rmfon.pl/i/logos/100x100/rmf.png", 6 | "link": "http://195.150.20.9/RMFFM48" 7 | }, 8 | { 9 | "id": 1, 10 | "name": "Radio Nowy świat", 11 | "icon": "https://mytuner.global.ssl.fastly.net/media/tvos_radios/d7cncggk4dvq.jpg", 12 | "link": "https://n12.rcs.revma.com/ypqt40u0x1zuv?rj-ttl=5&rj-tok=AAABeect65gAp-ayyf8dAhnI8A" 13 | 14 | }, 15 | { 16 | "id": 2, 17 | "name": "Radio Zet", 18 | "icon": "https://prowly-uploads.s3.eu-west-1.amazonaws.com/uploads/4587/assets/46969/radio_zet_rozszerzony_rgb_red_72dpi.png", 19 | "link": "https://zt01.cdn.eurozet.pl/zet-old.mp3" 20 | }, 21 | { 22 | "id": 3, 23 | "name": "Polskie Radio Czwórka", 24 | "icon": "https://moje.polskieradio.pl/_img/kanaly/pr4.jpg", 25 | "link": "http://stream3.polskieradio.pl:8906/;stream" 26 | }, 27 | { 28 | "id": 4, 29 | "name": "Radio SUR", 30 | "icon": "https://i.imgur.com/rgzBp75.png", 31 | "link": "https://sur.radio.fm/stream_320.mp3" 32 | } 33 | ] 34 | -------------------------------------------------------------------------------- /index.css: -------------------------------------------------------------------------------- 1 | :root { 2 | --card-background: #fff 3 | } 4 | 5 | body { 6 | margin: 0; 7 | padding: 0; 8 | box-sizing: border-box; 9 | font-family: 'Roboto', sans-serif; 10 | color: #121212; 11 | } 12 | 13 | .container { 14 | height: 100% !important; 15 | } 16 | 17 | .content { 18 | display: flex !important; 19 | flex-flow: row wrap; 20 | } 21 | 22 | span.mdi { 23 | font-size: 20px; 24 | } 25 | 26 | .searcher { 27 | margin-right: auto; 28 | margin-left: auto; 29 | display: block; 30 | width: 200px; 31 | } 32 | 33 | .mdc-text-field { 34 | height: 40px !important; 35 | } 36 | 37 | .mdc-card { 38 | margin: 15px; 39 | width: 300px; 40 | height: 200px; 41 | padding: 10px; 42 | flex: 1 300px; 43 | } 44 | 45 | .mdc-card__media { 46 | height: 70px; 47 | } 48 | 49 | .stationName { 50 | font-size: 20px; 51 | } 52 | 53 | .controls-play { 54 | margin-top: auto; 55 | } 56 | 57 | a { 58 | color: white; 59 | text-decoration: none; 60 | } 61 | 62 | li { 63 | list-style: none; 64 | } 65 | 66 | .mdc-drawer { 67 | z-index: 10000; 68 | } 69 | 70 | .mdc-switch { 71 | margin-left: auto !important; 72 | } -------------------------------------------------------------------------------- /index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | Webradio 8 | 9 | 10 | 11 | 42 | 43 | 44 | 69 | 70 |
71 | 90 | 91 | 100 |
101 | 102 | 103 | 104 | 105 | 106 | -------------------------------------------------------------------------------- /index.js: -------------------------------------------------------------------------------- 1 | /* 2 | NOTE! 3 | 4 | THIS IS OLD SCRIPT, YOU DON'T FIND ANYTHING HERE 5 | LOOK AT app.js 6 | 7 | NOTE! 8 | */ 9 | 10 | // Your web app's Firebase configuration 11 | // For Firebase JS SDK v7.20.0 and later, measurementId is optional 12 | var firebaseConfig = { 13 | apiKey: "AIzaSyAs4WSvyBoODJIi2VgBwZDZTwhRiBm3-e4", 14 | authDomain: "webradio-3904f.firebaseapp.com", 15 | databaseURL: "https://webradio-3904f.firebaseio.com", 16 | projectId: "webradio-3904f", 17 | storageBucket: "webradio-3904f.appspot.com", 18 | messagingSenderId: "96382163337", 19 | appId: "1:96382163337:web:15c8acd210a462da4b6958", 20 | measurementId: "G-6B26PSM2BT" 21 | }; 22 | // Initialize Firebase 23 | firebase.initializeApp(firebaseConfig); 24 | firebase.analytics(); 25 | analytics = firebase.analytics() 26 | 27 | Storage.prototype.setObject = function(key, value) { 28 | this.setItem(key, JSON.stringify(value)); 29 | } 30 | 31 | Storage.prototype.getObject = function(key) { 32 | var value = this.getItem(key); 33 | return value && JSON.parse(value); 34 | } // Stackoverflow goes brrrr 35 | 36 | const searcher = document.querySelector('.searchInput') 37 | const searchSubmit = document.querySelector('.searchSubmit') 38 | 39 | const content = document.querySelector('.content') 40 | const description = document.querySelector('.pageDescription') 41 | const settings = document.querySelector('.pageSettings') 42 | const contributors = document.querySelector('.pageContributors') 43 | 44 | const settingsBtn = document.querySelector('.settings-button') 45 | const darkModeSwitcher = document.querySelector('#dark-mode-switch') 46 | const switchTop = document.querySelector('.switch-top') 47 | const closeBtn = document.querySelector('.close-button') 48 | const backBtn = document.querySelector('.back-button') 49 | 50 | const contributorsBtn = document.querySelector('.contributorsButton') 51 | const contributorList = document.querySelector('.contributorList') 52 | 53 | searchSubmit.addEventListener('click', () => { 54 | description.style.display = 'none' 55 | let searchQuery = searcher.value 56 | analytics.logEvent('search_radios', { query: searchQuery }) 57 | content.innerHTML = "" 58 | 59 | if(searchQuery === "" || searchQuery === "radio") { 60 | content.innerHTML = '

Ta fraza wyszukiwania spowoduje, że twój komputer się zatnie. Nie rób tak więcej, proszę.

' 61 | } else { 62 | if(searchQuery === "/benchmark") searchQuery = "" // easter-egg 63 | fetch(`https://de1.api.radio-browser.info/json/stations/byname/${searchQuery}`) 64 | .then(response => response.json()) 65 | .then(data => { 66 | data.forEach((elem) => { 67 | const stationUUID = elem.stationuuid 68 | const stationName = elem.name 69 | const stationCodec = elem.codec 70 | window.stationURL = elem.url_resolved 71 | const stationFavicon = elem.favicon 72 | const testAudioStream = new Audio(stationURL) 73 | 74 | const cardTemplate = document.createElement('div') 75 | cardTemplate.classList = 'mdc-card mdc-card-outlined' 76 | cardTemplate.innerHTML = `
Station Favicon
${stationName}` 77 | 78 | content.append(cardTemplate) 79 | }) 80 | 81 | const playButton = document.querySelectorAll('.controls-play'); 82 | const icon = document.querySelectorAll('.play') 83 | const audio = document.querySelectorAll('audio') 84 | 85 | playButton.forEach((button, i) => { 86 | button.addEventListener('click', () => { 87 | if (button.dataset.playing === 'false') { 88 | analytics.logEvent('start_playing_radio', { stationName: button.dataset.radioname }) 89 | audio[i].play(); 90 | button.dataset.playing = 'true' 91 | icon[i].classList = 'mdi mdi-pause pause' 92 | // if track is playing pause it 93 | } else if (button.dataset.playing === 'true') { 94 | analytics.logEvent('stop_playing_radio', { stationName: button.dataset.radioname }) 95 | audio[i].pause(); 96 | button.dataset.playing = 'false' 97 | icon[i].classList = 'mdi mdi-play play' 98 | } 99 | 100 | let state = button.getAttribute('aria-checked') === "true" ? true : false 101 | button.setAttribute( 'aria-checked', state ? "false" : "true" ); 102 | }) 103 | }) 104 | 105 | }) 106 | } 107 | }) 108 | 109 | settingsBtn.addEventListener('click', () => { 110 | content.innerHTML = '' 111 | if(settingsBtn.dataset.checked === 'true') { 112 | content.style.display = 'none' 113 | description.style.display = 'block' 114 | settings.style.display = 'none' 115 | settingsBtn.dataset.checked = 'false' 116 | } else if(settingsBtn.dataset.checked === 'false'){ 117 | content.style.display = 'none' 118 | description.style.display = 'none' 119 | settings.style.display = 'block' 120 | settingsBtn.dataset.checked = 'true' 121 | } 122 | }) 123 | 124 | darkModeSwitcher.addEventListener('click', () => { 125 | if(darkModeSwitcher.dataset.checked === 'false'){ 126 | darkModeSwitcher.checked = true 127 | switchTop.classList = 'mdc-switch mdc-switch--checked switch-top' 128 | darkModeSwitcher.dataset.checked = 'true' 129 | document.body.style.background = '#121212' 130 | document.body.style.color = '#fff' 131 | document.documentElement.style.setProperty('--mdc-theme-surface', '#121212') 132 | document.documentElement.style.setProperty('--mdc-theme-text-primary-on-background', '#fff') 133 | document.documentElement.style.setProperty('--mdc-theme-text-icon-on-background', '#fff') 134 | 135 | localStorage.setItem('settings', JSON.stringify({ 136 | 'iconColor': "#fff", 137 | 'primaryTextColor': "#fff", 138 | 'cssTextColor': "#fff", 139 | 'cssBackgroundColor': "#121212", 140 | 'surfaceColor': "#121212" 141 | })) 142 | 143 | } else if(darkModeSwitcher.dataset.checked === 'true') { 144 | darkModeSwitcher.checked = true 145 | switchTop.classList = 'mdc-switch switch-top' 146 | darkModeSwitcher.dataset.checked = 'false' 147 | document.body.style.background = '#fff' 148 | document.body.style.color = '#121212' 149 | document.documentElement.style.setProperty('--mdc-theme-surface', '#fff') 150 | document.documentElement.style.setProperty('--mdc-theme-text-primary-on-background', '#121212') 151 | document.documentElement.style.setProperty('--mdc-theme-text-icon-on-background', '#9f9f9f') 152 | 153 | localStorage.setItem('settings', JSON.stringify({ 154 | "iconColor": "#9f9f9f", 155 | "primaryTextColor": "#121212", 156 | "cssTextColor": "#121212", 157 | "cssBackgroundColor": "#fff", 158 | "surfaceColor": "#fff" 159 | })) 160 | } 161 | }) 162 | 163 | closeBtn.addEventListener('click', () => { 164 | description.style.display = 'block' 165 | settings.style.display = 'none' 166 | }) 167 | 168 | window.addEventListener('load', () => { 169 | window.settingsValues = JSON.parse(localStorage.getItem('settings')) 170 | 171 | if(settingsValues.cssBackgroundColor && settingsValues.cssTextColor && settingsValues.surfaceColor && settingsValues.primaryTextColor && settingsValues.iconColor) { 172 | document.body.style.background = settingsValues.cssBackgroundColor 173 | document.body.style.color = settingsValues.cssTextColor 174 | document.documentElement.style.setProperty('--mdc-theme-surface', settingsValues.surfaceColor) 175 | document.documentElement.style.setProperty('--mdc-theme-text-primary-on-background', settingsValues.primaryTextColor) 176 | document.documentElement.style.setProperty('--mdc-theme-text-icon-on-background', settingsValues.iconColor) 177 | if(settingsValues.cssBackgroundColor !== '#fff') { 178 | switchTop.classList = 'mdc-switch mdc-switch--checked switch-top' 179 | darkModeSwitcher.dataset.checked = 'true' 180 | 181 | } 182 | } else { 183 | localStorage.setItem('settings', { 184 | iconColor: '#9f9f9f', 185 | primaryTextColor: '#121212', 186 | cssTextColor: '#121212', 187 | cssBackgroundColor: '#fff', 188 | surfaceColor: '#fff' 189 | }) 190 | } 191 | }) 192 | 193 | contributorsBtn.addEventListener('click', () => { 194 | contributorList.innerHTML = '' 195 | content.style.display = 'none' 196 | description.style.display = 'none' 197 | settings.style.display = 'none' 198 | contributors.style.display = 'block' 199 | 200 | fetch('https://api.github.com/repos/web-radio/webradio/contributors') 201 | .then(response => response.json()) 202 | .then(data => { 203 | data.forEach(contributor => { 204 | if (contributor.login == 'MarcinK50' || contributor.login == 'Lambada10') { 205 | console.log('maintainer') 206 | } else { 207 | if (contributorList.childElementCount >= 0) { 208 | const listItem = document.createElement('li') 209 | listItem.classList = 'mdc-list-item' 210 | listItem.tabIndex = 0 211 | listItem.innerHTML = `${contributor.login} avatar${contributor.login}` 212 | 213 | contributorList.append(listItem) 214 | } 215 | } 216 | }) 217 | }) 218 | }) 219 | 220 | backBtn.addEventListener('click', () => { 221 | settings.style.display = 'block' 222 | contributors.style.display = 'none' 223 | }) 224 | /* 225 | let lang 226 | const searchButton = document.getElementById("searchbutton"); 227 | const content = document.querySelector('#content'); 228 | const note = document.getElementById("note") 229 | const searcher = document.getElementById("search"); 230 | const settingsIcon = document.getElementsByClassName('settingsIcon') 231 | 232 | const langCheckbox = document.querySelector("#langCheckbox") 233 | 234 | const subheader = document.querySelector("#subheader") 235 | const searchLabel = document.querySelector("#searchLabel") 236 | const langLabel = document.querySelector("#langLabel") 237 | const legacyInfo = document.querySelector("#legacyInfo") 238 | 239 | langCheckbox.addEventListener("click", () => { 240 | if (langCheckbox.checked) { 241 | fetch("https://raw.githubusercontent.com/web-radio/webradio/master/languages/polish.json") 242 | .then(response => response.json()) 243 | .then(data => { 244 | lang = data 245 | subheader.textContent = data.header 246 | searchLabel.textContent = data.searchText 247 | langLabel.textContent = data.langInfo 248 | legacyInfo.textContent = data.legacyInfo 249 | }) 250 | } else { 251 | fetch("https://raw.githubusercontent.com/web-radio/webradio/master/languages/english.json") 252 | .then(response => response.json()) 253 | .then(data => { 254 | lang = data 255 | subheader.textContent = data.header 256 | searchLabel.textContent = data.searchText 257 | langLabel.textContent = data.langInfo 258 | legacyInfo.textContent = data.legacyInfo 259 | }) 260 | } 261 | }) 262 | 263 | document.addEventListener("DOMContentLoaded", () => { 264 | fetch("https://raw.githubusercontent.com/web-radio/webradio/master/languages/polish.json") 265 | .then(response => response.json()) 266 | .then(data => { 267 | lang = data 268 | subheader.textContent = data.header 269 | searchLabel.textContent = data.searchText 270 | langLabel.textContent = data.langInfo 271 | legacyInfo.textContent = data.legacyInfo 272 | }) 273 | }) 274 | */ 275 | -------------------------------------------------------------------------------- /legacy/legacy.css: -------------------------------------------------------------------------------- 1 | @import url('https://fonts.googleapis.com/css2?family=Lato:wght@400&display=swap'); 2 | 3 | @media screen and (max-width: 800px) { 4 | #content { 5 | display: grid; 6 | grid-template-columns: 1fr !important; 7 | grid-template-rows: 1fr 1fr 1fr 1fr; 8 | gap: 0 0; 9 | } 10 | } 11 | 12 | body { 13 | background: -webkit-gradient(linear,left top,left bottom,from(rgba(0,0,0,.9)),to(rgba(0,0,0,.9))),url('https://raw.githubusercontent.com/web-radio/webradio/master/wallpaper.jpg'); 14 | background: linear-gradient(rgba(0,0,0,.9),rgba(0,0,0,.9)),url('https://raw.githubusercontent.com/web-radio/webradio/master/wallpaper.jpg'); 15 | background-size: cover; 16 | background-attachment: fixed; 17 | overflow: auto; 18 | -webkit-box-align: center; 19 | -ms-flex-align: center; 20 | align-items: center; 21 | -webkit-box-pack: center; 22 | -ms-flex-pack: center; 23 | justify-content: center; 24 | color: #efefef; 25 | font-family: 'Lato', sans-serif; 26 | text-align: center; 27 | font-size: 20px; 28 | margin-top: 10vh; 29 | } 30 | 31 | #content { 32 | display: grid; 33 | grid-template-columns: 1fr 1fr; 34 | grid-template-rows: 1fr 1fr 1fr 1fr; 35 | gap: 0 0; 36 | } 37 | 38 | #container { 39 | width: 90%; 40 | margin-left: auto; 41 | margin-right: auto; 42 | } 43 | 44 | #header { 45 | text-transform: uppercase; 46 | font-size: 24px; 47 | } 48 | 49 | .radioElementLast { 50 | margin-left: auto; 51 | margin-right: auto; 52 | } 53 | 54 | a { 55 | color: white; 56 | } 57 | 58 | #search { 59 | margin: 15px; 60 | padding: 5px; 61 | border-radius: 5px; 62 | border: none; 63 | } 64 | 65 | #searchbutton { 66 | border-radius: 5px; 67 | border: none; 68 | padding: 5px; 69 | } 70 | 71 | .radioElement { 72 | text-align: center; 73 | height: 30%; 74 | width: 100%; 75 | } 76 | 77 | #blue { 78 | color: blue; 79 | } 80 | 81 | #red { 82 | color: #d43f3f; 83 | } -------------------------------------------------------------------------------- /legacy/legacy.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | Webradio 6 | 7 | 8 | 9 |
10 | 13 |
14 |

Webradio - wszystkie radia internetowe w jednym miejscu. za darmo. 15 |

16 |
17 | 18 |
19 |
20 | 21 | -------------------------------------------------------------------------------- /legacy/legacy.js: -------------------------------------------------------------------------------- 1 | var req = new XMLHttpRequest(); 2 | req.open('GET', 'https://raw.githubusercontent.com/web-radio/webradio/master/radios.json', false); 3 | req.send(null); 4 | const radios = JSON.parse(req.response) 5 | 6 | const content = document.querySelector('#content'); 7 | 8 | radios.forEach((elem) => { 9 | if(elem.last) { 10 | content.innerHTML += `

${elem.name}

`; 11 | } else { 12 | content.innerHTML += `

${elem.name}

`; 13 | } 14 | }); -------------------------------------------------------------------------------- /radios.json: -------------------------------------------------------------------------------- 1 | [ 2 | { 3 | "name":"Jedynka", 4 | "src":"http://mp3.polskieradio.pl:8900/;", 5 | "type":"audio/mp3" 6 | }, 7 | { 8 | "name":"Dwójka", 9 | "src":"http://mp3.polskieradio.pl:8902/;", 10 | "type":"audio/mp3" 11 | }, 12 | { 13 | "name":"Trójka", 14 | "src":"http://mp3.polskieradio.pl:8904/;", 15 | "type":"audio/mp3" 16 | }, 17 | { 18 | "name":"Czwórka", 19 | "src":"http://mp3.polskieradio.pl:8906/;", 20 | "type":"audio/mp3" 21 | }, 22 | { 23 | "name":"RMF FM", 24 | "src":"http://195.150.20.242:8000/rmf_fm", 25 | "type":"audio/mp3" 26 | }, 27 | { 28 | "name":"Radio Maryja", 29 | "src":"http://radio.zamarproductions.com:5946/;", 30 | "type":"audio/mp3" 31 | }, 32 | { 33 | "name":"Radio ZET", 34 | "src":"http://zet090-02.cdn.eurozet.pl:8404/;", 35 | "type":"audio/mp3" 36 | }, 37 | { 38 | "name":"Radio Złote Przeboje", 39 | "src":"http://poznan7.radio.pionier.net.pl:8000/tuba9-1.mp3", 40 | "type":"audio/mp3" 41 | }, 42 | { 43 | "name":"Złote Przeboje Gdańsk", 44 | "src":"http://stream10.radioagora.pl/zp_gda_128.mp3", 45 | "type":"audio/mp3" 46 | }, 47 | { 48 | "name":"PR Poznań", 49 | "src":"http://stream4.nadaje.com:8578/poznan", 50 | "type":"audio/mp3" 51 | }, 52 | { 53 | "name":"PR Kraków", 54 | "src":"http://stream4.nadaje.com:9680/radiokrakow-s3", 55 | "type":"audio/mp3" 56 | }, 57 | { 58 | "name":"PR Katowice", 59 | "src":"http://stream4.nadaje.com:9212/radiokatowice", 60 | "type":"audio/mp3" 61 | }, 62 | { 63 | "name":"PR Opole", 64 | "src":"http://dab.radio.opole.pl:8035/1", 65 | "type":"audio/mp3" 66 | }, 67 | { 68 | "name":"Meloradio FM", 69 | "src":"http://mel.cdn.eurozet.pl/mel-ols.mp3", 70 | "type":"audio/mp3" 71 | }, 72 | { 73 | "name":"PR Zachód", 74 | "src":"http://stream02.zachod.pl:10113/;", 75 | "type":"audio/mp3" 76 | }, 77 | { 78 | "name":"Radio Tok FM", 79 | "src":"http://poznan5-4.radio.pionier.net.pl:8000/tuba10-1.mp3", 80 | "type":"audio/mp3" 81 | }, 82 | { 83 | "name":"PR Szczecin", 84 | "src":"http://stream4.nadaje.com:11986/prs.aac", 85 | "type":"audio/mp3" 86 | }, 87 | { 88 | "name":"PR Olsztyn", 89 | "src":"http://olsztyn.radio.pionier.net.pl:7055/;", 90 | "type":"audio/mp3" 91 | }, 92 | { 93 | "name":"PR Białystok", 94 | "src":"http://stream4.nadaje.com:15476/radiobialystok", 95 | "type":"audio/mp3" 96 | }, 97 | { 98 | "name":"PR Koszalin", 99 | "src":"http://s0.radiohost.pl:9680/;", 100 | "type":"audio/mp3" 101 | }, 102 | { 103 | "name":"PR Pomorza i Kujaw", 104 | "src":"http://stream.radiopik.pl:9004/;", 105 | "type":"audio/mp3" 106 | }, 107 | { 108 | "name":"PR Słupsk", 109 | "src":"http://s0.radiohost.pl:8240/;", 110 | "type":"audio/mp3" 111 | }, 112 | { 113 | "name":"Białoruskie Radio Racja", 114 | "src":"http://air.racyja.com:8000/racja256", 115 | "type":"audio/mp3" 116 | }, 117 | { 118 | "name":"RMF Classic", 119 | "src":"http://rmfstream1.interia.pl:8000/rmf_classic", 120 | "type":"audio/mp3" 121 | }, 122 | { 123 | "name":"Antyradio FM", 124 | "src":"http://ant-kat-01.cdn.eurozet.pl:8604/;", 125 | "type":"audio/mp3" 126 | }, 127 | { 128 | "name":"Radio Plus Gdańsk", 129 | "src":"http://plu-gdn-02.cdn.eurozet.pl:8304/;", 130 | "type":"audio/mp3" 131 | }, 132 | { 133 | "name":"VOX FM", 134 | "src":"http://85.219.133.18/radio.php?id=-1&url=http://www.eskago.pl/radio/vox-fm", 135 | "type":"audio/mp3" 136 | }, 137 | { 138 | "name":"Radio Rodzina", 139 | "src":"http://sluchaj.radiorodzina.pl/RadioRodzinaWroclawLIVE.mp3", 140 | "type":"audio/mp3" 141 | }, 142 | { 143 | "name":"Muzyczne Radio", 144 | "src":"http://stream.nadaje.com:9900/;", 145 | "type":"audio/mp3" 146 | }, 147 | { 148 | "name":"Radio RDN", 149 | "src":"http://rdn.pl:8002/;", 150 | "type":"audio/mp3" 151 | }, 152 | { 153 | "name":"Radio Plus Legnica", 154 | "src":"http://stream.plus.legnica.pl:8000/plusaacp", 155 | "type":"audio/mp3" 156 | }, 157 | { 158 | "name":"Radio eM", 159 | "src":"http://91.200.187.58/;", 160 | "type":"audio/mp3" 161 | }, 162 | { 163 | "name":"Radio Pogoda", 164 | "src":"http://stream13.radioagora.pl/tuba38-1.mp3", 165 | "type":"audio/mp3" 166 | }, 167 | { 168 | "name":"KRP Katolickie Radio Podlasie", 169 | "src":"http://s1.slotex.pl:7038/;", 170 | "type":"audio/mp3" 171 | }, 172 | { 173 | "name":"Radio Victoria", 174 | "src":"https://stream.v4.radiovictoria.pl:8076/;?type=http&nocache=4494", 175 | "type":"audio/mp3" 176 | }, 177 | { 178 | "name":"Muzo FM", 179 | "src":"http://stream4.nadaje.com/muzo", 180 | "type":"audio/mp3" 181 | }, 182 | { 183 | "name":"Rock Radio", 184 | "src":"http://stream13.radioagora.pl/tuba9004-1.mp3", 185 | "type":"audio/mp3" 186 | }, 187 | { 188 | "name":"Radio Doxa", 189 | "src":"http://81.210.92.213:8000/;", 190 | "type":"audio/mp3" 191 | }, 192 | { 193 | "name":"Radio Weekend", 194 | "src":"http://stream.weekendfm.pl:8000/weekendfm_najlepsza.aac", 195 | "type":"audio/mp3" 196 | }, 197 | { 198 | "name":"VIA - Katolickie Radio Rzeszów", 199 | "src":"http://62.133.128.18:8040/;", 200 | "type":"audio/mp3" 201 | }, 202 | { 203 | "name":"Radio Elka", 204 | "src":"http://live.elka.pl:8000/elkamp3", 205 | "type":"audio/mp3" 206 | }, 207 | { 208 | "name":"Radio Nadzieja", 209 | "src":"http://streaming01.technologicznie.net:8000/;", 210 | "type":"audio/mp3" 211 | }, 212 | { 213 | "name":"Radio Fiat", 214 | "src":"http://stream2.nadaje.com:8056/;", 215 | "type":"audio/mp3" 216 | }, 217 | { 218 | "name":"Radio CCM", 219 | "src":"http://primary.moodyradiostream.org/radioccm", 220 | "type":"audio/mp3" 221 | }, 222 | { 223 | "name":"Radio Emaus", 224 | "src":"http://stream.radioemaus.pl:8000/mp3stream", 225 | "type":"audio/mp3" 226 | }, 227 | { 228 | "name":"Radio Fara", 229 | "src":"http://62.133.128.22:8000/;", 230 | "type":"audio/mp3" 231 | }, 232 | { 233 | "name":"Radio Plus Gniezno", 234 | "src":"http://plu02.cdn.eurozet.pl:8308/plu-gnz.fb.mp3", 235 | "type":"audio/mp3" 236 | }, 237 | { 238 | "name":"Radio Plus Radom", 239 | "src":"http://78.46.170.230:8040/;", 240 | "type":"audio/mp3" 241 | }, 242 | { 243 | "name":"Radio Plus Warszawa", 244 | "src":"http://plu02.cdn.eurozet.pl:8318/plu-waw.mp3", 245 | "type":"audio/mp3" 246 | }, 247 | { 248 | "name":"Radio Leliwa", 249 | "src":"http://stream2.nadaje.com:8054/;", 250 | "type":"audio/mp3" 251 | }, 252 | { 253 | "name":"Chillzet FM", 254 | "src":"http://chi-net.cdn.eurozet.pl:8900/;", 255 | "type":"audio/mp3" 256 | }, 257 | { 258 | "name":"Radio Fama Kielce", 259 | "src":"http://stream2.nadaje.com:8076/", 260 | "type":"audio/mp3" 261 | }, 262 | { 263 | "name":"Radio Niepokalanów", 264 | "src":"http://88.199.169.10:8000/;", 265 | "type":"audio/mp3" 266 | }, 267 | { 268 | "name":"Radio Parada", 269 | "src":"http://stream4.nadaje.com:15274/live", 270 | "type":"audio/mp3" 271 | }, 272 | { 273 | "name":"Wasze Radio FM", 274 | "src":"http://stream1.waszeradiofm.pl:8000/stream", 275 | "type":"audio/mp3" 276 | }, 277 | { 278 | "name":"Radio Głos", 279 | "src":"http://87.204.92.180:8000/;", 280 | "type":"audio/mp3" 281 | }, 282 | { 283 | "name":"Krdp FM", 284 | "src":"http://s1.slotex.pl:7762/;", 285 | "type":"audio/mp3" 286 | }, 287 | { 288 | "name":"Radio 90 FM", 289 | "src":"http://streams.radio90.pl:8000/radio90_128kbps_stereo.mp3", 290 | "type":"audio/mp3" 291 | }, 292 | { 293 | "name":"Radio Bielsko", 294 | "src":"http://stream.nadaje.com:8044/", 295 | "type":"audio/mp3" 296 | }, 297 | { 298 | "name":"Radio Eska", 299 | "src":"http://waw02-03.ic.smcdn.pl:8000/t043-1.mp3", 300 | "type":"audio/mp3" 301 | }, 302 | { 303 | "name":"RMF MAXXX", 304 | "src":"http://195.150.20.242:8000/rmf_maxxx", 305 | "type":"audio/mp3" 306 | }, 307 | { 308 | "name":"ESKA Trójmiasto", 309 | "src":"http://waw02-03.ic.smcdn.pl:8000/t048-1.mp3", 310 | "type":"audio/mp3" 311 | }, 312 | { 313 | "name":"Radio Kaszebe", 314 | "src":"http://stream3.nadaje.com:8048/;", 315 | "type":"audio/mp3" 316 | }, 317 | { 318 | "name":"Dark Radio", 319 | "src":"http://dark.sh/mp3", 320 | "type":"audio/mp3", 321 | "last":true 322 | }, 323 | { 324 | "name":"Radio Nowy Świat", 325 | "src":"http://stream.rcs.revma.com/ypqt40u0x1zuv", 326 | "type":"audio/mp3" 327 | } 328 | ] 329 | --------------------------------------------------------------------------------