diff --git a/htdocs/admin/users/quota.json.php b/htdocs/admin/users/quota.json.php index 0a3e9958ef059c9417a8c3986af0472eef648740..06928f28dc7ac94ba82b1b58a049dc8e3f86ba05 100644 --- a/htdocs/admin/users/quota.json.php +++ b/htdocs/admin/users/quota.json.php @@ -21,7 +21,7 @@ $instid = param_integer('instid'); $disabled = param_boolean('disabled', false); $definst = get_field('auth_instance', 'id', 'institution', 'mahara'); -$record = get_record_sql('SELECT i.name, i.defaultquota FROM {institution} i JOIN {auth_instance} ai ON (i.name = ai.institution) WHERE ai.id = ?', $instid); +$record = get_record_sql('SELECT i.name, i.defaultquota FROM {institution} i JOIN {auth_instance} ai ON (i.name = ai.institution) WHERE ai.id = ?', array($instid)); if (!$USER->get('admin') && !$USER->is_institutional_admin($record->name)) { json_reply(true, 'You are not an administrator for institution '.$record->name); diff --git a/htdocs/api/xmlrpc/lib.php b/htdocs/api/xmlrpc/lib.php index 971f9c3dc1055a5268b88ef78ce075a9f899b4e7..4836be384489867977b8d2ddd741c60b2818933f 100644 --- a/htdocs/api/xmlrpc/lib.php +++ b/htdocs/api/xmlrpc/lib.php @@ -869,7 +869,7 @@ function get_service_providers($instance) { a.name = h.appname"; try { - $results = get_records_sql_assoc($query, array('value' => $instance)); + $results = get_records_sql_assoc($query, array($instance)); } catch (SQLException $e) { // Table doesn't exist yet return array(); diff --git a/htdocs/auth/user.php b/htdocs/auth/user.php index d3924cb39b07e6189198badc2156f4c03054df3b..3a491814602bb1934e50164f501ed0333896041e 100644 --- a/htdocs/auth/user.php +++ b/htdocs/auth/user.php @@ -147,7 +147,7 @@ class User { WHERE username = ?'; - $user = get_record_sql($sql, $username); + $user = get_record_sql($sql, array($username)); if (false == $user) { throw new AuthUnknownUserException("User with username \"$username\" is not known"); diff --git a/htdocs/interaction/forum/deletepost.php b/htdocs/interaction/forum/deletepost.php index b99ac2a3f80f916b1681ff82d7cefe4c10cab089..1187bddfb5f3e0e61dce41cf4acbfad209189e40 100644 --- a/htdocs/interaction/forum/deletepost.php +++ b/htdocs/interaction/forum/deletepost.php @@ -99,7 +99,7 @@ function deletepost_submit(Pieform $form, $values) { ON (o.objecttype = 'forum' AND o.objectid = fp.id) WHERE fp.id = ? AND o.resolvedby IS NULL - AND o.resolvedtime IS NULL", $values['post']); + AND o.resolvedtime IS NULL", array($values['post'])); if ($objectionable !== false) { // Trigger activity. diff --git a/htdocs/interaction/forum/deletetopic.php b/htdocs/interaction/forum/deletetopic.php index 7c0c862fe6a87a634170376d6c309da4239242f4..89651d6906b4d0e7bc03b5b26ef18c2a479debf8 100644 --- a/htdocs/interaction/forum/deletetopic.php +++ b/htdocs/interaction/forum/deletetopic.php @@ -91,7 +91,7 @@ function deletetopic_submit(Pieform $form, $values) { WHERE fp.topic = ? AND fp.parent IS NULL AND o.resolvedby IS NULL - AND o.resolvedtime IS NULL", $topicid); + AND o.resolvedtime IS NULL", array($topicid)); if ($objectionable !== false) { // Trigger activity.