1
0
mirror of https://github.com/mgerb/mywebsite synced 2026-01-11 18:32:50 +00:00

working on post upload

This commit is contained in:
2015-10-19 09:08:02 -05:00
parent 245cef5d2a
commit 184abc8ac1
3 changed files with 90 additions and 0 deletions

43
views/newpost.ejs Normal file
View File

@@ -0,0 +1,43 @@
<% include layout.ejs %>
<body>
<div class="header">
</div>
<div class="container">
<form action="/newpost" method="post" enctype="multipart/form-data" class="form-signin">
<h2 class="form-signin-heading text-center">Submit New Post</h2>
<input type="text" class="form-control" name="title" placeholder="Title" required autofocus>
<br>
<input type="text" class="form-control" name="date" placeholder="Date" required>
<br>
<textarea type="text" class="form-control" name="intro" placeholder="Intro"></textarea>
<br>
<input type="text" class="form-control" namel="key" placeholder="Key" required>
<%
if (typeof message != 'undefined'){ %>
<span class="text-center colorRed"><%=message%></span>
<%}%>
<br>
<span class="btn btn-default btn-file">
Browse<input type="file" name="file">
</span>
<br>
<br>
<button class="btn btn-lg btn-primary btn-block" type="submit">Sign in</button>
</form>
</div>
</body>
<% include layoutBottom.ejs %>