INNER CODE UNIT · JavaScript

strip_http

increpare/flickgame · flickgame_base.js:20

function strip_http(url) {
   url = url.replace(/^https?:\/\//,'');
   return url;
}

// Helper function to qualify URLs
function qualifyURL(url) {
    var aurl = document.createElement('a');
    aurl.href = url;
    return aurl.href;
}

// Color math utilities

function hexToRgb(hex) {
    var result = /^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(hex);
    return result
      ? { r: parseInt(result[1], 16), g: parseInt(result[2], 16), b: parseInt(result[3], 16) }

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…