Files
offline-octopus/examples/editor.html
2023-05-04 07:44:41 +02:00

6 lines
313 B
HTML

<html>
<textarea cols=60 rows=10></textarea>
<button onclick="fetch('/editor/save?content='+document.querySelector('textarea').value)">save</button>
<script>window.onload=_=>fetch('/editor/read').then( r => r.json() ).then( r => document.querySelector('textarea').value = r.msg)</script>
</html>