added a main id so central section can be styled
This commit is contained in:
+46
-44
@@ -1,47 +1,49 @@
|
|||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html lang="<%= config.charset %>">
|
<html lang="<%= config.charset %>">
|
||||||
<head>
|
<head>
|
||||||
<%- include("../partials/head") %>
|
<%- include("../partials/head") %>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
Misc:<br/>
|
<div id="main">
|
||||||
<a href="<%= config.site_path %>/">Home Page</a><br/>
|
Misc:<br/>
|
||||||
<a href="<%= config.site_path %><%= config.new_post_url %>">New Post Form</a><br/>
|
<a href="<%= config.site_path %>/">Home Page</a><br/>
|
||||||
<a href="<%= config.site_path %><%= config.signup_url %>">Signup Form</a><br/>
|
<a href="<%= config.site_path %><%= config.new_post_url %>">New Post Form</a><br/>
|
||||||
Indexes:<br/>
|
<a href="<%= config.site_path %><%= config.signup_url %>">Signup Form</a><br/>
|
||||||
<a href="<%= config.site_path %>/index/posts">Posts Index</a><br/>
|
Indexes:<br/>
|
||||||
<a href="<%= config.site_path %>/index/users">Users Index</a><br/>
|
<a href="<%= config.site_path %>/index/posts">Posts Index</a><br/>
|
||||||
<a href="<%= config.site_path %>/index/comments">Comments Index</a><br/>
|
<a href="<%= config.site_path %>/index/users">Users Index</a><br/>
|
||||||
Posts:<br/>
|
<a href="<%= config.site_path %>/index/comments">Comments Index</a><br/>
|
||||||
<% for (let postID = 0; postID < posts.length; postID++) { %>
|
Posts:<br/>
|
||||||
<% if (posts[postID]["deleted"] != true) { %>
|
<% for (let postID = 0; postID < posts.length; postID++) { %>
|
||||||
<a href="<%= config.site_path %>/post/<%= postID %>"><%= posts[postID]["title"] %></a><br/>
|
<% if (posts[postID]["deleted"] != true) { %>
|
||||||
<% }; %>
|
<a href="<%= config.site_path %>/post/<%= postID %>"><%= posts[postID]["title"] %></a><br/>
|
||||||
<% }; %>
|
<% }; %>
|
||||||
Comments:<br/>
|
<% }; %>
|
||||||
<% for (let postID = 0; postID < comments.length; postID++) { %>
|
Comments:<br/>
|
||||||
<% for (let comment_index = 0; comment_index < comments[postID]['comments'].length; comment_index++) { %>
|
<% for (let postID = 0; postID < comments.length; postID++) { %>
|
||||||
<a href="<%= config.site_path %>/comment/<%= postID %>-<%= comment_index %>"><%= postID %>-<%= comment_index %></a><br/>
|
<% for (let comment_index = 0; comment_index < comments[postID]['comments'].length; comment_index++) { %>
|
||||||
<% }; %>
|
<a href="<%= config.site_path %>/comment/<%= postID %>-<%= comment_index %>"><%= postID %>-<%= comment_index %></a><br/>
|
||||||
<% }; %>
|
<% }; %>
|
||||||
Users:<br/>
|
<% }; %>
|
||||||
<% for (let userID = 0; userID < users.length; userID++) { %>
|
Users:<br/>
|
||||||
<% if (users[userID]["deleted"] != true) { %>
|
<% for (let userID = 0; userID < users.length; userID++) { %>
|
||||||
<a href="<%= config.site_path %>/user/<%= users[userID]["username"] %>"><%= users[userID]["username"] %></a><br/>
|
<% if (users[userID]["deleted"] != true) { %>
|
||||||
<% }; %>
|
<a href="<%= config.site_path %>/user/<%= users[userID]["username"] %>"><%= users[userID]["username"] %></a><br/>
|
||||||
<% }; %>
|
<% }; %>
|
||||||
Edit Posts:<br/>
|
<% }; %>
|
||||||
<% for (let postID = 0; postID < posts.length; postID++) { %>
|
Edit Posts:<br/>
|
||||||
<% if (posts[postID]["deleted"] != true) { %>
|
<% for (let postID = 0; postID < posts.length; postID++) { %>
|
||||||
<a href="<%= config.site_path %><%= config.edit_post_base_url %>/<%= postID %>">Edit <%= posts[postID]["title"] %></a><br/>
|
<% if (posts[postID]["deleted"] != true) { %>
|
||||||
<% }; %>
|
<a href="<%= config.site_path %><%= config.edit_post_base_url %>/<%= postID %>">Edit <%= posts[postID]["title"] %></a><br/>
|
||||||
<% }; %>
|
<% }; %>
|
||||||
Edit Users:<br/>
|
<% }; %>
|
||||||
<% for (let userID = 0; userID < users.length; userID++) { %>
|
Edit Users:<br/>
|
||||||
<% if (users[userID]["deleted"] != true) { %>
|
<% for (let userID = 0; userID < users.length; userID++) { %>
|
||||||
<a href="<%= config.site_path %><%= config.edit_account_base_url %>/<%= users[userID]["username"] %>">Edit <%= users[userID]["username"] %></a><br/>
|
<% if (users[userID]["deleted"] != true) { %>
|
||||||
<% }; %>
|
<a href="<%= config.site_path %><%= config.edit_account_base_url %>/<%= users[userID]["username"] %>">Edit <%= users[userID]["username"] %></a><br/>
|
||||||
<% }; %>
|
<% }; %>
|
||||||
<!-- TODO add tags -->
|
<% }; %>
|
||||||
</body>
|
<!-- TODO add tags -->
|
||||||
|
</div>
|
||||||
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
|||||||
+12
-10
@@ -1,13 +1,15 @@
|
|||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html lang="<%= config.charset %>">
|
<html lang="<%= config.charset %>">
|
||||||
<head>
|
<head>
|
||||||
<%- include("../partials/head") %>
|
<%- include("../partials/head") %>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<% for (let postID = 0; postID < comments.length; postID++) { %>
|
<div id="main">
|
||||||
<% for (let comment_index = 0; comment_index < comments[postID]['comments'].length; comment_index++) { %>
|
<% for (let postID = 0; postID < comments.length; postID++) { %>
|
||||||
<a href="<%= config.site_path %>/comment/<%= postID %>-<%= comment_index %>"><%= postID %>-<%= comment_index %></a><br/>
|
<% for (let comment_index = 0; comment_index < comments[postID]['comments'].length; comment_index++) { %>
|
||||||
<% }; %>
|
<a href="<%= config.site_path %>/comment/<%= postID %>-<%= comment_index %>"><%= postID %>-<%= comment_index %></a><br/>
|
||||||
<% }; %>
|
<% }; %>
|
||||||
</body>
|
<% }; %>
|
||||||
|
</div>
|
||||||
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
|||||||
+12
-10
@@ -1,13 +1,15 @@
|
|||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html lang="<%= config.charset %>">
|
<html lang="<%= config.charset %>">
|
||||||
<head>
|
<head>
|
||||||
<%- include("../partials/head") %>
|
<%- include("../partials/head") %>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<% for (let postID = 0; postID < posts.length; postID++) { %>
|
<div id="main">
|
||||||
<% if (posts[postID]["deleted"] != true) { %>
|
<% for (let postID = 0; postID < posts.length; postID++) { %>
|
||||||
<a href="<%= config.site_path %>/post/<%= postID %>"><%= posts[postID]["title"] %></a><br/>
|
<% if (posts[postID]["deleted"] != true) { %>
|
||||||
<% }; %>
|
<a href="<%= config.site_path %>/post/<%= postID %>"><%= posts[postID]["title"] %></a><br/>
|
||||||
<% }; %>
|
<% }; %>
|
||||||
</body>
|
<% }; %>
|
||||||
|
</div>
|
||||||
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
|||||||
+12
-10
@@ -1,13 +1,15 @@
|
|||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html lang="<%= config.charset %>">
|
<html lang="<%= config.charset %>">
|
||||||
<head>
|
<head>
|
||||||
<%- include("../partials/head") %>
|
<%- include("../partials/head") %>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<% for (let userID = 0; userID < users.length; userID++) { %>
|
<div id="main">
|
||||||
<% if (users[userID]["deleted"] != true) { %>
|
<% for (let userID = 0; userID < users.length; userID++) { %>
|
||||||
<a href="<%= config.site_path %>/user/<%= users[userID]["username"] %>"><%= users[userID]["username"] %></a><br/>
|
<% if (users[userID]["deleted"] != true) { %>
|
||||||
<% }; %>
|
<a href="<%= config.site_path %>/user/<%= users[userID]["username"] %>"><%= users[userID]["username"] %></a><br/>
|
||||||
<% }; %>
|
<% }; %>
|
||||||
</body>
|
<% }; %>
|
||||||
|
</div>
|
||||||
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
|||||||
+25
-23
@@ -1,26 +1,28 @@
|
|||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html lang="en">
|
<html lang="en">
|
||||||
<head>
|
<head>
|
||||||
<%- include('../partials/head'); %>
|
<%- include('../partials/head'); %>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<header id="site-header">
|
<div id="main">
|
||||||
<%- include("../headers/site_wide") %>
|
<header id="site-header">
|
||||||
</header>
|
<%- include("../headers/site_wide") %>
|
||||||
<div id="comment">
|
</header>
|
||||||
<%- include("../partials/comment"); %>
|
<div id="comment">
|
||||||
</div>
|
<%- include("../partials/comment"); %>
|
||||||
<%- config.seperator %>
|
</div>
|
||||||
<b><%= locale.reply %>:</b>
|
<%- config.seperator %>
|
||||||
<div id="post-commentform">
|
<b><%= locale.reply %>:</b>
|
||||||
<!-- Comment form -->
|
<div id="post-commentform">
|
||||||
<form method="POST" action="/submit_comment">
|
<!-- Comment form -->
|
||||||
<input type="hidden" name="post_index" value="<%= postID %>">
|
<form method="POST" action="/submit_comment">
|
||||||
<label><%= locale.username %>:</label><br/><input name="name"><br/><br/>
|
<input type="hidden" name="post_index" value="<%= postID %>">
|
||||||
<label><%= locale.comment %>:</label><br/><textarea name="content">>> <%- postID %>-<%- commentID %>
|
<label><%= locale.username %>:</label><br/><input name="name"><br/><br/>
|
||||||
</textarea><br/>
|
<label><%= locale.comment %>:</label><br/><textarea name="content">>> <%- postID %>-<%- commentID %>
|
||||||
<button type="submit"><%= locale.submit %></button>
|
</textarea><br/>
|
||||||
</form>
|
<button type="submit"><%= locale.submit %></button>
|
||||||
</div>
|
</form>
|
||||||
</body>
|
</div>
|
||||||
|
</div>
|
||||||
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
|||||||
+16
-14
@@ -1,17 +1,19 @@
|
|||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html lang="en">
|
<html lang="en">
|
||||||
<head>
|
<head>
|
||||||
<%- include('../partials/head'); %>
|
<%- include('../partials/head'); %>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<header id="site-header">
|
<div id="main">
|
||||||
<%- include("../headers/site_wide") %>
|
<header id="site-header">
|
||||||
</header>
|
<%- include("../headers/site_wide") %>
|
||||||
<div id="posts">
|
</header>
|
||||||
<%- include('../posts/post'); %>
|
<div id="posts">
|
||||||
</div>
|
<%- include('../posts/post'); %>
|
||||||
<footer id='footer'>
|
</div>
|
||||||
<%- include('../partials/footer'); %>
|
<footer id='footer'>
|
||||||
</footer>
|
<%- include('../partials/footer'); %>
|
||||||
</body>
|
</footer>
|
||||||
|
</div>
|
||||||
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
|||||||
+25
-23
@@ -4,34 +4,36 @@
|
|||||||
<%- include('../partials/head'); %>
|
<%- include('../partials/head'); %>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<div id='site-header'>
|
<div id="main">
|
||||||
<%- include('../headers/site_wide'); %>
|
<div id='site-header'>
|
||||||
</div>
|
<%- include('../headers/site_wide'); %>
|
||||||
|
</div>
|
||||||
|
|
||||||
<div id='advanced-search'>
|
<div id='advanced-search'>
|
||||||
<form method="GET" action="/search">
|
<form method="GET" action="/search">
|
||||||
<label>Search Term:</label>
|
<label>Search Term:</label>
|
||||||
<input type='text' placeholder='🔍' name='q' value='<%- search_term %>'><br/>
|
<input type='text' placeholder='🔍' name='q' value='<%- search_term %>'><br/>
|
||||||
|
|
||||||
<label>Search for:</label><br/>
|
<label>Search for:</label><br/>
|
||||||
<label>Post:</label>
|
<label>Post:</label>
|
||||||
<input type="checkbox" name="type" value="post" <% if (search_type.includes('post')) {%>checked<% } %>><br/>
|
<input type="checkbox" name="type" value="post" <% if (search_type.includes('post')) {%>checked<% } %>><br/>
|
||||||
<label>User:</label>
|
<label>User:</label>
|
||||||
<input type="checkbox" name="type" value="user" <% if (search_type.includes('user')) {%>checked<% } %>><br/>
|
<input type="checkbox" name="type" value="user" <% if (search_type.includes('user')) {%>checked<% } %>><br/>
|
||||||
|
|
||||||
<input type="submit" value="Submit">
|
<input type="submit" value="Submit">
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<%- config.seperator %>
|
<%- config.seperator %>
|
||||||
|
|
||||||
<div id='results'>
|
<div id='results'>
|
||||||
<% search_results.posts.forEach((result, index) => { %>
|
<% search_results.posts.forEach((result, index) => { %>
|
||||||
<a href="/post/<%- result.id %>"><%- result.title %></a><br/>
|
<a href="/post/<%- result.id %>"><%- result.title %></a><br/>
|
||||||
<% }); %>
|
<% }); %>
|
||||||
<% search_results.users.forEach((result, index) => { %>
|
<% search_results.users.forEach((result, index) => { %>
|
||||||
<a href="/user/<%- result.username %>"><%- result.prettyname %></a><br/>
|
<a href="/user/<%- result.username %>"><%- result.prettyname %></a><br/>
|
||||||
<% }); %>
|
<% }); %>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
|||||||
+27
-25
@@ -1,28 +1,30 @@
|
|||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html lang="en">
|
<html lang="en">
|
||||||
<head>
|
<head>
|
||||||
<%- include('../partials/head'); %>
|
<%- include('../partials/head'); %>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<header id="site-header">
|
<div id="main">
|
||||||
<%- include('../headers/site_wide'); %>
|
<header id="site-header">
|
||||||
</header>
|
<%- include('../headers/site_wide'); %>
|
||||||
<header id='page-header'>
|
</header>
|
||||||
<%- include('../headers/tag'); %>
|
<header id='page-header'>
|
||||||
</header>
|
<%- include('../headers/tag'); %>
|
||||||
<div id="posts">
|
</header>
|
||||||
<% for (let index = posts.length - 1; index >= 0; index--) { %>
|
<div id="posts">
|
||||||
<% if ( posts[index].deleted != true) { %>
|
<% for (let index = posts.length - 1; index >= 0; index--) { %>
|
||||||
<% posts[index].tags.forEach((current_tag, tag_index) => { %>
|
<% if ( posts[index].deleted != true) { %>
|
||||||
<% if (current_tag.toLowerCase() == tag.toLowerCase()) { %>
|
<% posts[index].tags.forEach((current_tag, tag_index) => { %>
|
||||||
<%- include('../posts/tag', {post: posts[index], postID: index, user: users[posts[index].userID], comments: comments[index]}); %>
|
<% if (current_tag.toLowerCase() == tag.toLowerCase()) { %>
|
||||||
<% } %>
|
<%- include('../posts/tag', {post: posts[index], postID: index, user: users[posts[index].userID], comments: comments[index]}); %>
|
||||||
<% }) %>
|
<% } %>
|
||||||
<% } %>
|
<% }) %>
|
||||||
<% } %>
|
<% } %>
|
||||||
</div>
|
<% } %>
|
||||||
<footer id='footer'>
|
</div>
|
||||||
<%- include('../partials/footer'); %>
|
<footer id='footer'>
|
||||||
</footer>
|
<%- include('../partials/footer'); %>
|
||||||
</body>
|
</footer>
|
||||||
|
</div>
|
||||||
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
|||||||
+23
-21
@@ -1,24 +1,26 @@
|
|||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html lang="en">
|
<html lang="en">
|
||||||
<head>
|
<head>
|
||||||
<%- include('../partials/head'); %>
|
<%- include('../partials/head'); %>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<header id="site-header">
|
<div id="main">
|
||||||
<%- include("../headers/site_wide") %>
|
<header id="site-header">
|
||||||
</header>
|
<%- include("../headers/site_wide") %>
|
||||||
<header id='page-header'>
|
</header>
|
||||||
<%- include('../headers/timeline'); %>
|
<header id='page-header'>
|
||||||
</header>
|
<%- include('../headers/timeline'); %>
|
||||||
<div id="posts">
|
</header>
|
||||||
<% for (let index = posts.length - 1; index >= 0; index--) { %>
|
<div id="posts">
|
||||||
<% if (posts[index]["deleted"] != true) { %>
|
<% for (let index = posts.length - 1; index >= 0; index--) { %>
|
||||||
<%- include('../posts/timeline', {post: posts[index], postID: index, user: users[posts[index].userID], comments: comments[index]}); %>
|
<% if (posts[index]["deleted"] != true) { %>
|
||||||
<% } %>
|
<%- include('../posts/timeline', {post: posts[index], postID: index, user: users[posts[index].userID], comments: comments[index]}); %>
|
||||||
<% } %>
|
<% } %>
|
||||||
</div>
|
<% } %>
|
||||||
<footer id='footer'>
|
</div>
|
||||||
<%- include('../partials/footer'); %>
|
<footer id='footer'>
|
||||||
</footer>
|
<%- include('../partials/footer'); %>
|
||||||
</body>
|
</footer>
|
||||||
|
</div>
|
||||||
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
|||||||
+23
-21
@@ -1,24 +1,26 @@
|
|||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html lang="en">
|
<html lang="en">
|
||||||
<head>
|
<head>
|
||||||
<%- include('../partials/head'); %>
|
<%- include('../partials/head'); %>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<header id="site-header">
|
<div id="main">
|
||||||
<%- include("../headers/site_wide") %>
|
<header id="site-header">
|
||||||
</header>
|
<%- include("../headers/site_wide") %>
|
||||||
<header id='page-header'>
|
</header>
|
||||||
<%- include('../headers/user'); %>
|
<header id='page-header'>
|
||||||
</header>
|
<%- include('../headers/user'); %>
|
||||||
<div id="posts">
|
</header>
|
||||||
<% for (let index = posts.length - 1; index >= 0; index--) { %>
|
<div id="posts">
|
||||||
<% if (posts[index].userID == userID) { %>
|
<% for (let index = posts.length - 1; index >= 0; index--) { %>
|
||||||
<%- include('../posts/user', {post: posts[index], postID: index, user: user, comments: comments[index]}); %>
|
<% if (posts[index].userID == userID) { %>
|
||||||
<% } %>
|
<%- include('../posts/user', {post: posts[index], postID: index, user: user, comments: comments[index]}); %>
|
||||||
<% } %>
|
<% } %>
|
||||||
</div>
|
<% } %>
|
||||||
<footer id='footer'>
|
</div>
|
||||||
<%- include('../partials/footer'); %>
|
<footer id='footer'>
|
||||||
</footer>
|
<%- include('../partials/footer'); %>
|
||||||
</body>
|
</footer>
|
||||||
|
</div>
|
||||||
|
</body>
|
||||||
</html>
|
</html>
|
||||||
|
|||||||
@@ -0,0 +1,22 @@
|
|||||||
|
<?xml version="1.0" encoding="<%= config.charset %>" ?>
|
||||||
|
<rss version="2.0">
|
||||||
|
<channel>
|
||||||
|
<title><%= config.site_name %></title>
|
||||||
|
<link><%= config.site_url %></title>
|
||||||
|
<description><%= config.site_description %></description>
|
||||||
|
<% for (let postID = posts.length-1; postID >= 0; postID--) { %>
|
||||||
|
<% if (posts[postID]["deleted"] != true) { %>
|
||||||
|
<item>
|
||||||
|
<title><%= posts[postID]["title"] %></title>
|
||||||
|
<link><%= config.site_url %>/post/<%= postID %></link>
|
||||||
|
<description><![CDATA[<%- func.render_md(posts[postID]["content"]) %>]]></description>
|
||||||
|
<guid isPermaLink="true"><%= config.site_url %>/post/<%= postID %></guid>
|
||||||
|
<pubDate><%= func.unix_time_to_rss_date(posts[postID]['pubdate']) %></pubDate>
|
||||||
|
<% for (let tag_index = 0; tag_index < posts[postID]['tags'].length; tag_index++) { %>
|
||||||
|
<category><![CDATA[<%= posts[postID]['tags'][tag_index] %>]]></category>
|
||||||
|
<% } %>
|
||||||
|
</item>
|
||||||
|
<% } %>
|
||||||
|
<% } %>
|
||||||
|
</channel>
|
||||||
|
</rss>
|
||||||
Reference in New Issue
Block a user