bindValue(':ip', $mask); $query->bindValue(':mod', $mod['id']); if ($reason !== '') $query->bindValue(':reason', $reason); else $query->bindValue(':reason', null, PDO::PARAM_NULL); if ($length > 0) $query->bindValue(':expires', time() + $length); else $query->bindValue(':expires', null, PDO::PARAM_NULL); if ($board) $query->bindValue(':board', $board); else $query->bindValue(':board', null, PDO::PARAM_NULL); $query->execute() or error(db_error($query)); }