Sum per page Display sum per page and Grand sum (added in v 1.9)

You can use sum per page function to display sum of any columns values of that page and sum total function to display grand total. Please note that these function display values dynamically on crud table only.

  
                            $pdocrud = new PDOCrud();
                            $pdocrud->crudTableCol(array("product_id","product_name","product_price","product_sell_price"));
                            $pdocrud->colSumPerPage("product_price");
                            $pdocrud->colSumPerPage("product_sell_price");
                            $pdocrud->colSumTotal("product_sell_price");
                            echo $pdocrud->dbTable("products")->render();
                        

Products

Showing 1 to 5 of 107 entries

# Product id Product name Product price Product sell price Actions
1 S10_1949 1952 Alpine Renault 1300 50.00 214.30
2 S10_4962 1962 LanciaA Delta 16V 103.42 147.74
3 S12_1099 1968 Ford Mustang 95.34 194.57
4 S12_1108 2001 Ferrari Enzo 95.59 207.80
5 S12_1666 1958 Setra Bus 77.90 136.67
6 Total - 422.25 Total - 901.08
6 Grand Total- 10642.36
# Product id Product name Product price Product sell price Actions