Posted by: Cult_films
Posting time: 6.4 years ago on
Last edit time: never edited.
Archived on: 2/12/2017 1:51:00 AM
Views: 199
SCP: 5
5 upvotes, 0 downvotes (100% upvoted it)
~1 user(s) here now
NSFW: No
Authorized: No
Anon: No
Private: No
Type: Default
Sort: Top
[–] Nurdoidz 0 points 2 points 2 points (+2|-0) ago (edited ago)
You came to the right place!
It looks like you adopted some of my old code, so I know what the problem is. To prevent the links and posts from going to the other side of the screen and under the sidebar (which made it look odd), the margins have been altered. Here is the part of your code that's doing it:
To alleviate this when the screen is small, we need to add media queries. Here is the basic structure of a media query for screen size:
There are two values to be set here.
max-widthandmin-width. They both correspond to the screen size the page is being viewed on. Let's say you want to remove the sidebar and extend the links when the screen becomes smaller than 800 pixels. Here is how to do it:You can also have multiple media queries, too. Let's say we want the sidebar to be thinner when the screen width is less than 800 pixels, then hide it when the screen width is less than 600 pixels.
Good luck!
[–] Cult_films [S] 0 points 1 point 1 point (+1|-0) ago
Thank you!