PHP changing background collor

ArditA

New member
Joined
May 17, 2010
Messages
4
Hallo I've been looking on the net and found a lot of examples but nothing dit work.

I'm making a site with more frames. In one of the frames an PHP file is loaded (a form to fil in data wich is then send by mail with the submit button.) Now I want to change the background collor to mach the other frames or even load o pickture as background.

From what I could find so far I need to use a CSS file, but I don't know how that works and using the examples I couldn't get it working can someone help me??
 
This thread is really not ontopic for the DirectAdmin forums, because it has nothing to do with DirectAdmin server management. It's been moved, as it's an off-topic discussion.

Jeff
 
eg

body
{
background-color:yellow;
}

h1
{
background-color:#00ff00;
}

p
{
background-color:rgb(255,0,255);
}

That what you mean?
 
What Peter suggested - you can put either in a separate file (name it "style.css" for example) ... then you will need to call the CSS file by adding a line inside your <HEAD> tag of your HTML page - like:

<link rel="stylesheet" href="style.css" type="text/css" media="screen">

- or you can put the code inside the HTML script - you can have something like:

<html>
<head>
<title>My Page</title>
<style type="text/css">
body
{
background-color:yellow;
}

h1
{
background-color:#00ff00;
}

p
{
background-color:rgb(255,0,255);
}
</style>
</head>
<body>

The first method is better - as you can re-use the same piece of code, and you only have to edit one file if you decide to make changes.
 
Back
Top