Anyone Good With HTML or CSS?

Status
Not open for further replies.

CookieMonstah

Est. Contributor
Messages
1,622
Role
  1. Adult Baby
  2. Diaper Lover
  3. Little
Literally been at this for hours but here is my problem:

I made my background image so big it will be viewable on 4k monitors but I want it to auto resize so it can be viewed on my monitor for example which is 1080p (1920x1080).

I have messed around with tons of settings and either got the half of it on my monitor or it is placed in the centre and a bit to the left has been cut off and a bit to the right has been cut off.

Can anyone help me?
 
It's background-size property you're looking for. If you set it to 'cover' it should do the trick. Here's an example:
https://jsfiddle.net/pmo80poq/
 
Could you possible give an example Or post the code you are using.

How are you scaling the background. Is it given a set dimension or are you using percentage in css?
 
LightYoshi said:
Could you possible give an example Or post the code you are using.

How are you scaling the background. Is it given a set dimension or are you using percentage in css?

f4cf889a4bcbb2894994eba6f359f351.png

There is my code, I have tried doing all sorts, cover, contain, width and height percentages or px, tried center center, I've tried margins and padding (pardon the pun :)), tried making it fixed or adding a scroll attachment to it, tried a lot. All I want is that the 4k image will resize itself so people without 4k monitors can view the whole thing and for it the show on the whole page, top to bottom, left to right.
 
Also I have another problem, this time with php, here is some code: f01046ff9819b0eeff35d826af4effe3.jpg

I have a login bit at the top of my page, when the person is logged in I want that to disappear and have it say "Welcome (username)" with a logout button. What do I have to change for it to work? Would be really awesome for you guys to help me!
 
Are you using a session token? It might not be able to track the login state without that.
 
Amcon said:
Are you using a session token? It might not be able to track the login state without that.

I've tried using the session token but I can't get it to work. It's kind of confusing, all this is new to me.
 
Status
Not open for further replies.
Back
Top