◆ check()
check |
( |
|
$clearIfValid = true , |
|
|
|
$token = false , |
|
|
|
$name = 'XOOPS_TOKEN' |
|
) |
| |
Check if there is a valid token in $_REQUEST[$name . '_REQUEST'] - can be expanded for more wide use, later (Mith)
- Paramètres
-
bool | $clearIfValid | whether to clear the token after validation |
string | false | $token | token to validate |
string | $name | name of session variable |
- Renvoie
- bool
◆ checkBadips()
Check if visitor's IP address is banned Should be changed to return bool and let the action be up to the calling script
- Renvoie
- void
◆ checkReferer()
checkReferer |
( |
|
$docheck = 1 | ) |
|
Check the user agent's HTTP REFERER against XOOPS_URL
- Paramètres
-
int | $docheck | 0 to not check the referer (used with XML-RPC), 1 to actively check it |
- Renvoie
- bool
◆ checkSuperglobals()
Check superglobals for contamination
- Renvoie
- void
◆ clearTokens()
clearTokens |
( |
|
$name = 'XOOPS_TOKEN' | ) |
|
Clear all token values from user's session
- Paramètres
-
- Renvoie
- void
◆ createToken()
createToken |
( |
|
$timeout = 0 , |
|
|
|
$name = 'XOOPS_TOKEN' |
|
) |
| |
Create a token in the user's session
- Paramètres
-
int | string | $timeout | time in seconds the token should be valid |
string | $name | name of session variable |
- Renvoie
- string token value
◆ filterToken()
Check whether a token value is expired or not
- Paramètres
-
- Renvoie
- bool
◆ garbageCollection()
garbageCollection |
( |
|
$name = 'XOOPS_TOKEN' | ) |
|
Perform garbage collection, clearing expired tokens
- Paramètres
-
- Renvoie
- void
◆ getErrors()
& getErrors |
( |
|
$ashtml = false | ) |
|
Get generated errors
- Paramètres
-
bool | $ashtml | Format using HTML? |
- Renvoie
- array|string Array of array messages OR HTML string
◆ getTokenHTML()
getTokenHTML |
( |
|
$name = 'XOOPS_TOKEN' | ) |
|
Get the HTML code for a XoopsFormHiddenToken object - used in forms that do not use XoopsForm elements
- Paramètres
-
string | $name | session token name |
- Renvoie
- string
◆ setErrors()
Add an error
- Paramètres
-
- Renvoie
- void
◆ validateToken()
validateToken |
( |
|
$token = false , |
|
|
|
$clearIfValid = true , |
|
|
|
$name = 'XOOPS_TOKEN' |
|
) |
| |
Check if a token is valid. If no token is specified, $_REQUEST[$name . '_REQUEST'] is checked
- Paramètres
-
string | false | $token | token to validate |
bool | $clearIfValid | whether to clear the token value if valid |
string | $name | session name to validate |
- Renvoie
- bool
◆ $errors
La documentation de cette classe a été générée à partir du fichier suivant :