How to display foreach values to tables formate or datables?

My foreach values like,

code :

<?php
 session_start();
 foreach($_SESSION['playlist'] as $key=>$value)
 {
 echo $key.' '.$value.'<pre>';
 }
 ?>

How to display foreach values to datables?

Do you mean in a html table? Just open the table before the loop, use the <tr> and <td> tags around each value, and close the table after the loop. Just as per normal html really.

This topic was automatically closed 91 days after the last reply. New replies are no longer allowed.