kernel/private/modules/oauth/authorize.php
File containing the oauth/authorize view definition
- Copyright
- Copyright (C) 1999-2011 eZ Systems AS. All rights reserved.
- License
- eZ Business Use License Agreement Version 2.0
- Package
- oauth
- $_GET[client_id]
- string
the client application identifier, as in ezpRestClient
- $_GET[redirect_uri]
- string
the URI the view should redirect to in case of success
- $_GET[response_type]
- string
the requested response type. Can be code_and_token, code, or token
- $_GET[scope]
- string
the permissions scope the client requests (optional)
- $_GET[state]
- string
Not implemented yet (optional)
- Version
- 4.6.0
Functions

error(
string $redirectUri, string $errorCode, string $message
=
null
)
:
void
oAuth error handler function. Terminates execution after redirecting.
Name | Type | Description |
---|---|---|
$redirectUri | string | The URI the error should be sent to |
$errorCode | string | The error code, as defined in section 3.2.1 |
$message | string | A human readable error message explaining the error |

getHTTPVariable(
string $variable
)
:
mixed
Helper function that reads an HTTP variable over GET or POST, depending on the stage.
The POST variables AuthorizeButton and DenyButton will make the function read from POST
Name | Type | Description |
---|---|---|
$variable | string |
Type | Description |
---|---|
mixed | The parameter, or false if not set |

response(
string $httpHeader, string $location
=
null
)
:
void
oAuth2 response handler function. Terminates execution after sending the headers.
Name | Type | Description |
---|---|---|
$httpHeader | string | The HTTP header to be sent as a response |
$location | string | The location to redirect to. No redirection is done if not provided. |