notes
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| notes [2025/10/03 07:02] – admin | notes [2025/10/08 09:59] (current) – admin | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| ==== Web Notes ==== | ==== Web Notes ==== | ||
| - | **Description**: | + | **Description**: |
| - | **Functions**: | + | **Functions**: |
| + | **Demo**: http:// | ||
| < | < | ||
| Line 9: | Line 9: | ||
| < | < | ||
| < | < | ||
| - | < | + | < |
| < | < | ||
| *: | *: | ||
| label{font-family: | label{font-family: | ||
| - | form{background-color:# | + | h2{font-family: |
| - | input[type=submit],input[type=reset]{cursor: | + | form{background-color:# |
| + | button{cursor: | ||
| + | input[type=submit]{cursor: | ||
| + | input[type=reset]{cursor: | ||
| + | .container{max-width: | ||
| </ | </ | ||
| - | |||
| - | <!-- Save file as function --> | ||
| - | <script language=" | ||
| - | function download(filename, | ||
| - | var pom = document.createElement(' | ||
| - | pom.setAttribute(' | ||
| - | pom.setAttribute(' | ||
| - | pom.style.display = ' | ||
| - | document.body.appendChild(pom); | ||
| - | pom.click(); | ||
| - | document.body.removeChild(pom); | ||
| - | } | ||
| - | </ | ||
| </ | </ | ||
| < | < | ||
| + | <div class=" | ||
| - | < | + | < |
| - | < | + | < |
| + | <input type=" | ||
| <form onsubmit=" | <form onsubmit=" | ||
| - | < | + | < |
| < | < | ||
| - | <input type=" | + | <button type=" |
| + | <input type=" | ||
| + | <input type="reset" | ||
| </ | </ | ||
| + | </ | ||
| <!-- Open existing file into editor function --> | <!-- Open existing file into editor function --> | ||
| - | < | + | < |
| var control = document.getElementById(" | var control = document.getElementById(" | ||
| control.addEventListener(" | control.addEventListener(" | ||
| - | var reader = new FileReader(); | + | var reader = new FileReader(); |
| reader.onload = function(event){ | reader.onload = function(event){ | ||
| var contents = event.target.result; | var contents = event.target.result; | ||
| - | document.getElementById(' | + | document.getElementById(' |
| }; | }; | ||
| reader.onerror = function(event){ | reader.onerror = function(event){ | ||
| Line 56: | Line 51: | ||
| reader.readAsText(control.files[0]); | reader.readAsText(control.files[0]); | ||
| }, false); | }, false); | ||
| + | </ | ||
| + | |||
| + | <!-- Save file as function --> | ||
| + | <script language=" | ||
| + | function download(filename, | ||
| + | var pom = document.createElement(' | ||
| + | pom.setAttribute(' | ||
| + | pom.setAttribute(' | ||
| + | pom.style.display = ' | ||
| + | document.body.appendChild(pom); | ||
| + | pom.click(); | ||
| + | document.body.removeChild(pom); | ||
| + | } | ||
| + | </ | ||
| + | |||
| + | <!-- Copy all text in editor area --> | ||
| + | <script language=" | ||
| + | document.querySelector(" | ||
| + | document.querySelector(" | ||
| + | document.execCommand(' | ||
| + | } | ||
| </ | </ | ||
| </ | </ | ||
| </ | </ | ||
| + | |||
| </ | </ | ||
notes.1759474956.txt.gz · Last modified: by admin
