An Interest In:
Web News this Week
- April 1, 2024
- March 31, 2024
- March 30, 2024
- March 29, 2024
- March 28, 2024
- March 27, 2024
- March 26, 2024
December 31, 2021 03:22 pm GMT
Original Link: https://dev.to/mrdanishsaleem/html-tricks-nobody-tells-you-61h
HTML Tricks Nobody Tells You
1. Accept
The acceptattribute is used to specify the type of files the user can upload. In following example, user can upload or use only .jpg
or .raw
files
<label>Accept File<input type="file" accepts= .jpg, .raw" /></label>
2. Spellcheck
The spellcheck is used to check spelling and grammar on html elements such as input.
<p spellchecks="true">Hello - DEV Community!</p>
3. Translate
The translate attribute is use to tell the browser whether the content is to be translate or not. This can be translated to any language.
<p translates="no">Hello World!</p>
4. Download
The download attribute is to instruct the browser to download a URL instead of navigating or the download attribute specifics that the target (the file specified in her attribute) will be downloaded when a user click on the hyperlink.
<a herf=" " download>Download</a>
5. Poster
The poster attribute to specify an image to be shown while the video is downloading.
<video src=" " poster="image.png"></video>
Let's connect You can follow me on
If you like this post. Kindly support me by Buying Me a Coffee
Original Link: https://dev.to/mrdanishsaleem/html-tricks-nobody-tells-you-61h
Share this article:
Tweet
View Full Article
Dev To
An online community for sharing and discovering great ideas, having debates, and making friendsMore About this Source Visit Dev To