CSS Design Issue Advice

Dpinkston91

Baseband Member
Messages
31
Location
Arkansas City, KS
So when I do...

body {
background-color: black;
}

It stretches out on the left side of the page. There is absolutely no margin left.

I'm using...

div {
width: 1358px; (Because I want to style a box at only the top of the page)
}

Which stretches just far enough to the right side of the page not to require a scroll-bar, but it will not cover the white margin on the left-hand side of the page. Any suggestions?
 

Attachments

  • 2021-02-22 (1) (Edited).png
    2021-02-22 (1) (Edited).png
    176 KB · Views: 8
  • 2021-02-22 (2).png
    2021-02-22 (2).png
    110.8 KB · Views: 8
If you provide the address of this page, you can probably help.
At the moment, it is quite difficult to guess what exactly needs to be changed or added, because there are many possibilities.
But if you only want to change the background of one part of the web page, as in the first image, you certainly can't change the body background color, because this command changes the whole web page background.
 
Open up your browser's Dev Tools (F12) and check to see if you have any inherited styles/classes adding that margin / padding.
 
Chrome inspection is a really useful tool, helps me a lot when I don't know how to fix certain things. And yeah, I'm not here to judge but honestly your website looks pretty bad. Have you tried to use other fonts and styles? I understand that this is just a portfolio and you don't want to waste time on it but still. It would be better if you used some other fonts for your webpage, it would attract people much more. I personally use the services of website designers newcastle nsw who frequently help me to make or edit my own websites.
 
Last edited:
Don't you happen to know that You can make exactly the design and layout that You like?
Then you don't have to force your taste on others.
Try it, it is good for You.
 
Chrome inspection is a really useful tool, helps me a lot when I don't know how to fix certain things. And yeah, I'm not here to judge but honestly your website looks pretty bad. Have you tried to use other fonts and styles? I understand that this is just a portfolio and you don't want to waste time on it but still. It would be better if you used some other fonts for your webpage, it would attract people much more. I personally use the services of website designers newcastle nsw who frequently help me to make or edit my own websites.
I believe OP is attempting to learn HTML/CSS/JS and this is the exercise he's chosen to give himself a goal.
 
I believe OP is attempting to learn HTML/CSS/JS and this is the exercise he's chosen to give himself a goal.
*Inserts Laughter*

I've actually changed up my entire page, and have added links on it.

Thank you for noticing that and saying something! Practical advice is always good, and opinions usually smell.
 
Chrome inspection is a really useful tool, helps me a lot when I don't know how to fix certain things. And yeah, I'm not here to judge but honestly your website looks pretty bad. Have you tried to use other fonts and styles? I understand that this is just a portfolio and you don't want to waste time on it but still. It would be better if you used some other fonts for your webpage, it would attract people much more. I personally use the services of website designers newcastle nsw who frequently help me to make or edit my own websites.
I feel like this was fairly constructive. Thank you for the advice.
 
Back
Top Bottom