Somewhere in here there is an error, I can't figure it out. The error is: Parse error: parse error, expecting `T_VARIABLE' or `'$'' in /home/valcoweb/public_html/scriptsforyou/stats/powerlog.php3 on line 491;. Line 491 is $1024 = get...
PHP Code:// screen colors
if($action == "colors") {
function get_colors($col) {
global $dbsql;
$sql = "SELECT count(sr) as cnt FROM $dbsql WHERE sr LIKE '%$col%'";
$result = mysql_query ($sql);
while ($row = mysql_fetch_array($result)) {
$os1 = $row["cnt"];
return $os1;
}
}
$1024 = get_colors("1024x768");
$800 = get_colors("800x600");
$1152 = get_colors("1152x864");
$1280 = get_colors("1280x1024");
$848 = get_colors("848x480");
$640 = get_colors("640x480");
$total = ($1024 + $800 + $1152 + $1280 + $848 + $640);
function calculateper($number) {
global $total;
$percent = round((100 * $number / $total), 1);
return $percent;
}
$1024per = calculateper($1024);
$800per = calculateper($800);
$1152per = calculateper($1152);
$1280per = calculateper($1280);
$848per = calculateper($848);
$640per = calculateper($640);
?>




Bookmarks