Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <!DOCTYPE html>
- <html lang="en">
- <head>
- <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
- <style type="text/css">
- .gm-style .gm-style-mtc label,
- .gm-style .gm-style-mtc div {
- font-weight: 400
- }
- </style>
- <style type="text/css">
- .gm-control-active img {
- box-sizing: content-box;
- pointer-events: none
- }
- .gm-control-active:hover img:nth-child(1),
- .gm-control-active:active img:nth-child(1),
- .gm-control-active:active img:nth-child(2) {
- display: none
- }
- </style>
- <link type="text/css" rel="stylesheet" href="theme/css.css">
- <style type="text/css">
- .gm-ui-hover-effect {
- opacity: .7
- }
- .gm-ui-hover-effect:hover {
- opacity: 1
- }
- </style>
- <style type="text/css">
- .gm-style .gm-style-cc span,
- .gm-style .gm-style-cc a,
- .gm-style .gm-style-mtc div {
- font-size: 10px;
- box-sizing: border-box
- }
- </style>
- <style type="text/css">
- @media print {
- .gm-style .gmnoprint,
- .gmnoprint {
- display: none
- }
- }
- @media screen {
- .gm-style .gmnoscreen,
- .gmnoscreen {
- display: none
- }
- }
- </style>
- <style type="text/css">
- .gm-style-pbc {
- transition: opacity ease-in-out;
- background-color: rgba(0, 0, 0, 0.45);
- text-align: center
- }
- .gm-style-pbt {
- font-size: 22px;
- color: white;
- font-family: Roboto, Arial, sans-serif;
- position: relative;
- margin: 0;
- top: 50%;
- -webkit-transform: translateY(-50%);
- -ms-transform: translateY(-50%);
- transform: translateY(-50%)
- }
- </style>
- <!-- Theme Made By www.w3schools.com - No Copyright -->
- <title>Digicoin Transaction Page</title>
- <meta name="viewport" content="width=device-width, initial-scale=1">
- <link rel="stylesheet" href="theme/bootstrap.min.css">
- <link href="theme/css_1.css" rel="stylesheet" type="text/css">
- <link href="theme/css_2.css" rel="stylesheet" type="text/css">
- <script src="theme/jquery.min.js"></script>
- <script src="theme/bootstrap.min.js"></script>
- <style>
- body {
- font: 400 15px Lato, sans-serif;
- line-height: 1.8;
- color: #818181;
- }
- h2 {
- font-size: 24px;
- text-transform: uppercase;
- color: #303030;
- font-weight: 600;
- margin-bottom: 30px;
- }
- h4 {
- font-size: 19px;
- line-height: 1.375em;
- color: #303030;
- font-weight: 400;
- margin-bottom: 30px;
- }
- .jumbotron {
- background-color: #f4511e;
- color: #fff;
- padding: 100px 25px;
- font-family: Montserrat, sans-serif;
- }
- .container-fluid {
- padding: 60px 50px;
- }
- .bg-grey {
- background-color: #f6f6f6;
- }
- .logo-small {
- color: #f4511e;
- font-size: 50px;
- }
- .logo {
- color: #f4511e;
- font-size: 200px;
- }
- .thumbnail {
- padding: 0 0 15px 0;
- border: none;
- border-radius: 0;
- }
- .thumbnail img {
- width: 100%;
- height: 100%;
- margin-bottom: 10px;
- }
- .carousel-control.right,
- .carousel-control.left {
- background-image: none;
- color: #f4511e;
- }
- .carousel-indicators li {
- border-color: #f4511e;
- }
- .carousel-indicators li.active {
- background-color: #f4511e;
- }
- .item h4 {
- font-size: 19px;
- line-height: 1.375em;
- font-weight: 400;
- font-style: italic;
- margin: 70px 0;
- }
- .item span {
- font-style: normal;
- }
- .panel {
- border: 1px solid #f4511e;
- border-radius: 0 !important;
- transition: box-shadow 0.5s;
- }
- .panel:hover {
- box-shadow: 5px 0px 40px rgba(0, 0, 0, .2);
- }
- .panel-footer .btn:hover {
- border: 1px solid #f4511e;
- background-color: #fff !important;
- color: #f4511e;
- }
- .panel-heading {
- color: #fff !important;
- background-color: #f4511e !important;
- padding: 25px;
- border-bottom: 1px solid transparent;
- border-top-left-radius: 0px;
- border-top-right-radius: 0px;
- border-bottom-left-radius: 0px;
- border-bottom-right-radius: 0px;
- }
- .panel-footer {
- background-color: white !important;
- }
- .panel-footer h3 {
- font-size: 32px;
- }
- .panel-footer h4 {
- color: #aaa;
- font-size: 14px;
- }
- .panel-footer .btn {
- margin: 15px 0;
- background-color: #f4511e;
- color: #fff;
- }
- .navbar {
- margin-bottom: 0;
- background-color: #f4511e;
- z-index: 9999;
- border: 0;
- font-size: 12px !important;
- line-height: 1.42857143 !important;
- letter-spacing: 4px;
- border-radius: 0;
- font-family: Montserrat, sans-serif;
- }
- .navbar li a,
- .navbar .navbar-brand {
- color: #fff !important;
- }
- .navbar-nav li a:hover,
- .navbar-nav li.active a {
- color: #f4511e !important;
- background-color: #fff !important;
- }
- .navbar-default .navbar-toggle {
- border-color: transparent;
- color: #fff !important;
- }
- footer .glyphicon {
- font-size: 20px;
- margin-bottom: 20px;
- color: #f4511e;
- }
- .slideanim {
- visibility: hidden;
- }
- .slide {
- animation-name: slide;
- -webkit-animation-name: slide;
- animation-duration: 1s;
- -webkit-animation-duration: 1s;
- visibility: visible;
- }
- @keyframes slide {
- 0% {
- opacity: 0;
- transform: translateY(70%);
- }
- 100% {
- opacity: 1;
- transform: translateY(0%);
- }
- }
- @-webkit-keyframes slide {
- 0% {
- opacity: 0;
- -webkit-transform: translateY(70%);
- }
- 100% {
- opacity: 1;
- -webkit-transform: translateY(0%);
- }
- }
- @media screen and (max-width: 768px) {
- .col-sm-4 {
- text-align: center;
- margin: 25px 0;
- }
- .btn-lg {
- width: 100%;
- margin-bottom: 35px;
- }
- }
- @media screen and (max-width: 480px) {
- .logo {
- font-size: 150px;
- }
- }
- </style>
- <style type="text/css">
- .gm-style {
- font: 400 11px Roboto, Arial, sans-serif;
- text-decoration: none;
- }
- .gm-style img {
- max-width: none;
- }
- </style>
- </head>
- <body id="myPage" data-spy="scroll" data-target=".navbar" data-offset="60">
- <nav class="navbar navbar-default navbar-fixed-top">
- <div class="container">
- <div class="navbar-header">
- <button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#myNavbar">
- <span class="icon-bar"></span>
- <span class="icon-bar"></span>
- <span class="icon-bar"></span>
- </button>
- <a class="navbar-brand" href="#myPage">DIGICOIN</a>
- </div>
- <div class="collapse navbar-collapse" id="myNavbar">
- <ul class="nav navbar-nav navbar-right">
- <li class=""><a href="#transfer">TRANSFER</a></li>
- <li class=""><a href="#transpool">TRANSACTION POOL</a></li>
- <li class=""><a href="#mine">MINE</a></li>
- <li class=""><a href="#blockchain">BLOCKCHAIN</a></li>
- <li class=""><a href="#contact">CONTACT</a></li>
- </ul>
- </div>
- </div>
- </nav>
- <div class="jumbotron text-center">
- <h1>Welcome to Digicoin</h1>
- <p>Digicoin is a blockchain powered safe currency</p>
- </div>
- <!-- Container (transfer Section) -->
- <div id="transfer" class="container-fluid">
- <div class="row">
- <div class="col-sm-8">
- <h2>Transfer Digicoins</h2><br>
- <div class="row">
- <div class="col-sm-5">
- <p>Transfer From</p>
- <p style="padding-top: 12px">Transfer To</p>
- <!-- <p style="padding-top: 100px">Transfer Amount</p> -->
- </div>
- <div class="col-sm-7 slideanim slide">
- <div class="row">
- <div class="col-sm-6 form-group">
- <input class="form-control" id="username" name="name" placeholder="Name" type="text" disabled>
- </div>
- </div>
- <div class="row">
- <div class="col-sm-6 form-group">
- <select id="publickey" class="form-control">
- <option value="Select">Select</option>
- <option value="http://localhost:3001">Sunny</option>
- <option value="http://localhost:3002">Sreetej</option>
- <option value="http://localhost:3003">Taran</option>
- <option value="http://localhost:3004">Akhil</option>
- </select>
- </div>
- </div>
- <div class="row">
- <div class="form-group">
- <textarea class="form-control" id="publickeyspan" name="comments" placeholder="public-key" rows="3" style="margin-left: 15px"
- disabled></textarea>
- </div>
- </div>
- <div class="row">
- <div class="col-sm-6 form-group">
- <!-- <input class="form-control" id="noofcoins" name="noofcoins" placeholder="Amount" type="number"> -->
- </div>
- </div>
- </div>
- </div>
- <br><button class="btn btn-default btn-lg" id="transact">Vote</button>
- </div>
- <div class="col-sm-4">
- <span class="glyphicon glyphicon-send logo" style="padding-top: 100px;padding-left: 70px;"></span>
- </div>
- </div>
- </div>
- <div id="transpool" class="container-fluid bg-grey">
- <h2 class="text-center" style="margin-top: -5px">Transaction Pool</h2>
- <div class="row">
- <div class="col-sm-2">
- <span class="glyphicon glyphicon-th-list logo slideanim slide"></span>
- </div>
- <div class="col-sm-10">
- <h4>Click <button class="btn btn-default btn-lg" id="reftransact">Refresh</button> to view latest <strong>Transaction Pool</strong></h4>
- <pre id="transactionDiv">dfafdaf</pre>
- </div>
- </div>
- </div>
- <!-- Container (Portfolio Section) -->
- <div id="mine" class="container-fluid">
- <h2 class="text-center" style="margin-top: -5px">Mine</h2><br>
- <h4 class="text-center" style="margin-top: -40px">Mine all transactions</h4>
- <div class="row">
- <div class="col-sm-10">
- <h4>Click <button class="btn btn-default btn-lg" id="minetransact">Start Mining</button> to mine all transactions
- in the <strong>Transaction Pool</strong></h4>
- </div>
- <div class="col-sm-2">
- <span class="glyphicon glyphicon-cog logo slideanim slide" style="margin-top:-50px"></span>
- </div>
- </div>
- </div>
- <!-- Container (Pricing Section) -->
- <div id="blockchain" class="container-fluid bg-grey">
- <div class="text-center">
- <h2>Blockchain</h2>
- <h4 style="margin-top: -20px">Digital Ledger of all transactions</h4>
- </div>
- <div class="row">
- <div class="col-sm-2">
- <span class="glyphicon glyphicon-th logo slideanim slide" style="margin-top:-50px"></span>
- </div>
- <div class="col-sm-10">
- <h4>Click <button class="btn btn-default btn-lg" id="refblockchain">Refresh Blockchain</button> to view the
- <strong>Blockchain</strong></h4>
- <pre id="blockchaindiv"></pre>
- </div>
- </div>
- </div>
- <!-- Container (Contact Section) -->
- <div id="contact" class="container-fluid">
- <h2 class="text-center">CONTACT</h2>
- <div class="row">
- <div class="col-sm-5">
- <p>Contact us and we'll get back to you within 24 hours.</p>
- <p><span class="glyphicon glyphicon-map-marker"></span> Hyderabad, India</p>
- <p><span class="glyphicon glyphicon-phone"></span> +91 99082 35656</p>
- <p><span class="glyphicon glyphicon-envelope"></span> sandeepsinghrathod@gmail.com</p>
- </div>
- <div class="col-sm-7 slideanim slide">
- <div class="row">
- <div class="col-sm-6 form-group">
- <input class="form-control" id="name" name="name" placeholder="Name" type="text" required="">
- </div>
- <div class="col-sm-6 form-group">
- <input class="form-control" id="email" name="email" placeholder="Email" type="email" required="">
- </div>
- </div>
- <textarea class="form-control" id="comments" name="comments" placeholder="Comment" rows="5"></textarea><br>
- <div class="row">
- <div class="col-sm-12 form-group">
- <button class="btn btn-default pull-right" type="submit">Send</button>
- </div>
- </div>
- </div>
- </div>
- </div>
- <footer class="container-fluid text-center">
- <a href="#myPage" title="To Top">
- <span class="glyphicon glyphicon-chevron-up"></span>
- </a>
- </footer>
- <script>
- var userNameArray = {
- "3001": "Sunny",
- "3002": "Sreetej",
- "3003": "Taran"
- };
- $(document).ready(function () {
- $("#username").val(userNameArray[document.location.port]);
- $("#publickey").change(function () {
- var urlPubKey = $("#publickey option:selected").val()
- if (urlPubKey !== "Select") {
- $.get(urlPubKey + "/public-key", function (data, status) {
- $("#publickeyspan").val(data.publicKey);
- });
- } else {
- $("#publickeyspan").val('');
- }
- })
- $("#reftransact").click(function () {
- $.get("/transaction", function (data, status) {
- $("#transactionDiv").html(JSON.stringify(data, null, 4));
- });
- });
- $("#transact").click(function () {
- var transactObj = {};
- transactObj.recipient = $("#publickeyspan").val();
- // transactObj.amount = parseInt($("#noofcoins").val());
- transactObj.amount = 1;
- //alert(JSON.stringify(transactObj));
- var settings = {
- "async": true,
- "crossDomain": true,
- "url": "/transact",
- "method": "POST",
- "headers": {
- "Content-Type": "application/json",
- "Cache-Control": "no-cache",
- },
- "processData": false,
- "data": JSON.stringify(transactObj)
- }
- $.ajax(settings).done(function (response) {
- $("#transactionDiv").html(JSON.stringify(response, null, 4));
- scrollToAnchor("transpool");
- });
- });
- $("#refblockchain").click(function () {
- $.get("/block", function (data, status) {
- $("#blockchaindiv").html(JSON.stringify(data, null, 4));
- });
- });
- $("#minetransact").click(function () {
- $.get("/mine-transactions", function (data, status) {
- $("#blockchaindiv").html(JSON.stringify(data, null, 4));
- scrollToAnchor("blockchain");
- });
- });
- function scrollToAnchor(aid) {
- var aTag = $("div[id='" + aid + "']");
- $('html,body').animate({
- scrollTop: aTag.offset().top
- }, 'slow');
- }
- // Add smooth scrolling to all links in navbar + footer link
- $(".navbar a, footer a[href='#myPage']").on('click', function (event) {
- // Prevent default anchor click behavior
- event.preventDefault();
- // Store hash
- var hash = this.hash;
- // Using jQuery's animate() method to add smooth page scroll
- // The optional number (900) specifies the number of milliseconds it takes to scroll to the specified area
- $('html, body').animate({
- scrollTop: $(hash).offset().top
- }, 900, function () {
- // Add hash (#) to URL when done scrolling (default click behavior)
- window.location.hash = hash;
- });
- });
- // Slide in elements on scroll
- $(window).scroll(function () {
- $(".slideanim").each(function () {
- var pos = $(this).offset().top;
- var winTop = $(window).scrollTop();
- if (pos < winTop + 600) {
- $(this).addClass("slide");
- }
- });
- });
- })
- </script>
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement