How to solve Joomla Error " The template for this display is not available."

15,923

Solution 1

This error is raised when the chosen template (in administrator->extensions->templates) for either the admin or the site is not available.

Since you made a full ftp backup it can be one of two things:

  • the template was not included in the backup; possibly because of wrong privileges (sometimes the ftp account and the web account run under different users)

  • the template is not readable by the user running the current apache: it could have wrong permissions or wrong ownership or both on the new server.

Depending on the case above, you might want to re-check your entire installation, and run an update package just to be on the safe side.

The third, albeit unlikely, option is that in the database the #__templates table was - for some funny reason - not copied over or somewhat corrupted.

The error message is a bit misleading (what is a display?).

Update with solution:

The message is generated in the libraries/cms/application/site.php file by the following lines:

if (!file_exists(JPATH_THEMES . '/' . $template->template . '/index.php'))
{
    $this->enqueueMessage(JText::_('JERROR_ALERTNOTEMPLATE'), 'error');

and JPATH_THEMES is defined in the /includes/defines.php as

define('JPATH_THEMES',        JPATH_BASE . '/templates');

So the error is most definitely the missing template.

I was able to reproduce this on another Joomla 3.2 site simply by selecting Extensions->Templates->**and making **Bluestork the default template. Switch it to Isis and the issue will disappear; I guess you could do the same for the frontend choosing another template.

Solution 2

I had this problem in the Administrator backend on Joomla 3.8.6 (after updating from an earlier Joomla version). I had already tried switching the default template to Isis but, in my case, this didn't cure it and none of the other solutions worked. Eventually I was able to fix it by editing the database from phpMyAdmin as follows: opened _template_styles and changed the "home" value for "isis" template from 0 to 1.

Share:
15,923
Shiva
Author by

Shiva

Master of Technology #Bioinformatics, #RNABiology, #WebDeveloper #PHP5,#HTML5,Believe in #Extraterritorial Life #Aliens #SOreadytohelp

Updated on June 04, 2022

Comments

  • Shiva
    Shiva about 2 years

    Hi all thanks for taking time to read my question, I was using iPages as my host since past few year now I got a new hosting provider so I am Migrating my Joomla! 3.1.5 from iPage to my new hosting provider.

    Here is the steps I have followed ^1.

    1. FTP backup iPage
    2. FTP upload on Newhosting
    3. Database Export (From Old server)
    4. Database import (To new Server)
    5. Configuration.php modification

    Here is the config Details, These are only detail I changed with new data

    var $host = 'localhost'; 
    var $user = 'the_db_username';
    var $password = 'the_db_password';
    

    After all this I am not able to see previous look of website. I am getting login option on home page when i am logging in it says:

    "The template for this display is not available.Please contact a Site administrator."

    I can access to the admin panel using admin credentials but same error message I am getting there.

    This is the home page of website

    This is admin panel

    Any suggestion..!!

    Thanks

  • Shiva
    Shiva about 10 years
    Thanks for your reply. I tried most of your steps but no luck. I have also added image to explain error exactly I am getting Thanks Again :)
  • Riccardo Zorn
    Riccardo Zorn about 10 years
    ok the screenshot won: I compared it to mine, and it was too different! So I tried switching templates, your issue is the missing/incomplete bluestork template, I added an update to my answer
  • Eoin
    Eoin over 2 years
    Just in case anyone else is reading I changed the state value from 0 to 1