If you see in the example I gave, I have 20 classes for possible values of height:
Code:
.h0 {height: 0px;}
.h5 {height: 50px;}
.h10 {height: 100px;}
.h15 {height: 150px;}
.h20 {height: 200px;}
.h25 {height: 250px;}
.h30 {height: 300px;}
.h35 {height: 350px;}
.h40 {height: 400px;}
.h45 {height: 450px;}
.h50 {height: 500px;}
.h55 {height: 550px;}
.h60 {height: 600px;}
.h65 {height: 650px;}
.h70 {height: 700px;}
.h75 {height: 750px;}
.h80 {height: 800px;}
.h85 {height: 850px;}
.h90 {height: 900px;}
.h95 {height: 950px;}
.h100 {height: 1000px}
That can be a lot easier to manage and work with, if you use a php for loop:
Code:
<?php
foreach (range(0,100,5) as $id)
{
echo (".h" . $id . " {height: " . 10*$id . "px;}\n");
}
?>
Or, you can send values around through the address of the .php stylesheet. I made a page with randomly a randomly generated color (
http://wsup.tk - under construction), and the reference to the css has the color in it. If the generated color is, say, #44dd88, the css reference would be:
Code:
<link rel="stylesheet" type="text/css" href="style.php?col=4d8">
And there are a whole other list of things you could posibly do. off the top of my head, you could probably send screen width values using javascript and the GET method.