userTimeline(false, $since_id, $max_id); if ($statuses === false) { header('location: error.php?code='.$t->http_code);exit(); } $empty = count($statuses) == 0? true: false; if ($empty) { echo "
No tweet to display.
"; } else if ($t->http_code == 429) { echo "
API quota is used out, please wait for a moment before next refresh.
"; } else { include_once('lib/timeline_format.php'); $output = '
    '; $firstid = false; $lastid = false; foreach ($statuses as $status) { if (isset($status->retweeted_status)) { $output .= format_retweet($status,true); } else { $output .= format_timeline($status,$t->username); } if(!$firstid) $firstid = $status->id_str; $lastid = $status->id_str; } $lastid = bcsub($lastid, "1"); $output .= "
"; $output .= "Back"; $output .= "Next"; $output .= "
"; echo $output; } ?>