Hello all,
my problem is that the stylesheet for my website is saved in my database, and I want to update the following stylesheet:
body {background-color:#252341;
scrollbar-face-color: #CBCBCB;
scrollbar-shadow-color: #AFAFAF;
scrollbar-highlight-color: #AFAFAF;
scrollbar-3dlight-color: #AFAFAF;
scrollbar-darkshadow-color: #000000;
scrollbar-track-color: #262342;
scrollbar-arrow-color: #3333ff;}
a:link {color:#0000FF; text-decoration:none}
a:active {color:#4684BD; text-decoration:none}
a:visited {color:#0000FF; text-decoration:none}
a:hover {color:#4684BD; text-decoration: none}
.text {color:#000000; font-size:12px}
.td {background-color:#dddddd}
input {font-family: Arial,
font-size: 12px;
color: #5F5F5F;
background-color: #DFDFDF;
border-top-width : 1px;
border-right-width : 1px;
border-bottom-width : 1px;
border-left-width : 1px;
text-indent : 0px;}
and I want to update it by the following function:
function update($tabel, $action, $connect) {
$sql = "update $tabel SET $action where $id=1";
$result = mysql_db_query($db,$sql,$connect)
or die("Couldn't execute query.");
return $result;
}
I call this function by the following line:
$update = update("ppn_design","design_name=$design_name,stylesheet=$stylesheet","$connect");
but all I get is the output:
Couldn't execute query.
I got no clue where the problem is, maybe it has something to do with the , and ; and " in the $stylesheet, but I'm not sure..
please help me.