Skip to content
Permalink
Browse files

no jquery + security + updates

  • Loading branch information
BitDesert committed Jun 30, 2019
1 parent a6d84c1 commit c8c78000a92ba5457bdec791d366068e667bf106
@@ -8,7 +8,7 @@

<h3>Contribute to <?php echo currencyName($currency); ?> Node Monitor</h3>
<p>
If you want to contribute to <?php echo currencyName($currency); ?> Node Monitor and further improve it, your help is very welcome. Have a look at its <a href="https://github.com/NanoTools/nanoNodeMonitor" target="_blank">GitHub page</a>, browse through open issues, check out the source code, create a branch, develop features, fix some bugs, and open pull requests. Development follows the standard <a href="https://guides.github.com/introduction/flow/" target="_blank">GitHub Flow</a> method.
If you want to contribute to <?php echo currencyName($currency); ?> Node Monitor and further improve it, your help is very welcome. Have a look at its <a href="https://github.com/NanoTools/nanoNodeMonitor" target="_blank" rel="noopener">GitHub page</a>, browse through open issues, check out the source code, create a branch, develop features, fix some bugs, and open pull requests. Development follows the standard <a href="https://guides.github.com/introduction/flow/" target="_blank" rel="noopener">GitHub Flow</a> method.
</p>

<br>
@@ -17,64 +17,15 @@

<p>
Donations support the efforts of the <?php echo currencyName($currency); ?> community to further decentralize the <?php echo currencyName($currency); ?> network by running representative nodes.
Please consider donating to the maintainer of this <?php echo currencyName($currency); ?> node to help cover some of its costs. Simply click the BrainBlocks button below.
Please consider donating to the maintainer of this <?php echo currencyName($currency); ?> node to help cover some of its costs. Simply scan the QR code with your wallet app.
</p>


<div class="row">
<div class="col-3">

<div class="form-group">
<div class="input-group mb-3">
<input id="bbAmountNode" class="form-control" aria-label="Amount" type="text" value="0.1">
<div class="input-group-append">
<span class="input-group-text">NANO</span>
</div>
</div>
</div>

</div>
</div>

<div id="bb-button"></div>

<div id="donateMessage" class="alert alert-dismissible alert-success" style="display:none;">
<button type="button" class="close" data-dismiss="alert">&times;</button>
<strong>Thanks!</strong> Your support helps a lot!
</div>

<script>
init.push(function(){
$( "#bbAmountNode" ).keyup(updateBrainButton);
updateBrainButton();
});

function updateBrainButton() {
$('#bb-button').empty();
brainblocks.Button.render({
// Pass in payment options
payment: {
destination: '<?php echo $nanoDonationAccount; ?>',
currency: 'rai',
amount: $('#bbAmountNode').val() * 1000000
},

// Handle successful payments

onPayment: function(data) {
$('#donateMessage').show();
console.log('Payment successful!', data.token);
}

}, '#bb-button');
};

</script>

<script src="https://brainblocks.io/brainblocks.min.js"></script>

<a href="nano:<?php echo $nanoNodeAccount; ?>">
<img src="https://chart.googleapis.com/chart?chs=150x150&cht=qr&chl=nano:<?php echo $nanoNodeAccount; ?>&choe=UTF-8"
title="QR code for <?php echo $nanoNodeAccount; ?>"
style="max-width:250px; display:block;" />
</a>
<br>

<!--- add the footer -->

<?php include 'modules/footer.php'; ?>
@@ -13,15 +13,17 @@
<div class="page-header mb-3" id="banner">
<div class="row">
<div class="col-lg-8 col-md-6 col-sm-6">
<a href="<?php echo $coinURL; ?>" target="_blank">
<a href="<?php echo $coinURL; ?>" target="_blank" rel="noopener">
<img src="static/img/nano-full-<?php echo $themeChoice; ?>.svg" width="220" alt="Logo"/>
</a>
<p class="lead mt-2"><?php echo currencyName($currency); ?> Node Monitor</p>
<p><?php echo $welcomeMsg; ?></p>

<div class="btn-group mb-3">
<?php foreach ($socials as $socialkey => $socialvalue): ?>
<a href="<?php echo $socialvalue; ?>" target="_blank" class="btn btn-secondary"><i class="fab fa-<?php echo $socialkey; ?>"></i></a>
<a href="<?php echo $socialvalue; ?>" target="_blank" rel="noopener" class="btn btn-secondary" aria-label="Social Media">
<i class="fab fa-<?php echo $socialkey; ?>"></i>
</a>
<?php endforeach; ?>
</div>

@@ -18,9 +18,9 @@
?>

<br>
Made by <a href="https://github.com/NanoTools" target="_blank">Nano Tools</a>.
Made by <a href="https://github.com/NanoTools" target="_blank" rel="noopener">Nano Tools</a>.
<br>
GitHub: <a href="<?php echo PROJECT_URL; ?>" target="_blank">Source</a> | <a href="<?php echo PROJECT_URL . '/wiki'; ?>" target="_blank">Wiki</a> | <a href="<?php echo PROJECT_URL . '/wiki/API-Description'; ?>" target="_blank">API</a>
GitHub: <a href="<?php echo PROJECT_URL; ?>" target="_blank" rel="noopener">Source</a> | <a href="<?php echo PROJECT_URL . '/wiki'; ?>" target="_blank" rel="noopener">Wiki</a> | <a href="<?php echo PROJECT_URL . '/wiki/API-Description'; ?>" target="_blank" rel="noopener">API</a>
</p>

<hr class=light>
@@ -42,18 +42,17 @@
}
?>

Donations to <?php echo currencyName($currency); ?> Node Monitor: <a href="<?php echo getAccountUrl($donAccount, $blockExplorer); ?>" target="_blank"><?php echo $donAccount; ?></a>
Donations to <?php echo currencyName($currency); ?> Node Monitor: <a href="<?php echo getAccountUrl($donAccount, $blockExplorer); ?>" target="_blank" rel="noopener"><?php echo $donAccount; ?></a>
</small>
<button id="copyAccount" class="btn btn-sm btn-link btn-clipboard-light" data-clipboard-text="<?php echo $donAccount; ?>" title="Copy"><i class="fas fa-clipboard fa-lg"></i></button>
</p>
</footer>

</div><!-- /container -->

<script src="static/js/jquery-3.3.1.min.js?v=<?php echo PROJECT_VERSION; ?>"></script>
<script src="static/js/popper.min.js?v=<?php echo PROJECT_VERSION; ?>"></script>
<script src="static/js/bootstrap.min.js?v=<?php echo PROJECT_VERSION; ?>"></script>
<script src="static/js/handlebars-v4.0.11.js?v=<?php echo PROJECT_VERSION; ?>"></script>
<script src="static/js/axios.min.js?v=<?php echo PROJECT_VERSION; ?>"></script>
<script src="static/js/bootstrap-native-v4.min.js?v=<?php echo PROJECT_VERSION; ?>"></script>
<script src="static/js/handlebars-v4.1.2.js?v=<?php echo PROJECT_VERSION; ?>"></script>
<script src="static/js/main.js?v=<?php echo PROJECT_VERSION; ?>"></script>

<?php
@@ -159,7 +159,7 @@ function getVersionInformation($latestVersion)
{
$versionInfo .= "<br>A new version " . $latestVersion;
$versionInfo .= " is available on ";
$versionInfo .= "<a href=\"" . PROJECT_URL . "\" target=\"_blank\">GitHub.</a>";
$versionInfo .= "<a href=\"" . PROJECT_URL . "\" target=\"_blank\" rel=\"noopener\">GitHub.</a>";
}

return $versionInfo;
@@ -122,3 +122,13 @@ function getUptime($ch)
// post curl
return postCurl($ch, $data);
}

// get active difficulty
function getActiveDifficulty($ch)
{
// get uptime
$data = array("action" => "active_difficulty");

// post curl
return postCurl($ch, $data);
}
@@ -5,9 +5,10 @@

<title><?php echo currencyName($currency); ?> Node Monitor - <?php echo $nanoNodeName; ?></title>

<meta name="Description" content="Nano Node Monitor is a server-side PHP-based monitor for Nano nodes.">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="robots" content="noindex" />
<meta name="robots" content="all" />
<link rel="stylesheet" href="static/css/bootstrap.min.css?v=<?php echo PROJECT_VERSION; ?>" media="screen">
<link rel="stylesheet" href="static/css/fontawesome-all.min.css?v=<?php echo PROJECT_VERSION; ?>" media="screen">
<link rel="stylesheet" href="static/css/main.css?v=<?php echo PROJECT_VERSION; ?>" media="screen">
@@ -20,7 +20,7 @@
</li>

<li class="nav-item">
<a class="nav-link" href="<?php echo PROJECT_URL; ?>" target="_blank">GitHub Project</a>
<a class="nav-link" href="<?php echo PROJECT_URL; ?>" target="_blank" rel="noopener">GitHub Project</a>
</li>
</ul>

Large diffs are not rendered by default.

Large diffs are not rendered by default.

0 comments on commit c8c7800

Please sign in to comment.
You can’t perform that action at this time.