HTML5 Examples For Beginners : Including Editable Contents And Local Storage
d. Including Editable contents
contenteditable attribute can be included to allow user to edit contents. There are many uses for this technique, such as allowing users to customize the way your pages appear to them each time they visit.
Browser Support:
- Internet Explorer 5.5+
- Firefox 3.5+
- Chrome 4.0+
- Safari 3.1+
Below is an example for editable To Do list
<!DOCTYPE
html> <html lang="en"> <head> <meta charset="utf-8"> <title>Editable Content Example</title> </head> <body> <h2> Thing To Do Today </h2> <ul contenteditable="true"> <li> Pay Electricity Bill </li> <li> Pick up laundry </li> <li> Visit dentist </li> </ul> </body> </html> |
Working example can be viewed here