version handling

This commit is contained in:
root 2016-01-04 10:54:56 +01:00
parent 0ee6abf7f4
commit b3457ea438
5 changed files with 26 additions and 11 deletions

View File

@ -1,4 +1,5 @@
# SMBind-ng Installation Guide
v0.91c
## Requirements
* Any kind of webserver with php usage abilities (tested on apache2, lighttpd,

View File

@ -1,10 +1,22 @@
<?php
$_CONF['db_type'] = '';
$_CONF['db_user'] = '';
$_CONF['db_pass'] = '';
$_CONF['db_host'] = '';
$_CONF['db_port'] = '';
$_CONF['db_db'] = '';
$_CONF['smarty_path'] = '';
$_CONF['peardb_path'] = '';
$_CONF['db_type'] = 'mysql';
$_CONF['db_user'] = 'smbind';
$_CONF['db_pass'] = 'smbind';
$_CONF['db_host'] = '10.21.32.7';
$_CONF['db_port'] = '3306';
$_CONF['db_db'] = 'smbind';
$_CONF['smarty_path'] = '/usr/share/php/smarty3/';
$_CONF['peardb_path'] = '/usr/share/php';
$_CONF['title'] = 'MyOnline Primary NS management';
$_CONF['footer'] = '<b>PRIMARY site</b> - Switch to <a class=attention href="https://service.myonline.hu/dnsslave/"><b>SECONDARY site</b></a> | You are from: <b>' . $_SERVER['REMOTE_ADDR'] . '</b>';
$_CONF['recaptcha'] = true;
$_CONF['rc_pubkey'] = '6LectQcTAAAAAGLTGJQpjM8eh8YEozuXYFqpLDqG';
$_CONF['rc_privkey'] = '6LectQcTAAAAAGBDl7u5lrbVQmNYtlF37K2RkArR';
$_CONF['nocaptcha'] = array (
'78.131.57.83',
'194.149.54.36',
);
$_CONF['path'] = '/etc/smbind/zones/';
$_CONF['conf'] = '/etc/smbind/smbind.conf';
$_CONF['rollerconf'] = '/etc/smbind/rollrec/zones.rollrec';
?>

View File

@ -211,7 +211,8 @@
if (is_string($path)) {
$_CONF['smbind_ng'] = $path;
$_CONF['title'] = "SMBind-ng";
$_CONF['footer'] = $_CONF['title'] . " v0.91b";
$_CONF['version'] = 'v0.91c';
$_CONF['footer'] = $_CONF['title'] . $_CONF['version'];
$_CONF['marker'] = "Forked by PtY 2015(GPL)";
$_CONF['template'] = "default";
$_CONF['recaptcha'] = false;

View File

@ -86,7 +86,7 @@ if (isset($_POST['username']) && isset($_POST['password']) && ($cap_rsp == NULL)
}
$user = new User();
$smarty->assign("loggedinuser",$user->getFullName());
$smarty->assign("loggedinuser",preg_replace('/\s/', '&nbsp;', $user->getFullName()));
if ($user->getId() == 0) {
login_page($smarty);
@ -100,6 +100,7 @@ if ((isset($_SERVER['PHP_SELF'])) && (basename($_SERVER['PHP_SELF']) != 'index.p
if($user->isAdmin()) {
$smarty->assign("admin", "yes");
$smarty->assign("version", $conf->version);
} else {
$smarty->assign("admin", "no");
}

View File

@ -2,4 +2,4 @@
<div class=title>{$TITLE}</div>
<div class=section><p>{$pagetitle}</p></div>{include file="menu.tpl"}{include file=$template}
<div class=hint><p>{$help}</p></div>
{if $loggedinuser}<div class=loggeduser>Logged in as: <strong>{$loggedinuser}</strong></div>{/if}{include file="footer.tpl"}
{if $loggedinuser}<div class=loggeduser>Logged&nbsp;in&nbsp;as:&nbsp;<strong>{$loggedinuser}</strong>{if $admin}&nbsp;|&nbsp;App&nbsp;engine:&nbsp;<strong>{$version}</strong>{/if}</div>{/if}{include file="footer.tpl"}