Project

General

Profile

Bug #23424 ยป 15527.diff

Administrator Admin, 2010-08-22 22:02

View differences:

t3lib/db/class.t3lib_db_preparedstatement.php
throw new InvalidArgumentException('$value is not a boolean as expected: ' . $value, 1281868687);
}
break;
case self::PARAM_NULL:
if (!is_null($value)) {
throw new InvalidArgumentException('$value is not NULL as expected: ' . $value, 1281868687);
}
break;
}
$key = is_int($parameter) ? $parameter - 1 : $parameter;
......
if (count($input_parameters) > 0) {
$parameterValues = array();
foreach ($input_parameters as $value) {
$parameterValues[] = array(
foreach ($input_parameters as $key => $value) {
$parameterValues[$key] = array(
'value' => $value,
'type' => $this->guessValueType($value),
);
......
$query = implode('', $parts);
}
} else {
if (!preg_match('/^:[\w]+$/', $key)) {
throw new InvalidArgumentException('Parameter names must start with ":" followed by at least one alphanumerical character.', 1282348825);
}
for ($i = 1; $i < count($precompiledQueryParts['queryParts']); $i++) {
if ($precompiledQueryParts['queryParts'][$i] === $key) {
$precompiledQueryParts['queryParts'][$i] = $value;
    (1-1/1)