Change the question id after confirmation (protect again validation by sender)
This commit is contained in:
parent
d2544cabb2
commit
a058ffa29f
3 changed files with 30 additions and 51 deletions
|
|
@ -50,9 +50,15 @@ class Question
|
|||
return $q;
|
||||
}
|
||||
|
||||
public function regen_id()
|
||||
{
|
||||
$this->id = md5(time().$this->question.$this->validator);
|
||||
}
|
||||
|
||||
public function set_validator($val)
|
||||
{
|
||||
$this->validator = $val;
|
||||
$this->regen_id();
|
||||
}
|
||||
|
||||
public function get_validator()
|
||||
|
|
|
|||
Reference in a new issue