Versione Drupal

Per evitare la famosa pagina di errore del DB quando il sito è offline, basta abilitare nel file settings.php la configurazione che permette a drupal di determinare la posizione della pagina.

# $conf['maintenance_theme'] = 'bartik';

 

/**
* A custom theme can be set for the offline page. This applies when the site
* is explicitly set to maintenance mode through the administration page or when
* the database is inactive due to an error. It can be set through the
* 'maintenance_theme' key. The template file should also be copied into the
* theme. It is located inside 'modules/system/maintenance-page.tpl.php'.
* Note: This setting does not apply to installation and update pages.
*/
# $conf['maintenance_theme'] = 'NOME_DEL_TUO_THEMA';

 

Dopo di che basta creare un file chiamato

maintenance-page--offline.tpl.php

 

e customizzarlo a piacere.

Ho seguito questa guida: https://www.drupal.org/docs/7/theming/tools-and-best-practices/theming-…