2021년 8월 2일 월요일

9 HTML Features

 1. The <optgroup> element

 2. The <base> element

 3. The <del> and <ins> elements

 4. The <wbr> element

 5. The <fieldset> element

 6. Opening the Device Camera

Did you know that you can use HTML to access a user’s device camera? By using the attribute, you can open either the front or back camera of a mobile device to capture images. Simply add the attribute to the file input element and specify either "user" for the front camera or "environment" for the back camera.

<input type="file" capture="user" accept="image/*">
<input type="file" capture="environment" accept="video/*" />

 7. Spellcheck Activation

<input type="text" spellcheck="true" lang="en">

8. Preventing Translation

<p translate="no">Brand name</p>

9. Customizing Form Validation Messages

<input type="text" required oninvalid="this.setCustomValidity('Please enter a valid value.')">

10. Responsive Images with srcset

<img srcset="image.jpg 1x, image@2x.jpg 2x, image@3x.jpg3x" src="image.jpg" alt="Responsive Image">









댓글 없음:

댓글 쓰기