Include signup form

main
Keir Finlow-Bates 2 years ago
parent 8c32b48610
commit 5c9a45c261

1
.gitignore vendored

@ -10,6 +10,7 @@ yarn-debug.log*
yarn-error.log*
lerna-debug.log*
.pnpm-debug.log*
database.txt
# Diagnostic reports (https://nodejs.org/api/report.html)
report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json

@ -1828,7 +1828,7 @@ input, select, textarea {
-webkit-appearance: none;
-ms-appearance: none;
appearance: none;
background: #f7f7f7;
background: #dddddd;
border-radius: 0.35em;
border: solid 2px transparent;
color: inherit;
@ -2565,19 +2565,19 @@ input, select, textarea {
-webkit-transition: background-color 0.2s ease-in-out, color 0.2s ease-in-out, border-color 0.2s ease-in-out;
-ms-transition: background-color 0.2s ease-in-out, color 0.2s ease-in-out, border-color 0.2s ease-in-out;
transition: background-color 0.2s ease-in-out, color 0.2s ease-in-out, border-color 0.2s ease-in-out;
background-color: transparent;
background-color: #c49393;
border-radius: 0.35em;
border: solid 3px #efefef;
color: #787878 !important;
border: solid 3px #c49393;
color: #e7e7e7 !important;
cursor: pointer;
display: inline-block;
font-weight: 400;
height: 3.15em;
height: calc(2.75em + 6px);
height: 2.75em;
line-height: 2.75em;
min-width: 10em;
padding: 0 1.5em;
text-align: center;
text-align: top;
text-decoration: none;
white-space: nowrap;
}
@ -2816,8 +2816,6 @@ input, select, textarea {
#main > section {
border-top: solid 2px #efefef;
margin: 4em 0 0 0;
padding: 4em 0 0 0;
}
#main > section:first-child {

@ -24,14 +24,31 @@
<!-- Main -->
<div id="main">
<!-- Zero -->
<section id="zero">
<p>Join my mailing list to receive notifications for promotions and new books.</p>
<form method="post" action="/subscribe">
<div class="row">
<div class="col-8 col-12-small">
<div class="row gtr-uniform gtr-50">
<div class="col-6 col-12-xsmall"><input type="text" name="name" id="name" placeholder="Name" /></div>
<div class="col-6 col-12-xsmall"><input type="email" name="email" id="email" placeholder="Email" /></div>
</div>
</div>
<div class="col-4 col-12-small">
<ul class="actions"><li><input type="submit" value="Sign up" /></li></ul>
</div>
</div>
</form>
</section>
<!-- One -->
<section id="one">
<header class="major">
<h2>About Keir</h2>
</header>
<p>I spend a lot of time researching and thinking about blockchain, often while walking through the Finnish woods. And then, every now and again, I find myself compelled to write a book about what I've discovered.</p>
</p>
</section>
<!-- Two -->
@ -51,7 +68,7 @@
<h4>Evil Tokenomics</h4>
<a href="https://mybook.to/eviltokenomics" src="images/thumbs/02.jpg" class="image fit thumb"><img src="images/thumbs/02.jpg" alt="" /></a>
<p><a href="https://mybook.to/eviltokenomics">Buy a copy: eBook, hardback or paperback</a></p>
<p>Ever wondered how crypto-scammers use tokenomics to manipulate us? Read this book, in which a fictional criminal mastermind explains how he fools both the buying public, project founders, and investors to steal your hard-earned cash using all sorts of psychological and economic tricks.</p>
<p>Ever wondered how crypto-scammers use tokenomics to manipulate us? Read this book, in which a fictional criminal mastermind explains how he fools both the buying public, project founders, and even investors to steal your hard-earned cash using all sorts of psychological and economic tricks.</p>
</article>
<article class="col-6 col-12-xsmall work-item">
<h4>How To Build A Brand On LinkedIn</h4>
@ -69,7 +86,7 @@
</section>
<!-- Three -->
<section id="two">
<section id="three">
<header class="major">
<h2>The Merchandise</h2>
<p>Prices shown are estimates and may differ depending on your shipping destination</p>

@ -0,0 +1,123 @@
<!DOCTYPE HTML>
<html>
<head>
<title>Thinklair Publishing</title>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no" />
<link rel="stylesheet" href="assets/css/main.css" />
<link rel="icon" type="image/x-icon" href="images/favicon.png">
</head>
<body class="is-preload">
<!-- Header -->
<header id="header">
<div class="inner">
<a href="#" class="image avatar"><img src="images/avatar.jpg" alt="" /></a>
<h1><strong>Thinklair Publishing : </strong><br />
Books by Keir Finlow-Bates<br />
(BlockchainGandalf)
</h1>
</div>
</header>
<!-- Main -->
<div id="main">
<!-- Zero -->
<section id="zero">
<p>Thank you for subscribing!</p>
</section>
<!-- One -->
<section id="one">
<header class="major">
<h2>About Keir</h2>
</header>
<p>I spend a lot of time researching and thinking about blockchain, often while walking through the Finnish woods. And then, every now and again, I find myself compelled to write a book about what I've discovered.</p>
</section>
<!-- Two -->
<section id="two">
<header class="major">
<h2>The Books</h2>
</header>
<div class="row">
<article class="col-6 col-12-xsmall work-item">
<h4>Move Over Brokers Here Comes The Blockchain</h4>
<a href="https://mybook.to/moveover" src="images/thumbs/01.jpg" class="image fit thumb"><img src="images/thumbs/01.jpg" alt="" /></a>
<p><a href="https://mybook.to/moveover">Buy a copy: eBook, hardback or paperback</a></p>
<p>BIBA award winner. An in-depth explanation of blockchain using simple analogies, this book covers everything from the technology that drives blockchain, through to economic, sociological and even philosophical examinations of why blockchain is significant.</p>
</article>
<article class="col-6 col-12-xsmall work-item">
<h4>Evil Tokenomics</h4>
<a href="https://mybook.to/eviltokenomics" src="images/thumbs/02.jpg" class="image fit thumb"><img src="images/thumbs/02.jpg" alt="" /></a>
<p><a href="https://mybook.to/eviltokenomics">Buy a copy: eBook, hardback or paperback</a></p>
<p>Ever wondered how crypto-scammers use tokenomics to manipulate us? Read this book, in which a fictional criminal mastermind explains how he fools both the buying public, project founders, and even investors to steal your hard-earned cash using all sorts of psychological and economic tricks.</p>
</article>
<article class="col-6 col-12-xsmall work-item">
<h4>How To Build A Brand On LinkedIn</h4>
<a href="https://mybook.to/personalbrand" src="images/thumbs/03.jpg" class="image fit thumb"><img src="images/thumbs/03.jpg" alt="" /></a>
<p><a href="https://mybook.to/personalbrand">Buy a copy: paperback or eBook</a></p>
<p>This is a cheap, short, and simple primer to improve your presence on social media, focussing on LinkedIn in particular. The book provides not just hints and tips on the algorithm, but also advice on how to write posts, articles, and record short videos.</p>
</article>
<article class="col-6 col-12-xsmall work-item">
<h4>Scansatevi Brokers: Arriva La Blockchain</h4>
<a href="https://mybook.to/scansatevi" src="images/thumbs/04.jpg" class="image fit thumb"><img src="images/thumbs/04.jpg" alt="" /></a>
<p><a href="https://mybook.to/personalbrand">Acquistane una copia: ebook, copertina rigida o tascabile</a></p>
<p>L'edizione italiana del classico blockchain.</p>
</article>
</div>
</section>
<!-- Three -->
<section id="three">
<header class="major">
<h2>The Merchandise</h2>
<p>Prices shown are estimates and may differ depending on your shipping destination</p>
</header>
<div class="row">
<article class="col-12 col-12-xsmall work-item">
<h4>Move Over Brokers Clothing</h4>
<a href="https://www.etsy.com/fi-en/shop/Thinklair?ref=seller-platform-mcnav&section_id=42944994&sort_order=price_desc"
src="images/thumbs/t2.jpg"
class="image2 fit thumb">
<img src="images/thumbs/t2.jpg" alt="" />
</a>
</article>
<article class="col-12 col-12-xsmall work-item">
<h4>Evil Tokenomics Clothing</h4>
<a href="https://www.etsy.com/fi-en/shop/Thinklair?ref=seller-platform-mcnav&section_id=42956469&sort_order=price_desc" src="images/thumbs/t1.jpg" class="image2 fit thumb"><img src="images/thumbs/t1.jpg" alt="" /></a>
</article>
<article class="col-12 col-12-xsmall work-item">
<h4>The Orthoverse Clothing</h4>
<a href="https://www.etsy.com/fi-en/shop/Thinklair?ref=seller-platform-mcnav&section_id=42956477&sort_order=price_desc" src="images/thumbs/t3.jpg" class="image2 fit thumb"><img src="images/thumbs/t3.jpg" alt="" /></a>
</article>
</div>
</section>
</div>
<!-- Footer -->
<footer id="footer">
<div class="inner">
<ul class="icons">
<li><a href="https://twitter.com/bcgandalf" class="icon brands fa-twitter"><span class="label">Twitter</span></a></li>
<li><a href="https://github.com/kf106" class="icon brands fa-github"><span class="label">Github</span></a></li>
<li><a href="https://www.linkedin.com/in/keirf/" class="icon brands fa-linkedin"><span class="label">LinkedIn</span></a></li>
<li><a href="mailto:keir@chainfrog.com" class="icon solid fa-envelope"><span class="label">Email</span></a></li>
</ul>
</div>
</footer>
<!-- Scripts -->
<script src="assets/js/jquery.min.js"></script>
<script src="assets/js/browser.min.js"></script>
<script src="assets/js/breakpoints.min.js"></script>
<script src="assets/js/util.js"></script>
<script src="assets/js/main.js"></script>
</body>
</html>

@ -1,16 +1,28 @@
const express = require("express")
const fs = require('fs')
const bodyParser = require('body-parser')
const app = express()
const PORT = process.env.PORT || 8997
app.use(express.static("public"))
app.use(express.json())
app.use(bodyParser.urlencoded({ extended: true }))
app.post('/', function requestHandler(req,res) {
fs.appendFile('./database.txt', req.body.toString() + "\n")
}
app.post('/subscribe', (req, res) => {
const name = req.body.name
const email = req.body.email
fs.appendFile('./database.txt', name + ";" + email + "\n", (err) => {
if (err) {
console.log(err);
}
else {
// Get the file contents after the append operation
console.log("\nFile Contents of file after append:\n",
fs.readFileSync("./database.txt", "utf8"));
}
})
res.redirect('/subscribed.html')
})
app.listen(PORT, () => {
console.log(`Server is running on port ${PORT}`);

Loading…
Cancel
Save