{php}
$postData = array('gid' => '1',);
$results = localAPI('GetProducts', $postData, 'admin');
//print_r( $results);
foreach ($results['products']['product'] as $product) {
$description =$product['description'];
$description = str_replace(array('<ul>', '</ul>'), '', $description);
$description = str_replace('<li>', '<td>', $description);
$description = str_replace('</li>', '</td>', $description);
$getProducts[] = array(
'name' => $product['name'],
'url' => $product['product_url'],
'desc' => $description,
'prefix' => $product['pricing']['USD']['prefix'],
'price' => $product['pricing']['USD']['monthly'],
);
}
$_smarty_tpl->assign('getProducts', $getProducts);
{/php}
{foreach $getProducts as $value }
<tr>
{$value.desc}
<td><span class="price">{$value.prefix}{$value.price}<span>/MRC</span></span> </td>
<td><a href="{$value.url}" class="btn btn-success">Order</a>
</td>
</tr>
{/foreach}