Jump to content


Photo

background image


  • Please log in to reply
2 replies to this topic

#1 gidiag

gidiag
  • New Members
  • Pip
  • Newbie
  • 6 posts

Posted 27 February 2006 - 02:20 PM

hello everyone, my question is ----- i have got an image i want to insert as the background of a page how do i go about it?i tried background ="splash.jpg" it did nt work any ideas pls?



#2 obsidian

obsidian
  • Staff Alumni
  • Advanced Member
  • 3,202 posts
  • LocationSeattle, WA

Posted 27 February 2006 - 02:39 PM

[!--quoteo(post=349827:date=Feb 27 2006, 09:20 AM:name=gidiag)--][div class=\'quotetop\']QUOTE(gidiag @ Feb 27 2006, 09:20 AM) View Post[/div][div class=\'quotemain\'][!--quotec--]
hello everyone, my question is ----- i have got an image i want to insert as the background of a page how do i go about it?i tried background ="splash.jpg" it did nt work any ideas pls?
[/quote]

CSS is the answer, my friend! if you want it to be centered in the middle of the page stationary, so it doesn't scroll when the content does, you simply have to add this right before your </head> tag:
<style type='text/css'>
<!--
body {
  background: url('splash.jpg') no-repeat 50% 50% fixed;
}
-->
</style>

You can't win, you can't lose, you can't break even... you can't even get out of the game.

<?php
while (count($life->getQuestions()) > 0)
{   $life->study(); } ?>
  LINKS: PHP: Manual MySQL: Manual PostgreSQL: Manual (X)HTML: Validate It! CSS: A List Apart | IE bug fixes | Zen Garden | Validate It! JavaScript: Reference Cards RegEx: Everything RegEx

#3 HoTDaWg

HoTDaWg
  • Members
  • PipPipPip
  • Advanced Member
  • 275 posts
  • LocationToronto

Posted 27 February 2006 - 05:56 PM

u can simply make the background through Html:

<html>
<head>
<title>Sample yo</title>
</head>
<body background="images/yourimage.gif">
asdeasdas
</body>
</html>

hope this helps!

hotdawg

Handy links:
Google
PHP Manual





0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users