Jump to content

$service.domainstatus on all pages


Recommended Posts

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

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated