FRED™
3.0
FRED™: Framework for Rapid and Easy Development
Honeypot.php
Go to the documentation of this file.
1
<?php
2
3
namespace
Rsi\Fred\Security\Check
;
4
5
class
Honeypot
extends
\Rsi\Fred\Security\Check{
6
7
protected
$_key
=
'honeypot'
;
8
protected
$_styleClassName
=
null
;
9
10
protected
function
init
(){
11
parent::init();
12
$this->
component
(
'event'
)->listen(\
Rsi
\Fred\
Controller
\
View
\Html::EVENT_FORM,
function
($sender,$params){
13
$params[
'content'
] = $this->
component
(
'html'
)->input(
null
,[
'class'
=> $this->_styleClassName],$this->_styleClassName ?
'text'
:
'hidden'
,$this->_key) . $params[
'content'
];
14
});
15
}
16
17
public
function
check
($expected =
false
){
18
return
!$this->
component
(
'request'
)->simple($this->_key);
19
}
20
21
}
Rsi\Fred\Controller\View
Definition:
View.php:5
Rsi
Rsi\Fred\Security\Check\Honeypot\check
check($expected=false)
Perform the check.
Definition:
Honeypot.php:17
Rsi\Fred\Security\Check\Honeypot\$_key
$_key
Definition:
Honeypot.php:7
Rsi\Fred\Controller
Definition:
Controller.php:5
Rsi\Fred\Security\Check
Definition:
Csrf.php:3
Rsi\Fred\Component\component
component($name)
Get a component (local or default).
Definition:
Component.php:81
Rsi\Fred\Security\Check\Honeypot\$_styleClassName
$_styleClassName
Definition:
Honeypot.php:8
Rsi\Fred\Security\Check\Honeypot
Definition:
Honeypot.php:5
Rsi\Fred\Security\Check\Honeypot\init
init()
Definition:
Honeypot.php:10
src
Rsi
Fred
Security
Check
Honeypot.php
Generated on Sat Jun 27 2026 16:33:38 for FRED™ by
1.8.17