DOM Controls that do things

From ProgZoo
Revision as of 00:32, 30 August 2021 by Andr3w (talk | contribs) (Created page with "<pre id='shellbody' data-qtp='fetch'></pre> <div class=qu> <pre class=usr> let b = document.createElement('button'); b.innerText = 'click me'; b.onclick = ()=>{ document.bod...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

let b = document.createElement('button');
b.innerText = 'click me';
b.onclick = ()=>{
  document.body.append('Ho=ello world');
}
let b = document.createElement('button');
b.innerText = 'click me';
b.onclick = ()=>{
  document.body.append('Ho=ello world');
}