What do you want to save?
Add Code snippet
New code examples
-
Javascript 2021-09-24 14:13:06
inject javascript to webpage
$.ajax({ url: `chrome-extension://${chrome.runtime.id}/index.html`, success: function(data){ //Simple note: the injected id is there so if you wanted to remove the injection you could do that :D document.getElementsByTagName('body... Add solution -
Html 2021-09-24 05:15:02
html ecommerece search box
<div class="row"> <div class="left" style="background-color:transparent;"> <h3 style="text-align: center;">Plants</h3> <input type="text" id="mySearch" ... Add solution -
Javascript 2021-09-23 21:17:04
DocumentFragment
var list = document.querySelector('#list') var fruits = ['Apple', 'Orange', 'Banana', 'Melon'] var fragment = new DocumentFragment() fruits.forEach(function (fruit) { var li = document.createElement('li') li.innerHTML = fruit fragment.appendChild(... Add solution -
Javascript 2021-09-23 15:37:04
tip in js
document.querySelector('#tip-form').onchange = function(){ var bill = Number(document.getElementById('billTotal').value); var tip = document.getElementById('tipInput').value; document.getElementById('tipOutput').innerHTML = `${tip}%`; var tipValu... Add solution -
Javascript 2021-09-21 17:01:02
with javascript, can html markup be added in a text string?
const text = 'This is a test to see whether nested style spans work properly.' const styling = [ {start: 22, end: 54, type: "strong"}, {start: 30, end: 36, type: "a"}, {start: 37, end: 48, type: "em"}, {start: 43, end... Add solution