newcoder1010 Posted January 2, 2023 Share Posted January 2, 2023 (edited) Hello, <!DOCTYPE html> <html> <head> <meta name="viewport" content="width=device-width, initial-scale=1"> <style> img { border-radius: 50%; } </style> </head> <body> <h2>Rounded Images</h2> <img src="/sites/default/files/2022-12/bg-house.png" alt="Avatar" style="width:200px"> </body> </html> Original image https://ibb.co/zH7HXfg Round image after styling. It looks oval shape. https://ibb.co/YpSBKw5 How can I round the image like this one in below? https://www.w3schools.com/howto/tryit.asp?filename=tryhow_css_rounded_images Edited January 2, 2023 by newcoder1010 Link to comment Share on other sites More sharing options...
Ingolme Posted January 2, 2023 Share Posted January 2, 2023 The image file needs to have been square to begin with. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now