Cheers for the reply sofar!
At the mometn, I've just got individual tags, or options thereof stored, I'm having issues uploading whole files to the database, so as it stands the text that makes up the .css would be the easiest way probably......
Regards
Wibble
ok you need a new collom as type BLOB this holds binary information aka files. the easiest way to manage databases on a system is with phpmyadmin. if you don't have it i strongly suggest you get it, it is stable, secure, and totaly free.
now once you have this collom you can add entire files and then use mysql select statements to get these files.
now i do think there is a better way to solve this problem than with mysql. you could have a series of .css files like follows
css1.css
css2.css
css3.css
...
and just save these on your server like you regularly would. then use a php script to determine which one to put in... say you have someone select from a dropdown box which .css file they want. it would send a variable to the
trialscript.htm
-
<html>
-
<head>
-
<title>trial thing</title>
-
</head>
-
<body>
-
<form action="phpscript.php" method="post">
-
<select name="css_skin">
-
<option value="1">css1</option>
-
<option value="2">css2</option>
-
<option value="3">css3</option>
-
</select>
-
<input type="submit">
-
</form>
-
</body>
-
</html>
-
phpscript.php
[PHP]
<html>
<head>
<title>page with varying skins</title>
<?
$css=$_POST['css_skin'];
echo "<html tag for css target=", $css, "close the tag>";
?>
</head>
<body>
now this could be the same page that the form was on just for the form action print out <?= PHP_SELF ?>
and then just have that php code at the top of your page
</body>
</html>
[/PHP]
hope this helps
eric