protected function OAuthStoreMySQLi::query_row in Lingotek Translation 7.6
Same name and namespace in other branches
- 7.7 lib/oauth-php/library/store/OAuthStoreMySQLi.php \OAuthStoreMySQLi::query_row()
- 7.2 lib/oauth-php/library/store/OAuthStoreMySQLi.php \OAuthStoreMySQLi::query_row()
- 7.3 lib/oauth-php/library/store/OAuthStoreMySQLi.php \OAuthStoreMySQLi::query_row()
- 7.4 lib/oauth-php/library/store/OAuthStoreMySQLi.php \OAuthStoreMySQLi::query_row()
- 7.5 lib/oauth-php/library/store/OAuthStoreMySQLi.php \OAuthStoreMySQLi::query_row()
* Perform a query, return the first row * *
Parameters
string sql: * @param vararg arguments (for sprintf) * @return array
Overrides OAuthStoreMySQL::query_row
File
- lib/
oauth-php/ library/ store/ OAuthStoreMySQLi.php, line 189
Class
Code
protected function query_row($sql) {
$sql = $this
->sql_printf(func_get_args());
if (!($res = mysqli_query($this->conn, $sql))) {
$this
->sql_errcheck($sql);
}
if ($row = mysqli_fetch_array($res)) {
$rs = $row;
}
else {
$rs = false;
}
mysqli_free_result($res) || is_object($res) && get_class($res) == "mysqli_result" ? true : false;
return $rs;
}