brettr Posted July 27, 2012 Share Posted July 27, 2012 Hi, A sidebar has been created to display the domain status (services from tblhosting database table) in the client area. This displays fine on page clientarea.php?action=products by inserting the following code: {if $service.rawstatus eq "cancelled"}{$LANG.clientareacompleted}{elseif $service.rawstatus eq "active"}{$LANG.clientareaactive}{elseif $service.rawstatus eq "pending"}{$LANG.clientareapending}{/if}. However, this does not display on other pages of the client area. I've tried adding custom PHP code to fetch the courses belonging to the logged in client and assigning them to a smarty array inside {php} tags at the top of footer.tpl {php} $userid = $this->_tpl_vars['clientsdetails']['id']; $result = mysql_query("SELECT *,tblhosting.id as serviceid FROM tblhosting,tblproducts WHERE userid =$userid AND tblhosting.packageid= tblproducts.id"); $services = array(); while ($data = mysql_fetch_array($result)) { array_push($services, $data); } $this->_tpl_vars['services'] = $services; {/php} However, this does not work correctly. Would anyone be able to assist please? Many thanks Brett 0 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.