Jump to content

Display Credit Balance In Six Template


sentq

Recommended Posts

Some people want to show their client's credit balance when they login to client area, as the option not implemented by default in Six Template here is how to do it:

1) Upload the PHP file from Attachements to -> /WHMCS-Path/includes/hooks/ directory.

 

Thanks for sharing this sentq, it works perfectly and your code has helped me to understand the sidebar implementation a little better.

Link to comment
Share on other sites

  • 3 weeks later...
Some people want to show their client's credit balance when they login to client area, as the option not implemented by default in Six Template here is how to do it:

1) Upload the PHP file from Attachements to -> /WHMCS-Path/includes/hooks/ directory.

CANNOT donwload the sample hook zip file. each and everytime it goes to the

[h=3]You are not logged in or you do not have permission to access this page.[/h]

I can do everything else and have been a user for a good few years. Simply wont let me do it :?:

 

- - - Updated - - -

 

CANNOT donwload the sample hook zip file. each and everytime it goes to the

You are not logged in or you do not have permission to access this page.

 

 

I can do everything else and have been a user for a good few years. Simply wont let me do it :?:

 

SPOKE too SOON. I opened the link via right click open new tab and it worked. ALthough clicking the link itself still takes me to the permissions error page. Strange..

 

P.S thanks for a great sample plugin 8)

Link to comment
Share on other sites

  • 2 weeks later...

Lol what for an addon ?!

 

You juste have to put :

<tr>

<td class="textright"><strong><dl><dd class="title">{$LANG.statscreditbalance}</a> :</dd></strong></td>

<td><dd class="number">{$clientsstats.creditbalance}</a></dd></dl></td>

</tr>

 

To your file clientareaaddfunds.tpl

 

No need hook for that ^^

 

Regards

Link to comment
Share on other sites

Lol what for an addon ?!

You just have to put To your file clientareaaddfunds.tpl

No need hook for that ^^

you do realise that when you update your WHMCS template, if WHMCS changes the clientareaaddfunds.tpl template, you'll lose the above additional code - but sentq's hook will continue to work! :)

 

in any event, your code and the hook are two different things... your code just adds the balance on the add funds page, sentq's hook will display it on the client homepage (and could be modified to work on other pages too).

Link to comment
Share on other sites

Thank you! hook works insanely well...

 

Found one issue, when in "Portal Home / Client Area / My Invoices" the Secondary_Sidebar-Billing module glitches out from the sidebar. Sorry not very familiar, learning whmcs as I go along. (See screenshot) Is there an easy fix to this?

 

Thanks in advance...

 

Once again Great Hook!!!

 

Screen Shot 2015-11-12 at 5.25.16 PM.png

Link to comment
Share on other sites

have you modified the hook in any way? when I go to that page on my dev site, the credit balance sidebar isn't shown there - it only appears on the client homepage.

 

Hi, Wow you respond quickly. No not at all... also re-downloaded and uploaded the hook again... and still the same issue?

Link to comment
Share on other sites

Hi, Wow you respond quickly. No not at all... also re-downloaded and uploaded the hook again... and still the same issue?

Is the issue only appear when you use this hook?

What version of WHMCS you currently use? if you have the 6.1.1 does your template use the latest template updates in v6.1.1?

Tell me how to replicate the issue and i will check, thank you

Link to comment
Share on other sites

Hi, thanks for getting back to me,

 

Yes, if I remove the hook everything goes back to normal. Billing block moves back to sidebar.

 

Using Version: 6.1.1 and also using latest v6 template.

 

Thanks for looking into this for me. Let me know if you need anything else.

Link to comment
Share on other sites

Hi also notices that when changing the code from “Primary” to “Secondary” it resolves the issue… : ) and then also moves it between “Your Info” block and “Contacts” block… which also works well.

 

 

ClientAreaSecondarySidebar

 

$secondarySidebar

Link to comment
Share on other sites

  • 2 weeks later...
  • 4 weeks later...
Thank you! hook works insanely well...

 

Found one issue, when in "Portal Home / Client Area / My Invoices" the Secondary_Sidebar-Billing module glitches out from the sidebar. Sorry not very familiar, learning whmcs as I go along. (See screenshot) Is there an easy fix to this?

 

Thanks in advance...

 

Once again Great Hook!!!

 

[ATTACH=CONFIG]9667[/ATTACH]

I was able to replicate the issue, even without using this Sidebar ActionHook, looks like a problem with Six Template but it can be fixed (almost) with CSS.

 

The issue only appear when left sidebar (Primary) gets height more than the content in the middle, this will cause the Secondary sidebar to be displayed as in the screenshot above, this need to be fixed by WHMCS it self :?: someday.

 

as a work around here is how you can solve this issue when you face it anytime, or simple to avoid it, add the following inside /templates/six/css/custom.css:

.main-content {
 min-height: 600px;
}

Link to comment
Share on other sites

  • 2 weeks later...
  • 1 month later...

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.

×
×
  • 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