PClib demo site

<?php
/* project: Taskman grid, file: taskman.php */

/* We want remember sorting of grid. It will be stored in session. */
session_start();

//Include pclib framework
require 'pclib/pclib.php';

//Create pclib application
$app = new PCApp('demo');

$datasource 'pdo_mysql://user:password@localhost/test';
$app->db = new PCDb($datasource);
$app->db->LOOKUP_TAB 'TASKMAN_LKP';

//Initialize grid template, set grid query and write grid out
$grid = new PCGrid('tpl/taskman.tpl''tasklist');
$grid->setQuery(
 
"select *, if(LASTMOD_AT>'2006-08-17',1,0) HI_MOD
  from TASKMAN_TASKS
  where ACTIVE=1
  order by CREATED_AT desc"
);

$grid->multiSort true;


print 
$grid->html();
?>

Elapsed time: 14.41 ms