https://github.com/web-platform-tests/wpt
Raw File
Tip revision: dc95d6e03b834edb8aef5b1c9f63187625197117 authored by Dong-hee Na on 10 October 2018, 08:14:18 UTC
Convert blocks.dat to html5lib_blocks.html
Tip revision: dc95d6e
form-data-set-usv-form.html
<!DOCTYPE html>
<meta charset="utf-8">
<title>This is the form that will be submitted</title>

<form action="form-echo.py" method="post" enctype="text/plain">
  <input id="input1" type="text">
  <select id="input2">
    <option selected>option
  </select>
  <input id="input3" type="radio" checked>
  <input id="input4" type="checkbox" checked>
</form>

<script>
"use strict";

const form = document.querySelector("form");

for (let el of Array.from(form.querySelectorAll("input"))) { // Firefox/Edge support
  el.name = el.id + "\uDC01";
  el.value = el.id + "\uDC01";
}

const select = document.querySelector("select");
select.name = select.id + "\uDC01";
select.firstElementChild.value = select.id + "\uDC01";
</script>
back to top