mirror of
https://github.com/YGGverse/YGGstate.git
synced 2025-01-27 06:54:34 +00:00
show admin label when host in ADMIN_REMOTE_ADDRESS_WHITELIST
This commit is contained in:
parent
01eeb1b347
commit
15d57568dd
@ -2,6 +2,7 @@
|
||||
|
||||
// Load dependencies
|
||||
require_once (__DIR__ . '/../config/app.php');
|
||||
require_once (__DIR__ . '/../library/access.php');
|
||||
require_once (__DIR__ . '/../library/mysql.php');
|
||||
require_once (__DIR__ . '/../../vendor/autoload.php');
|
||||
|
||||
@ -181,6 +182,9 @@ $peers = $memory->getByMethodCallback(
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<a class="logo" href="<?php echo WEBSITE_URL ?>"><?php echo str_replace('YGG', '<span>YGG</span>', WEBSITE_NAME) ?></a>
|
||||
<?php if (Access::address(ADMIN_REMOTE_ADDRESS_WHITELIST)) { ?>
|
||||
<sup class="label label-green font-size-12 font-width-normal cursor-default"><?php echo _('admin') ?></sup>
|
||||
<?php } ?>
|
||||
<form name="search" method="get" action="<?php echo WEBSITE_URL ?>/search.php">
|
||||
<input type="text" name="query" value="" placeholder="<?php echo _('this, address, ip, geo, port, keyword...') ?>" />
|
||||
<button type="submit"><?php echo _('search') ?></button>
|
||||
|
@ -213,6 +213,9 @@ $peerPortStatuses = $db->findLastPeerPortStatusesByPeerId($requestPeerId);
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<a class="logo" href="<?php echo WEBSITE_URL ?>"><?php echo str_replace('YGG', '<span>YGG</span>', WEBSITE_NAME) ?></a>
|
||||
<?php if (Access::address(ADMIN_REMOTE_ADDRESS_WHITELIST)) { ?>
|
||||
<sup class="label label-green font-size-12 font-width-normal cursor-default"><?php echo _('admin') ?></sup>
|
||||
<?php } ?>
|
||||
<form name="search" method="get" action="<?php echo WEBSITE_URL ?>/search.php">
|
||||
<input type="text" name="query" value="" placeholder="<?php echo _('this, address, ip, geo, port, keyword...') ?>" />
|
||||
<button type="submit"><?php echo _('search') ?></button>
|
||||
|
@ -1,6 +1,7 @@
|
||||
<?php
|
||||
|
||||
require_once (__DIR__ . '/../config/app.php');
|
||||
require_once (__DIR__ . '/../library/access.php');
|
||||
require_once (__DIR__ . '/../library/mysql.php');
|
||||
require_once(__DIR__ . '/../library/sphinxql.php');
|
||||
require_once __DIR__ . '/../../vendor/autoload.php';
|
||||
@ -84,6 +85,9 @@ $results = $sphinx->searchPeers($requestQuery,
|
||||
<div class="container">
|
||||
<div class="row">
|
||||
<a class="logo" href="<?php echo WEBSITE_URL ?>"><?php echo str_replace('YGG', '<span>YGG</span>', WEBSITE_NAME) ?></a>
|
||||
<?php if (Access::address(ADMIN_REMOTE_ADDRESS_WHITELIST)) { ?>
|
||||
<sup class="label label-green font-size-12 font-width-normal cursor-default"><?php echo _('admin') ?></sup>
|
||||
<?php } ?>
|
||||
<form name="search" method="get" action="<?php echo WEBSITE_URL ?>/search.php">
|
||||
<input type="text" name="query" value="<?php echo !empty($_SERVER['REMOTE_ADDR']) && $requestQuery == $_SERVER['REMOTE_ADDR'] ? 'this' : htmlentities($requestQuery) ?>" placeholder="<?php echo _('this, address, ip, geo, port, keyword...') ?>" />
|
||||
<button type="submit"><?php echo _('search') ?></button>
|
||||
|
Loading…
x
Reference in New Issue
Block a user