non lo so se funziona, potresti provare così, non ho conoscenze di PHP ma ci provo così almeno se sbaglio faccio esperienza :D
Codice PHP:
$time = date(H)
$pass = array(
'default' => 'abc',
'1' => 'abc',
'2' => 'abc',
'3' => 'abc',
'4' => 'abc',
'5' => 'abc',
'6' => 'abc',
'7' => 'abc',
'8' => 'abc',
'9' => 'abc',
'10' => 'abc',
'11' => 'abc',
'12' => 'abc',
'13' => 'abc',
'14' => 'abc',
'15' => 'abc',
'16' => 'abc',
'17' => 'abc',
'18' => 'abc',
'19' => 'abc',
'20' => 'abc',
'21' => 'abc',
'22' => 'abc',
'23' => 'abc',
'24' => 'abc',
);
if ($time =< 1) {
$password = $pass['$time'];
}
elseif ($time =< 2) {
$password = $pass['$time'];
}
elseif ($time =< 3) {
$password = $pass['$time'];
}
elseif ($time =< 4) {
$password = $pass['$time'];
}
elseif ($time =< 5) {
$password = $pass['$time'];
}
elseif ($time =< 6) {
$password = $pass['$time'];
}
elseif ($time =< 7) {
$password = $pass['$time'];
}
elseif ($time =< 8) {
$password = $pass['$time'];
}
elseif ($time =< 9) {
$password = $pass['$time'];
}
elseif ($time =< 10) {
$password = $pass['$time'];
}
elseif ($time =< 11) {
$password = $pass['$time'];
}
elseif ($time =< 12) {
$password = $pass['$time'];
}
elseif ($time =< 13) {
$password = $pass['$time'];
}
elseif ($time =< 14) {
$password = $pass['$time'];
}
elseif ($time =< 15) {
$password = $pass['$time'];
}
elseif ($time =< 17) {
$password = $pass['$time'];
}
elseif ($time =< 18) {
$password = $pass['$time'];
}
elseif ($time =< 19) {
$password = $pass['$time'];
}
elseif ($time =< 20) {
$password = $pass['$time'];
}
elseif ($time =< 21) {
$password = $pass['$time'];
}
elseif ($time =< 22) {
$password = $pass['$time'];
}
elseif ($time =< 23) {
$password = $pass['$time'];
}
elseif ($time =< 24) {
$password = $pass['$time'];
}
else {
$password = $pass['default'];
}
Non assicuro niente, è una prova, ma sono sicuro che deve essere rivisto