Jump to content

{$totalclientcount} ?


Cain72

Recommended Posts

Hi guys,

 

Just a quick one, is there or has anyone come up with a way to pull total client count ? im sure there would be a way to do it,

 

what i'd like to do is get the total count and link it up to one of the pages, a lame eg: would be ...

 

<div class="maxclientcount">
<p>{$maxclientcount}, happy customers cant be wrong, sign up today!!</p>
</div>

 

 

you get the idea,

 

can anyone point me in the right direction,

 

 

cheers

 

 

Cain

Link to comment
Share on other sites

hello Cain,

 

your request is very simple just create new hook file in "/includes/hooks/" directory with any name for example "totalclients.php" so this will be located here: WHMCS-Main-Dir/includes/hooks/totalclients.php

 

and put the following code inside it:

<?php

function hook_getTotalClients($params){
   $totalclients = get_query_val("tblclients","COUNT(id)","");
return array('maxclientcount', $totalclients);
}
add_hook("ClientAreaPage", 1, "hook_getTotalClients");

?>

so this:

<div class="maxclientcount">
<p>{$maxclientcount}, happy customers cant be wrong, sign up today!!</p>
</div>

will display a real number of your clients,

let me know if run into issues,

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