You are here

protected function OAuthStorePostgreSQL::query_row_assoc in Lingotek Translation 7.6

Same name and namespace in other branches
  1. 7.7 lib/oauth-php/library/store/OAuthStorePostgreSQL.php \OAuthStorePostgreSQL::query_row_assoc()
  2. 7.2 lib/oauth-php/library/store/OAuthStorePostgreSQL.php \OAuthStorePostgreSQL::query_row_assoc()
  3. 7.3 lib/oauth-php/library/store/OAuthStorePostgreSQL.php \OAuthStorePostgreSQL::query_row_assoc()
  4. 7.4 lib/oauth-php/library/store/OAuthStorePostgreSQL.php \OAuthStorePostgreSQL::query_row_assoc()
  5. 7.5 lib/oauth-php/library/store/OAuthStorePostgreSQL.php \OAuthStorePostgreSQL::query_row_assoc()

Perform a query, return the first row

Parameters

string sql:

vararg arguments (for sprintf):

Return value

array

9 calls to OAuthStorePostgreSQL::query_row_assoc()
OAuthStorePostgreSQL::getConsumer in lib/oauth-php/library/store/OAuthStorePostgreSQL.php
Fetch a consumer of this server, by consumer_key.
OAuthStorePostgreSQL::getConsumerAccessToken in lib/oauth-php/library/store/OAuthStorePostgreSQL.php
Fetch the consumer access token, by access token.
OAuthStorePostgreSQL::getConsumerRequestToken in lib/oauth-php/library/store/OAuthStorePostgreSQL.php
Fetch the consumer request token, by request token.
OAuthStorePostgreSQL::getSecretsForSignature in lib/oauth-php/library/store/OAuthStorePostgreSQL.php
Find the server details for signing a request, always looks for an access token. The returned credentials depend on which local user is making the request.
OAuthStorePostgreSQL::getSecretsForVerify in lib/oauth-php/library/store/OAuthStorePostgreSQL.php
Find stored credentials for the consumer key and token. Used by an OAuth server when verifying an OAuth request.

... See full list

File

lib/oauth-php/library/store/OAuthStorePostgreSQL.php, line 1804

Class

OAuthStorePostgreSQL

Code

protected function query_row_assoc($sql) {
  $sql = $this
    ->sql_printf(func_get_args());
  if (!($res = pg_query($this->conn, $sql))) {
    $this
      ->sql_errcheck($sql);
  }
  if ($row = pg_fetch_assoc($res)) {
    $rs = $row;
  }
  else {
    $rs = false;
  }
  pg_free_result($res);
  return $rs;
}