Archived topic
Container in % instead of px
3 replies · Started by Jon on May 30, 2020
Is it possible to make the width of the container in % instead of set px? The reason I ask is I have the container set at 1000 px wide. that is what fills up my 24" monitor. When a friend views it, it is only about 3/4 of her screen. She is not tech savvy so when I ask her what size monitor she has and what screen resolution, well she is a blonde! lol
Anyway, I got to thinking if there was a way to set it to percentages for the main and side containers that my solve the problem.
Would that even work?
Hi there,
You could try this:
body .grid-container {
max-width: 70%;
}
Let me know if this helps :)
Thank you Leo. Did you by chance look at the website? Is it askew and does not have a full screen? From every device I look from it looks ok to me.
Jon
Instead of using a percentage, I would just increase your container width to something much higher like 2000px.
That way if someone has a super big screen, your website will top out at 2000px (you don't want it to be much wider). For people with smaller monitors, it will be 100% of their screen width.