Stud.IP
5.4
|
Public Member Functions | |
setAcceptURL ($url, array $parameters=[]) | |
setDeclineURL ($url, array $parameters=[]) | |
setBaseURL ($url) | |
includeTicket ($name= 'studip_ticket') | |
__toString () | |
Static Public Member Functions | |
static | create ($question, $accept_url= '', $decline_url= '') |
static | createHTML ($question, $accept_url= '', $decline_url= '') |
Protected Member Functions | |
__construct ($question, $accept_url, $decline_url) | |
extractURLParameters ($url) | |
Protected Attributes | |
$question | |
$accept_url | |
$accept_parameters = [] | |
$decline_url | |
$decline_parameters = [] | |
$include_ticket = false | |
A question box is used to display a confirmation dialog for a specific action, quite similar to the message boxes.
A question box consists at least of a question and some approval parameters that will be sent when the question is approved. You may pass additional parameters that are sent when the question is disapproved and both urls for approving and disapproving may be set.
|
finalprotected |
Constructs the object. Protected to enforce the use of our static helper functions.
string | $question | The question that should be confirmed |
__toString | ( | ) |
|
static |
Creates a question object that should be confirmed.
If you want to pass additional parameters, include them in the url. They will be extract from the url.
string | $question | The question that should be confirmed |
string | $accept_url | URL to send the acceptance request to |
string | $decline_url | URL to send the declination request to |
|
static |
Creates a question object that should be confirmed. The question may contain HTML.
If you want to pass additional parameters, include them in the url. They will be extract from the url.
string | $question | The question that should be confirmed |
string | $accept_url | URL to send the acceptance request to |
string | $decline_url | URL to send the declination request to |
|
protected |
Extracts parameters from a url.
string | $url |
includeTicket | ( | $name = 'studip_ticket' | ) |
Defines whether a stud.ip ticket should be included in the question.
bool | $name |
setAcceptURL | ( | $url, | |
array | $parameters = [] |
||
) |
Set the url the acceptance request is sent to.
string | $url | |
array | $parameters |
setBaseURL | ( | $url | ) |
Sets boths url for acceptance and declination to the same url.
string | $url |
setDeclineURL | ( | $url, | |
array | $parameters = [] |
||
) |
Set the url the declination url is sent to.
string | $url | |
array | $parameters |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |