Add release notes to version string in header

This commit is contained in:
bergware
2018-05-10 18:44:55 +02:00
parent 43ee5e09f7
commit 856d9bbf57
2 changed files with 3 additions and 3 deletions

View File

@@ -23,7 +23,7 @@ require_once "$docroot/webGui/include/Markdown.php";
<body style="margin:14px 10px">
<?
$file = $_GET['file'];
if (file_exists($file) && strpos(realpath($file), '/tmp/plugins/') === 0 && substr($file, -4) == '.txt') echo Markdown(file_get_contents($file)); else echo Markdown("*No release notes available!*");
if (file_exists($file) && ($_GET['tmp'] || (strpos(realpath($file), '/tmp/plugins/') === 0 && substr($file, -4) == '.txt'))) echo Markdown(file_get_contents($file)); else echo Markdown("*No release notes available!*");
?>
<br><div style="text-align:center"><input type="button" value="Done" onclick="top.Shadowbox.close()"></div>
</body>

View File

@@ -42,9 +42,9 @@ if (strstr('gray,azure',$display['theme'])) {
foreach ($tasks as $page) if ($page['Code']) echo "#nav-item a[href='/{$page['name']}']:before{content:'\\{$page['Code']}'}\n";
foreach ($buttons as $page) if ($page['Code']) echo "#nav-item.{$page['name']} a:before{content:'\\{$page['Code']}'}\n";
}
$notes = '/tmp/plugins/unRAIDServer.txt';
$notes = '/var/tmp/unRAIDServer.txt';
if (!file_exists($notes)) file_put_contents($notes,shell_exec("/usr/local/emhttp/plugins/dynamix.plugin.manager/scripts/plugin changes /usr/local/emhttp/plugins/unRAIDServer/unRAIDServer.plg"));
$notes = "&nbsp;<a href='#' title='View Release Notes' onclick=\"openBox('/plugins/dynamix.plugin.manager/include/ShowChanges.php?file=$notes','Release Notes',600,900);return false\"><span class='fa fa-info-circle fa-fw blue-text'></span></a>"
$notes = "&nbsp;<a href='#' title='View Release Notes' onclick=\"openBox('/plugins/dynamix.plugin.manager/include/ShowChanges.php?tmp=1&file=$notes','Release Notes',600,900);return false\"><span class='fa fa-info-circle fa-fw blue-text'></span></a>"
?>
</style>