skibascott
IS-IT--Management
I am getting this error: Parse error: parse error in /export/home0/apache/htdocs/qalert.php(53) : eval()'d code on line 1
when running this code. I am assuming that it is referring to line 53, here is that block of code:
The research I have done on this error tells me that it some sort of syntax error. I am very new to php, so looking at this code with an untrained eye is not helping.
when running this code. I am assuming that it is referring to line 53, here is that block of code:
Code:
function array_csort() {
$args = func_get_args();
$marray = array_shift($args);
$msortline = "return(array_multisort)";
foreach ($args as $arg) {
$i++;
if (is_string($arg)) {
foreach ($marray as $row) {
$sortarr[$i][] = $row[$arg];
}
} else {
$sortarr[$i] = $arg;
}
$msortline .= "\$sortarr[".$i."],";
}
$msortline .= "\$marray));";
eval($msortline);
return $marray;
}
The research I have done on this error tells me that it some sort of syntax error. I am very new to php, so looking at this code with an untrained eye is not helping.