Cakephp grid example

<?php
// echo $html->css('default');
?>
<style type="text/css">
table
{
  border-collapse: collapse;
}
 
th
{
  background-color: #00A300;
  color: #ffffff;
}
 
tr
{
  background-color: #D4FFA8;
  border-top: 1px solid #000000;
  border-bottom: 1px solid #000000;
}
</style>
 
<table>
 
<?php
 
echo $html->tableHeaders(
    array(
      'Product ID',
      'Product',
      'Description',
      'Price'
    )
);
 
foreach($data as $product)
{
  echo $html->tableCells(
      array(
        array(
          $product['Product']['product_id'],
          $product['Product']['product_name'],
          $product['Product']['product_desc'],
          $product['Product']['product_price']
        )
      )
    );
}
?>
 
</table>
Processing your request, Please wait....

No Responses to “Cakephp grid example”

Comments (Your Comments)

Leave a Reply

You must be logged in to post a comment.