forked from ashley-graves/bwitter
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpublic_timeline.php
More file actions
47 lines (37 loc) · 1.19 KB
/
Copy pathpublic_timeline.php
File metadata and controls
47 lines (37 loc) · 1.19 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
<?php include_once "inc/main.php";
$page = !empty($_GET['page']) ? (int) $_GET['page'] : 1;
$total = count($_ATWEETS);
$limit = 100;
$totalPages = ceil($total/ $limit);
$page = max($page, 1);
$page = min($page, $totalPages);
$offset = ($page - 1) * $limit;
if($offset < 0) $offset = 0;
$_STWEETS = array_slice($_ATWEETS, $offset, $limit);
$feat = true;
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<?php include "inc/head.php"; ?>
<body class="account" id="front">
<?php include "inc/css.php"; ?>
<div id="container" class="subpage">
<?php include "inc/header.php"; ?>
<div id="content">
<div class="wrapper">
<h3>Look at what these people are doing right now…</h3>
<table class="doing" id="timeline" cellspacing="0">
<?php foreach($_STWEETS as $_STATUS) { render_bweet($_STATUS); } ?>
</table>
<?php include "inc/paginator.php"; ?>
</div>
</div>
<hr />
<?php include "inc/side.php"; ?>
<hr />
<hr />
<?php include "inc/footer.php"; ?>
</div>
</body>
<?php ?>
</html>