HTML5 Web storage and its types 🚀
👇🧵
👇🧵
Please don't forget to read EXAMPLE for better understanding 🙏
★ HTML5 Web storage
• It's a way for websites to store information on your computer or device so they can remember certain things about you when you visit them again in the future.
• This is helpful because it can make it easier and faster to use websites you visit a lot.
• It's a way for websites to store information on your computer or device so they can remember certain things about you when you visit them again in the future.
• This is helpful because it can make it easier and faster to use websites you visit a lot.
• Before HTML5, application data had to be stored in cookies, included in every server request.
• Web storage is more secure, and large amounts of data can be stored locally, without affecting website performance.
• Web storage is more secure, and large amounts of data can be stored locally, without affecting website performance.
• Unlike cookies, the storage limit is far larger (at least 5MB) and information is never transferred to the server.
• Web storage is per origin (per domain and protocol). All pages, from one origin, can store and access the same data.
• Web storage is per origin (per domain and protocol). All pages, from one origin, can store and access the same data.
★ There are two types of HTML5 web storage:
1. local storage and
2. session storage
1. local storage and
2. session storage
★ Local storage
• Local storage is like a special folder on your computer or device that the website can use to store information about you.
• This information will stay there even if you close your web browser or turn off your computer.
• Local storage is like a special folder on your computer or device that the website can use to store information about you.
• This information will stay there even if you close your web browser or turn off your computer.
★ Session storage
• Session storage is like a temporary folder that the website can use to store information about you while you are visiting the website.
• This information will be deleted when you close your web browser or leave the website.
• Session storage is like a temporary folder that the website can use to store information about you while you are visiting the website.
• This information will be deleted when you close your web browser or leave the website.
★ Example
• let's say you visit a website that sells toys. You add a toy to your shopping cart, but you don't have time to finish your purchase.
• let's say you visit a website that sells toys. You add a toy to your shopping cart, but you don't have time to finish your purchase.
• If the website uses HTML5 web storage, it can store the information about the toy in your shopping cart in either local storage or session storage.
• If it uses local storage, the toy will still be in your shopping cart the next time you visit the website.
• If it uses local storage, the toy will still be in your shopping cart the next time you visit the website.
• If it uses session storage, the toy will be removed from your shopping cart when you close your web browser or leave the website.
End thread 🧵
End thread 🧵
If this thread helpful for you then :
1. Do Retweet the FIRST TWEET.
2. Follow me and turn on the notifications: @personalvipin
HTML
CSS
Javascript
Thank you ❤️
1. Do Retweet the FIRST TWEET.
2. Follow me and turn on the notifications: @personalvipin
HTML
CSS
Javascript
Thank you ❤️
جاري تحميل الاقتراحات...