I'm having the following PHP code:
$Query1 = "Select ReportId,MailingFrequency from reports_scheduler WHERE UserId='$UserId'";
$result1 = db::sql($Query1);
$X = array();
while($x = mysql_fetch_assoc($result1)) {
$this->smarty->assign("X",$x['ReportId']);// This gives '1'
$this->smarty->assign("X",$x['MailingFrequency']);//This gives 'Saturday'
}
My HTML code:
{html_table loop=$X}
<table id="resulttable" border="1">
<tr>
<td>$X[0]</td>
<td>$X[1]</td>
</tr>
</table>