MediaWiki REL1_33
CaptchaHashStore.php
Go to the documentation of this file.
1<?php
2
4 protected $data = [];
5
6 public function store( $index, $info ) {
7 $this->data[$index] = $info;
8 }
9
10 public function retrieve( $index ) {
11 if ( array_key_exists( $index, $this->data ) ) {
12 return $this->data[$index];
13 }
14 return false;
15 }
16
17 public function clear( $index ) {
18 unset( $this->data[$index] );
19 }
20
21 public function cookiesNeeded() {
22 return false;
23 }
24
25 public function clearAll() {
26 $this->data = [];
27 }
28}
and that you know you can do these things To protect your we need to make restrictions that forbid anyone to deny you these rights or to ask you to surrender the rights These restrictions translate to certain responsibilities for you if you distribute copies of the or if you modify it For if you distribute copies of such a whether gratis or for a you must give the recipients all the rights that you have You must make sure that receive or can get the source code And you must show them these terms so they know their rights We protect your rights with two and(2) offer you this license which gives you legal permission to copy
cookiesNeeded()
Whether this type of CaptchaStore needs cookies.
retrieve( $index)
Retrieve the answer for a given captcha.
clear( $index)
Delete a result once the captcha has been used, so it cannot be reused.
store( $index, $info)
Store the correct answer for a given captcha.