'.N; $notifs.='
'.N; $unreadnotifs=false; $res=mysqli_query($link,'SELECT * FROM Notifications ORDER BY Microtime DESC') or muoribene(mysqli_error($link),true); while ($row=mysqli_fetch_assoc($res)) { if ($row['Seen']==0) { $unreadnotifs=true; $notifclass='notifunseen'; } else { $notifclass='notifseen'; } $i++; if ($i<=$chunksize) { if ($i==1) $lastmicrotime=$row['Microtime']; $notifs.='
'.strftime('%d/%m/%y %T',$row['Microtime']).': '.$row['Notification'].'
'.N; } } $notifs.='
'.N; $notifs.='
Vedi tutte le notifiche
'.N; $notifs.=''.N; if ($unreadnotifs) { $imgoff='imgs/bell_act_off.svg'; $imgon='imgs/bell_act_on.svg'; } else { $imgoff='imgs/bell_off.svg'; $imgon='imgs/bell_on.svg'; } return(array( 'div'=>$notifs, 'imgoff'=>$imgoff, 'imgon'=>$imgon, 'lastmicrotime'=>$lastmicrotime, 'chunksize'=>$chunksize)); } ?>