0

I am using custom module to insert and rendering data from Drupal Database.Is it possible rendering data using theme table in my custom div block

1

1 Answer 1

2

You could render content as table using Theme Table

<?php
$table_element = array(
    '#theme' => 'table',
    '#header' => $header,
    '#rows' => $rows,
    '#empty' =>t('Your table is empty'),
);   
drupal_render($table_element);
?>

Here are some Examples for it:

Not the answer you're looking for? Browse other questions tagged or ask your own question.