parent
ffab9dc4da
commit
3edb156749
5 changed files with 24 additions and 21 deletions
|
|
@ -80,15 +80,11 @@ class ZAPDisplay implements ZAPHandler {
|
|||
*/
|
||||
private function handleWords() {
|
||||
$words = array();
|
||||
$ix = 1;
|
||||
$postix = sprintf("%02d", $ix);
|
||||
$wd = 'word' . $postix;
|
||||
|
||||
while(!empty($_POST[$wd])) {
|
||||
array_push($words, $_POST[$wd]);
|
||||
$ix++;
|
||||
$postfix = sprintf("%02d", $ix);
|
||||
$wd = 'word' . $postfix;
|
||||
for ($i = 1; $i <= MAX_WORDS; $i++) {
|
||||
$key = 'word' . sprintf("%02d", $i);
|
||||
if (!empty($_POST[$key])) {
|
||||
$words[] = $_POST[$key];
|
||||
}
|
||||
}
|
||||
return $words;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue