Jump to content


image resizable to screen configuration


5 replies to this topic

#1 Jay.

    Young Padawan

  • Members
  • Pip
  • 70 posts
  • Gender:Male
  • Location:Latinoamérica yeah!!!

Posted 12 March 2008 - 02:28 PM

ello out there, I really dunno much bout html codes I'm more a flash designer but I have a problem on a job I get assigned, the site supposed to have a background image but the image its just on both sides of the screen, nothing in the middle, and I was wondering if someone here can help me out to achieve that, www.myspace.com/candida_albicans I try to make the image on the left side to be the same in the right side, I try to insert 2 links from a free image host but it only shows one, then I try to make an only image but on a screen configuration of 1280 it shows on the original size of the image wich is 1024, so what I need help with is in the code to make that image resizable to any screen configuration without any pixel distortion, hope someone can help with this I'll be more than happy.
Peace.
the link below is the example of what I'm trying to make
http://www.myspace.c...nchofredemption




Edited by iceball, 12 March 2008 - 02:55 PM.


#2 PaintingBlack

    Young Padawan

  • Members
  • Pip
  • 56 posts
  • Gender:Male
  • Location:Winnipeg, MB

Posted 12 March 2008 - 05:18 PM

Unfortunately you can't use 2 background images at the moment in CSS2, but there is a way to fix your problem, if I understand correctly. In your CSS file you're going to want to add this. Keep in mind that the image you use will only fill up the size of itself, and nothing more.

body {
	background:url('images/YOUR_IMAGE_NAME.gif') top center fixed no-repeat; /* Replace YOUR_IMAGE_NAME.gif with your images name... */
}

Then have your content center aligned so that it overlaps the background.

#content {
	margin:0 auto;
}

Hope that helps.

(PS. If you want your image to scale with the page width this will not work. There are plenty of tutorials on how to do that, just google "Scalable Background")

#3 Jay.

    Young Padawan

  • Members
  • Pip
  • 70 posts
  • Gender:Male
  • Location:Latinoamérica yeah!!!

Posted 13 March 2008 - 01:18 AM

ok, it's done, but one more favour, colud someone tell me plz if this background image stay in it's position in a higher configuration? I'm using 1024x768. thanks for the help.
peace out! :P

#4 PaintingBlack

    Young Padawan

  • Members
  • Pip
  • 56 posts
  • Gender:Male
  • Location:Winnipeg, MB

Posted 13 March 2008 - 04:38 PM

View Posticeball, on Mar 13 2008, 01:18 AM, said:

ok, it's done, but one more favour, colud someone tell me plz if this background image stay in it's position in a higher configuration? I'm using 1024x768. thanks for the help.
peace out! :P

Yes, yes it does. That's what the "top" in the body's background element is for.

#5 Jay.

    Young Padawan

  • Members
  • Pip
  • 70 posts
  • Gender:Male
  • Location:Latinoamérica yeah!!!

Posted 13 March 2008 - 06:02 PM

aum... ok now that's done but i need help in something else, i want to put a banner above the main nav bar, like the one in the myspace of deicide, they have an image above everything, i try the <head> tag but does not work, is there a way to do that, if you see the last link of my first post you'll see what i want to do.

www.myspace.com/thestenchofredemption

ty for the help.
peace!

Edited by iceball, 13 March 2008 - 06:03 PM.


#6 PaintingBlack

    Young Padawan

  • Members
  • Pip
  • 56 posts
  • Gender:Male
  • Location:Winnipeg, MB

Posted 13 March 2008 - 09:40 PM

In your content area, add the image you'd like to be their via the img tag.

<img src="images/YOUR_IMAGE_HERE.gif" alt="" />






1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users