if($SESSIONS_actual == -1) unset($SESSIONS_actual);
$SESSIONS_totex = 0;
+ $SESSIONS_totex_nextinc = 0;
if(isset($SESSIONS)) {
foreach ($SESSIONS as $session) {
- if($session['id'] < $SESSIONS_next) { $SESSIONS_totex += $session['nexamples']; }
+ if( (! isset($SESSIONS_next)) || $session['id'] < $SESSIONS_next ) { $SESSIONS_totex += $session['nexamples']; }
+ if( (! isset($SESSIONS_actual)) || $session['id'] != $SESSIONS_actual ) { $SESSIONS_last = $session['id']; }
+ if( (! isset($SESSIONS_next)) || $session['id'] <= $SESSIONS_next ) { $SESSIONS_totex_nextinc += $session['nexamples']; }
}
}
- $SESSIONS_totex_nextinc = 0;
- if( isset($SESSIONS) && isset($SESSIONS_next) ) {
- foreach ($SESSIONS as $session) {
- if($session['id'] <= $SESSIONS_next) { $SESSIONS_totex_nextinc += $session['nexamples']; }
- }
- }
}
?>