473,382 Members | 1,380 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,382 software developers and data experts.

how do you make your background image automatically resize itself to fit any screen

MusoFreak200
hello

i am creating a website for both my school assignment and to really upload.

could someone help me with the following question, please?

how do you make your background image automatically resize itself to fit any screen without having extra scrollbars and having the image stay fixed and the words just move?

any help would be appreciated.

TY
MusoFreak200
Oct 20 '09 #1
9 6939
Dormilich
8,658 Expert Mod 8TB
@MusoFreak200
not at all (afaik), although you might use a repeating pattern or an image, that blends into background.

… and background images do not cause scrollbars.

alternatively, instead of using the CSS background, you can make a real image as a kind of background, although it may break the layout or provide other trouble.

@MusoFreak200
CSS backgrounds
Expand|Select|Wrap|Line Numbers
  1. background-position: fixed;
HTML Elements
Expand|Select|Wrap|Line Numbers
  1. position: fixed;
(not (partly?) implemented in IE)
Oct 20 '09 #2
thank you so much...

but i still am having trouble understanding... where exactly do i add the "background-position: fixed;" code?
Oct 20 '09 #3
Dormilich
8,658 Expert Mod 8TB
@MusoFreak200
to the CSS declaration of the element, that holds the background-image (theoretically you can add it everywhere, beside that’s making no sense at all)
Oct 20 '09 #4
i don't understand so do i add it in the body... or the head... or where?
Oct 20 '09 #5
Dormilich
8,658 Expert Mod 8TB
er, do you know how to apply a background in CSS?
Oct 20 '09 #6
no only html... sorry i still learning in class but my teacher didn't know how...

its for an assignment
Oct 20 '09 #7
Dormilich
8,658 Expert Mod 8TB
@MusoFreak200
eh?! what kind of teacher is that?
Oct 20 '09 #8
Dormilich
8,658 Expert Mod 8TB
@MusoFreak200
check out http://www.w3schools.com there are a lot of tutorials.
Oct 20 '09 #9
high school...

anyway back to the code...
Oct 20 '09 #10

Sign in to post your reply or Sign up for a free account.

Similar topics

2
by: Markus Mohr | last post by:
Hi, everyone, I have a special problem: For every monitor resolution in 200 pixel steps from 800 to 1600 pixels I have an image to be shown as centered background-image. Those images all...
8
by: Abs | last post by:
Hi! I have an image inside a DIV box with its dimensions specified. The problem is that I don't know the dimensions of the image beforehand, therefore the image grows outside the box if it's...
8
by: Matt | last post by:
I've been searching around for a simple way to display a background image in my MDI form's client area. I want to be able to load the image from file on start up and have it resize as the MDI form...
14
by: Seige | last post by:
Ever had headache when you can't resize the background width using CSS: body{ background: url(/images/bg.jpg) ; background-width: 800px; } It won't work, would it? Of course not, it's not even...
35
by: Friendly_Lola | last post by:
What Screen Resolution do You use? 800 X 600 1024 X 768 1280 X 1024 Wow! 1600 X 1200 (i can't imagine this) I use 1024 X 768. For what resolution you optimize your web pages?
2
by: Roger | last post by:
Hi, Can anybody help to fix the vertical centering of an image in Firefox (2.0)? Apparently, Firefox puts the top half of the image in the background of the top of the screen instead of placing...
6
by: ChrisAtWokingham | last post by:
I am creating a website using .Net v2.0 and c# and I have a problem with background images. I want to dynamically change the background image on the page, depending on data in the SQL database. ...
1
by: Bob Alston | last post by:
Anyone use the AHRESIZE utility to resize a form dynamically who is also using background images? I have an app that creates electronic versions of manual forms. I digitize the manual form and...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.