Difference between revisions of "Troubleshooting Client Area Template Issues"

From WHMCS Documentation

(Check the Logs)
Line 1: Line 1:
You've upgraded your installation, but now your custom client area template is no longer working.
+
You've upgraded your installation, but now your custom client area template is no longer working. The steps below may help you.
 
 
Then you've come to the right place.  Let's start at the beginning...
 
  
 
==Why does this happen?==
 
==Why does this happen?==
Line 7: Line 5:
 
A blank or partially rendered page indicates a fatal PHP error is occurring which stops the execution from being able to continue.  This can be caused by a number of reasons, most commonly:
 
A blank or partially rendered page indicates a fatal PHP error is occurring which stops the execution from being able to continue.  This can be caused by a number of reasons, most commonly:
  
* Using PHP code blocks in your template without the '''Allow Smarty PHP Tags''' setting enabled (go to Setup > General Settings > Security to enable it)
+
* Using PHP code blocks in your template without the '''Allow Smarty PHP Tags''' setting enabled at '''Configuration (<i class="fa fa-wrench" aria-hidden="true"></i>) > System Settings > General Settings > Security'''.
 
* A custom or third party module or hook that is incompatible with the new version
 
* A custom or third party module or hook that is incompatible with the new version
 
* A syntax issue in your template
 
* A syntax issue in your template
Line 16: Line 14:
 
==Check the Logs==
 
==Check the Logs==
  
The first place to check any time you encounter an error of this nature is the [[Activity_Logs|Activity Log]].  This can be acccessed by navigating to '''Utilities > Logs > Activity Log''' within the admin area.  All errors encountered by the Smarty templating engine are logged here, and should help pinpoint the exact template and section of code that is causing the problem.
+
The first place to check any time you encounter an error of this nature is the [[Activity_Logs|Activity Log]].  This can be acccessed by navigating to '''System Settings (<i class="fa fa-wrench" aria-hidden="true"></i>) > System Logs''' ('''Utilities > Logs > Activity Log''' in WHMCS 7.x and earlier) within the admin area.  All errors encountered by the Smarty templating engine are logged here, and should help pinpoint the exact template and section of code that is causing the problem.
  
 
==Try a Different Template==
 
==Try a Different Template==
Line 24: Line 22:
 
If changing to a different template allows the client area to load successfully, then you know the issue is with your template itself.  If you continue to experience problems loading the client area with other templates, then your issue is more likely related to a module or hook and not a specific individual template.
 
If changing to a different template allows the client area to load successfully, then you know the issue is with your template itself.  If you continue to experience problems loading the client area with other templates, then your issue is more likely related to a module or hook and not a specific individual template.
  
To change the template your WHMCS system uses, navigate to '''Setup > General Settings''' and choose one of the default templates in the '''Template''' setting found on the first tab of the settings.  Then hit Save, and attempt to visit your client area.
+
To change the template your WHMCS system uses, navigate to '''Configuration (<i class="fa fa-wrench" aria-hidden="true"></i>) > System Settings > General Settings''' and choose one of the default templates in the '''Template''' setting found on the first tab of the settings.  Then, hit '''Save''', and attempt to visit your client area.
  
 
==Check Your Templates for Legacy Smarty Functions==
 
==Check Your Templates for Legacy Smarty Functions==

Revision as of 13:59, 4 August 2020

You've upgraded your installation, but now your custom client area template is no longer working. The steps below may help you.

Why does this happen?

A blank or partially rendered page indicates a fatal PHP error is occurring which stops the execution from being able to continue. This can be caused by a number of reasons, most commonly:

  • Using PHP code blocks in your template without the Allow Smarty PHP Tags setting enabled at Configuration () > System Settings > General Settings > Security.
  • A custom or third party module or hook that is incompatible with the new version
  • A syntax issue in your template
  • Using features of Smarty that have been removed in the upstream Smarty package

For more detailed information, please see Blank or Partially Rendered Pages.

Check the Logs

The first place to check any time you encounter an error of this nature is the Activity Log. This can be acccessed by navigating to System Settings () > System Logs (Utilities > Logs > Activity Log in WHMCS 7.x and earlier) within the admin area. All errors encountered by the Smarty templating engine are logged here, and should help pinpoint the exact template and section of code that is causing the problem.

Try a Different Template

If you don't find anything in the activity logs, switching to a different template will help determine where the issue lies.

If changing to a different template allows the client area to load successfully, then you know the issue is with your template itself. If you continue to experience problems loading the client area with other templates, then your issue is more likely related to a module or hook and not a specific individual template.

To change the template your WHMCS system uses, navigate to Configuration () > System Settings > General Settings and choose one of the default templates in the Template setting found on the first tab of the settings. Then, hit Save, and attempt to visit your client area.

Check Your Templates for Legacy Smarty Functions

Most custom templates won't need any updates to be compatible with newer versions of Smarty, but those features only available in Smarty 2 will need to be migrated to ensure a smooth transition to the latest version.

For more information on exactly what's changed, please refer to our Version 6 Template Migration Guide.

Contact our Support Team

If none of the above help, then you should contact our support team for further assistance. To do that, visit http://www.whmcs.com/support/ and select the Ask Us link.