backup.php:

- move "unmaintained" warning to templates/backupwarning.tpl (that's 
  the easiest way to have working HTML tags) 
- remove <p> tag from pgsql error message

templates/backupwarning.tpl
- new file, contains the "unmaintained" warning for backup.php


git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1542 a1433add-5e2c-0410-b055-b7f2511e0802
pull/2/head
Christian Boltz 11 years ago
parent 8ea4fd6c82
commit f02b781376

@ -29,20 +29,14 @@ authentication_require_role('global-admin');
// TODO: make backup supported for postgres
if ('pgsql'==$CONF['database_type']) {
flash_error('<p>Sorry: Backup is currently not supported for your DBMS ('.$CONF['database_type'].').</p>');
flash_error('Sorry: Backup is currently not supported for your DBMS ('.$CONF['database_type'].').');
$smarty->assign ('smarty_template', 'message');
$smarty->display ('index.tpl');
die;
}
if (safeget('download') == "") {
flash_error('
<p><span class="error_msg">Warning:</span> The backup module of PostfixAdmin is poorly maintained and might contain bugs.</p>
<p>Please use <tt>mysqldump</tt> to get a reliable backup of your database.</p>
<p>&nbsp;</p>
<p>If you still trust this backup module, you can <a href="backup.php?download=1" class="button">download the database dump now</a></p>
');
$smarty->assign ('smarty_template', 'message');
$smarty->assign ('smarty_template', 'backupwarning');
$smarty->display ('index.tpl');
die;
}

@ -0,0 +1,6 @@
<ul class="flash-error">
<li><span class='error_msg'><b>Warning:</b></span> The backup module of PostfixAdmin is poorly maintained and might contain bugs.
<li>Please use <tt>mysqldump</tt> to get a reliable backup of your database.
<li>&nbsp;
<li>If you still trust this backup module, you can <a href="backup.php?download=1" class="button">download the database dump now</a>
</div>
Loading…
Cancel
Save