Search

Monday 8 February 2010

Tabulation updated

We have slightly upgraded the tabulation function but the function is both important and comes very handy these days, in most e-commerce sites which gives user the control over they wish to see the results sort their prices etc.

So our new tabulation with pagination now has the sort function where you simply need to state which row needs to be sorted and in what order, i.e. Ascending or descending order.

The tabulation class can be downloaded from here:

http://nasaralla.googlecode.com/files/tabulation.php

and how to use the class is defined in this post:

http://phphelperfunctions.blogspot.com/2010/01/simple-php-tabulation-helper-class.html

You only need to call the following function in order to call a page in a required sorted order.

_______________________________________________________

Example:

$results = $tab->getResultSorted(3, 'Hotel', 'DESC');

where the signature is

getResultSorted($page_number, $row_name, $sort_order);

for ascending order simply keep the order blank (default order)
_______________________________________________________