-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathlatest.php
More file actions
24 lines (23 loc) · 903 Bytes
/
latest.php
File metadata and controls
24 lines (23 loc) · 903 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
<p>
<?php
/*------------------------------------------------------------------------*
* © 2010 University of Limerick. All rights reserved. This material may *
* not be reproduced, displayed, modified or distributed without the *
* express prior written permission of the copyright holder. *
*------------------------------------------------------------------------*/
require_once('./conf.php');
$db = new PDO('sqlite:'.BASE_DB_URL.'locTemp.sqlite');
$res = $db->query('Select * from Project where FinishDate is null Order by CreateDate Desc');
$c=0;
foreach($res as $row)
{
print "<span class='orangetext'><a href='http://".$_SERVER['HTTP_HOST'].BASE_URL."/track.php?id=".$row['ID']."'>".$row['PName']."</a></span><br/>";
$msg=$row['Desc'];
if (strlen($msg)>60) $msg=substr($msg,0,60).'..';
print $msg."<br/>";
$c=$c+1;
if ($c>2) break;
}
$db=NULL;
;?>
</p>