web

web

April 17, 2020

Align div to the bottom of the page in 3 steps

Aligning an element at the bottom of the page is a very common issue in web development and css. You will find the best practices for aligning the div at the bottom of the page. Step 1 : Setting the parent position to relative. If you want to align a div at the bottom of a parent div, the parent should have a position : relative. <style> .parent { position: relative; /* Set parent position to relative */ } </style> <div class="parent"> <div class="bottom"></div> </div> Step 2 : Setting the div position to absolute.

April 16, 2020

Srcset Tutorial : Responsive Image HTML

Responsive images are images that adapt to the width of screen to fit it perfectly and to improve the performance of the site. If you like this post feel free to share it with your colleagues. Why reponsive images? I’m pretty sure that, until now, all the images you have inserted in your websites looks like this: <img src="imageURL" width="360px" height="auto" max-width="100vw" /> Let’s say the image has 1024px width : 768px height.