Init
This commit is contained in:
75
res/template/account/files.html
Normal file
75
res/template/account/files.html
Normal file
@@ -0,0 +1,75 @@
|
||||
<!DOCTYPE html>
|
||||
<html xmlns:th="http://www.thymeleaf.org">
|
||||
<head>
|
||||
<title>File Browser ~ PixelDrain</title>
|
||||
<meta charset="UTF-8"/>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0"/>
|
||||
<link rel="stylesheet" href="/res/style/home.css"/>
|
||||
<link rel="stylesheet" href="/res/style/season.css"/>
|
||||
<link rel="stylesheet" href="/res/style/history.css"/>
|
||||
<link rel="stylesheet" href="/res/style/menu.css"/>
|
||||
<link href='https://fonts.googleapis.com/css?family=Ubuntu' rel='stylesheet' type='text/css'/>
|
||||
<link href="https://fonts.googleapis.com/css?family=Lato:100" rel="stylesheet" type="text/css"/>
|
||||
<link rel="shortcut icon" href="/res/img/tray32.png"/>
|
||||
<meta name="theme-color" content="#9FCF6C"/>
|
||||
<link rel="icon" sizes="180x180" href="/res/img/pixeldrain.png"/>
|
||||
<link rel="icon" sizes="256x256" href="/res/img/pixeldrain_big.png"/>
|
||||
|
||||
<style th:include="fragments :: background-pattern" th:inline="text"></style>
|
||||
|
||||
<meta name="description" content="PixelDrain is a free file sharing service, you
|
||||
can upload any file and you will be given a shareable link right away.
|
||||
PixelDrain also supports previews for images, videos, audio, PDFs and much more.
|
||||
Uncensored, unmonitored and unmoderated."/>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div id='body' class="body">
|
||||
<div th:replace="fragments :: menu"></div>
|
||||
<br/>
|
||||
|
||||
<div style="margin-left: 0; margin-right: 0; text-align: center; font-size: 22px;">
|
||||
<a th:href="'/account/files?pageid=' + ${pageid - 1}">Previous</a>
|
||||
<-- <span th:text="${pageid}">0</span> -->
|
||||
<a th:href="'/account/files?pageid=' + ${pageid + 1}">Nextious</a>
|
||||
</div>
|
||||
|
||||
<div id="uploadedFiles" class="uploadedFiles">
|
||||
<div class="uploadItem" th:each="file,interation : ${files}">
|
||||
<a th:href="'/u/' + ${file.getId()}" th:inline="text" target="_blank">
|
||||
<img th:src="'/api/thumbnail/' + ${file.getId()}" th:alt="${file.getFileName()}" class="uploadItemImage"/>
|
||||
</a>
|
||||
<a th:href="'/u/' + ${file.getId()}" th:inline="text" target="_blank" class="uploadItemText">
|
||||
[[${file.getFileName()}]]
|
||||
<br/>
|
||||
<span th:text="${file.getDateUpload().toString()}"></span>
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div style="margin-left: 0; margin-right: 0; text-align: center; font-size: 22px;">
|
||||
<a th:href="'/account/files?pageid=' + ${pageid - 1}">Previous</a>
|
||||
<-- <span th:text="${pageid}">0</span> -->
|
||||
<a th:href="'/account/files?pageid=' + ${pageid + 1}">Nextious</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Google Analytics Tracking Code -->
|
||||
<script>
|
||||
(function (i, s, o, g, r, a, m) {
|
||||
i['GoogleAnalyticsObject'] = r;
|
||||
i[r] = i[r] || function () {
|
||||
(i[r].q = i[r].q || []).push(arguments)
|
||||
}, i[r].l = 1 * new Date();
|
||||
a = s.createElement(o),
|
||||
m = s.getElementsByTagName(o)[0];
|
||||
a.async = 1;
|
||||
a.src = g;
|
||||
m.parentNode.insertBefore(a, m)
|
||||
})(window, document, 'script', '//www.google-analytics.com/analytics.js', 'ga');
|
||||
|
||||
ga('create', 'UA-24463738-4', 'auto');
|
||||
ga('send', 'pageview');
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
77
res/template/account/lists.html
Normal file
77
res/template/account/lists.html
Normal file
@@ -0,0 +1,77 @@
|
||||
<!DOCTYPE html>
|
||||
<html xmlns:th="http://www.thymeleaf.org">
|
||||
<head>
|
||||
<title>List Browser ~ PixelDrain</title>
|
||||
<meta charset="UTF-8"/>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0"/>
|
||||
<link rel="stylesheet" href="/res/style/home.css"/>
|
||||
<link rel="stylesheet" href="/res/style/season.css"/>
|
||||
<link rel="stylesheet" href="/res/style/history.css"/>
|
||||
<link rel="stylesheet" href="/res/style/menu.css"/>
|
||||
<link href='https://fonts.googleapis.com/css?family=Ubuntu' rel='stylesheet' type='text/css'/>
|
||||
<link href="https://fonts.googleapis.com/css?family=Lato:100" rel="stylesheet" type="text/css"/>
|
||||
<link rel="shortcut icon" href="/res/img/tray32.png"/>
|
||||
<meta name="theme-color" content="#9FCF6C"/>
|
||||
<link rel="icon" sizes="180x180" href="/res/img/pixeldrain.png"/>
|
||||
<link rel="icon" sizes="256x256" href="/res/img/pixeldrain_big.png"/>
|
||||
|
||||
<style th:include="fragments :: background-pattern" th:inline="text"></style>
|
||||
|
||||
<meta name="description" content="PixelDrain is a free file sharing service, you
|
||||
can upload any file and you will be given a shareable link right away.
|
||||
PixelDrain also supports previews for images, videos, audio, PDFs and much more.
|
||||
Uncensored, unmonitored and unmoderated."/>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div id='body' class="body">
|
||||
<div th:replace="fragments :: menu"></div>
|
||||
<br/>
|
||||
|
||||
<div style="margin-left: 0; margin-right: 0; text-align: center; font-size: 22px;">
|
||||
<a th:href="'/account/lists?pageid=' + ${pageid - 1}">Previous</a>
|
||||
<-- <span th:text="${pageid}">0</span> -->
|
||||
<a th:href="'/account/lists?pageid=' + ${pageid + 1}">Nextious</a>
|
||||
</div>
|
||||
|
||||
<div id="uploadedFiles" class="uploadedFiles">
|
||||
<div class="uploadItem" th:each="list,interation : ${lists}" th:inline="text">
|
||||
<a th:href="'/l/' + ${list.get('id')}" target="_blank">
|
||||
<img th:src="${list.get('image')}" alt="" class="uploadItemImage"/>
|
||||
</a>
|
||||
<a th:href="'/l/' + ${list.get('id')}" target="_blank" class="uploadItemText">
|
||||
[[${list.get('title')}]]
|
||||
<br/>
|
||||
[[${list.get('fileCount')}]] Items
|
||||
<br/>
|
||||
<span th:text="${list.get('date')}"></span>
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div style="margin-left: 0; margin-right: 0; text-align: center; font-size: 22px;">
|
||||
<a th:href="'/account/lists?pageid=' + ${pageid - 1}">Previous</a>
|
||||
<-- <span th:text="${pageid}">0</span> -->
|
||||
<a th:href="'/account/lists?pageid=' + ${pageid + 1}">Nextious</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Google Analytics Tracking Code -->
|
||||
<script>
|
||||
(function (i, s, o, g, r, a, m) {
|
||||
i['GoogleAnalyticsObject'] = r;
|
||||
i[r] = i[r] || function () {
|
||||
(i[r].q = i[r].q || []).push(arguments)
|
||||
}, i[r].l = 1 * new Date();
|
||||
a = s.createElement(o),
|
||||
m = s.getElementsByTagName(o)[0];
|
||||
a.async = 1;
|
||||
a.src = g;
|
||||
m.parentNode.insertBefore(a, m)
|
||||
})(window, document, 'script', '//www.google-analytics.com/analytics.js', 'ga');
|
||||
|
||||
ga('create', 'UA-24463738-4', 'auto');
|
||||
ga('send', 'pageview');
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
80
res/template/account/login.html
Normal file
80
res/template/account/login.html
Normal file
@@ -0,0 +1,80 @@
|
||||
<!DOCTYPE html>
|
||||
<html xmlns:th="http://www.thymeleaf.org">
|
||||
<head>
|
||||
<title>Login ~ PixelDrain</title>
|
||||
<meta charset="UTF-8"/>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0"/>
|
||||
<link rel="stylesheet" href="/res/style/home.css"/>
|
||||
<link rel="stylesheet" href="/res/style/season.css"/>
|
||||
<link rel="stylesheet" href="/res/style/form.css"/>
|
||||
<link rel="stylesheet" href="/res/style/menu.css"/>
|
||||
<link href='https://fonts.googleapis.com/css?family=Ubuntu' rel='stylesheet' type='text/css'/>
|
||||
<link href="https://fonts.googleapis.com/css?family=Lato:100" rel="stylesheet" type="text/css"/>
|
||||
<link rel="shortcut icon" href="/res/img/tray32.png"/>
|
||||
<meta name="theme-color" content="#9FCF6C"/>
|
||||
<link rel="icon" sizes="180x180" href="/res/img/pixeldrain.png"/>
|
||||
<link rel="icon" sizes="256x256" href="/res/img/pixeldrain_big.png"/>
|
||||
|
||||
<style th:include="fragments :: background-pattern" th:inline="text"></style>
|
||||
|
||||
<meta name="description" content="PixelDrain is a free file sharing service, you
|
||||
can upload any file and you will be given a shareable link right away.
|
||||
PixelDrain also supports previews for images, videos, audio, PDFs and much more.
|
||||
Uncensored, unmonitored and unmoderated."/>
|
||||
<meta property="og:type" content="website" />
|
||||
<meta property="og:title" content="Login ~ PixelDrain" />
|
||||
<meta property="og:site_name" content="PixelDrain" />
|
||||
<meta property="og:description" content="Instant file and screenshot sharing." />
|
||||
<meta property="og:url" content="http://pixeldra.in/" />
|
||||
<meta property="og:image" content="/res/img/pixeldrain_big.png" />
|
||||
<meta property="og:image:type" content="image/png" />
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div id='body' class="body">
|
||||
<div th:replace="fragments :: menu"></div>
|
||||
<br/><br/>
|
||||
|
||||
<div id="message" th:switch="${messageType}">
|
||||
<div th:case="'info'" th:utext="${message}" id="text-info" class="text-info"></div>
|
||||
<div th:case="'warn'" th:utext="${message}" id="text-warning" class="text-warning"></div>
|
||||
</div>
|
||||
|
||||
Log in to your PixelDrain account
|
||||
<form action="/login" method="POST">
|
||||
<table>
|
||||
<tr>
|
||||
<td>Username</td>
|
||||
<td><input name="username" type="text" value="" th:value="${form_username}"/></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Password</td>
|
||||
<td><input name="password" type="password"/></td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
<input type="submit" value="Login"/>
|
||||
</form>
|
||||
<br/><br/>
|
||||
If you don't have a PixelDrain account, you can <a href="/register">register here</a>.
|
||||
</div>
|
||||
|
||||
<!-- Google Analytics Tracking Code -->
|
||||
<script>
|
||||
(function (i, s, o, g, r, a, m) {
|
||||
i['GoogleAnalyticsObject'] = r;
|
||||
i[r] = i[r] || function () {
|
||||
(i[r].q = i[r].q || []).push(arguments)
|
||||
}, i[r].l = 1 * new Date();
|
||||
a = s.createElement(o),
|
||||
m = s.getElementsByTagName(o)[0];
|
||||
a.async = 1;
|
||||
a.src = g;
|
||||
m.parentNode.insertBefore(a, m)
|
||||
})(window, document, 'script', '//www.google-analytics.com/analytics.js', 'ga');
|
||||
|
||||
ga('create', 'UA-24463738-4', 'auto');
|
||||
ga('send', 'pageview');
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
99
res/template/account/overview.html
Normal file
99
res/template/account/overview.html
Normal file
@@ -0,0 +1,99 @@
|
||||
<!DOCTYPE html>
|
||||
<html xmlns:th="http://www.thymeleaf.org">
|
||||
<head>
|
||||
<title>File Overview ~ PixelDrain</title>
|
||||
<meta charset="UTF-8"/>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0"/>
|
||||
<link rel="stylesheet" href="/res/style/home.css"/>
|
||||
<link rel="stylesheet" href="/res/style/season.css"/>
|
||||
<link rel="stylesheet" href="/res/style/global.css"/>
|
||||
<link rel="stylesheet" href="/res/style/history.css"/>
|
||||
<link rel="stylesheet" href="/res/style/menu.css"/>
|
||||
<link href='https://fonts.googleapis.com/css?family=Ubuntu' rel='stylesheet' type='text/css'/>
|
||||
<link href="https://fonts.googleapis.com/css?family=Lato:100" rel="stylesheet" type="text/css"/>
|
||||
<link rel="shortcut icon" href="/res/img/tray32.png"/>
|
||||
<meta name="theme-color" content="#9FCF6C"/>
|
||||
<link rel="icon" sizes="180x180" href="/res/img/pixeldrain.png"/>
|
||||
<link rel="icon" sizes="256x256" href="/res/img/pixeldrain_big.png"/>
|
||||
|
||||
<style th:include="fragments :: background-pattern" th:inline="text"></style>
|
||||
|
||||
<meta name="description" content="PixelDrain is a free file sharing service, you
|
||||
can upload any file and you will be given a shareable link right away.
|
||||
PixelDrain also supports previews for images, videos, audio, PDFs and much more.
|
||||
Uncensored, unmonitored and unmoderated."/>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div id='body' class="body">
|
||||
<div th:replace="fragments :: menu"></div>
|
||||
<br/>
|
||||
Logged in as <span th:text="${user.getUsername()}"></span>. <a href="/logout">Log out</a>.
|
||||
<br/><br/>
|
||||
Bandwidth used past 24 hours:<br/>
|
||||
<div id="bandwidth-progress-bar" class="progress-bar">
|
||||
<span th:text="${bandwidth_used} + ' / ' + ${bandwidth_available}"></span>
|
||||
<div id="bandwidth-progress" th:style="'width: ' + ${bandwidth_percentage} + '%;'">
|
||||
<span th:text="${bandwidth_used} + ' / ' + ${bandwidth_available}"></span>
|
||||
</div>
|
||||
</div>
|
||||
<br/>
|
||||
Total size of your files: <span th:text="${account_total_size}"></span>.
|
||||
<br/><br/>
|
||||
Your 20 most recently uploaded files:
|
||||
<div id="uploadedFiles" class="uploadedFiles">
|
||||
<div class="uploadItem" th:each="file,interation : ${files}">
|
||||
<a th:href="'/u/' + ${file.getId()}" th:inline="text" target="_blank">
|
||||
<img th:src="'/api/thumbnail/' + ${file.getId()}" th:alt="${file.getFileName()}" class="uploadItemImage"/>
|
||||
</a>
|
||||
<a th:href="'/u/' + ${file.getId()}" th:inline="text" target="_blank" class="uploadItemText">
|
||||
[[${file.getFileName()}]]
|
||||
<br/>
|
||||
<span th:text="${file.getDateUpload().toString()}"></span>
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
<br/>
|
||||
<div style="margin-left: 0; margin-right: 0; text-align: center; font-size: 20px;">
|
||||
<a href="/account/files">Click here to view all your files</a>
|
||||
</div>
|
||||
<br/>
|
||||
Your 20 most recently created lists:
|
||||
<div id="uploadedFiles" class="uploadedFiles">
|
||||
<div class="uploadItem" th:each="list,interation : ${lists}" th:inline="text">
|
||||
<a th:href="'/l/' + ${list.getId()}" target="_blank">
|
||||
<img th:src="'/api/thumbnail/' + ${list_db.getListItem(list.getId(), 0).getFileId()}" alt="" class="uploadItemImage"/>
|
||||
</a>
|
||||
<a th:href="'/l/' + ${list.getId()}" target="_blank" class="uploadItemText">
|
||||
[[${list.getTitle()}]]
|
||||
<br/>
|
||||
<span th:text="${list.getSize()} + ' Items'"></span>
|
||||
<br/>
|
||||
<span th:text="${list.getDateCreated().toString()}"></span>
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
<div style="margin-left: 0; margin-right: 0; text-align: center; font-size: 20px;">
|
||||
<a href="/account/lists">Click here to view all your lists</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Google Analytics Tracking Code -->
|
||||
<script>
|
||||
(function (i, s, o, g, r, a, m) {
|
||||
i['GoogleAnalyticsObject'] = r;
|
||||
i[r] = i[r] || function () {
|
||||
(i[r].q = i[r].q || []).push(arguments)
|
||||
}, i[r].l = 1 * new Date();
|
||||
a = s.createElement(o),
|
||||
m = s.getElementsByTagName(o)[0];
|
||||
a.async = 1;
|
||||
a.src = g;
|
||||
m.parentNode.insertBefore(a, m)
|
||||
})(window, document, 'script', '//www.google-analytics.com/analytics.js', 'ga');
|
||||
|
||||
ga('create', 'UA-24463738-4', 'auto');
|
||||
ga('send', 'pageview');
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
82
res/template/account/register.html
Normal file
82
res/template/account/register.html
Normal file
@@ -0,0 +1,82 @@
|
||||
<!DOCTYPE html>
|
||||
<html xmlns:th="http://www.thymeleaf.org">
|
||||
<head>
|
||||
<title>Register ~ PixelDrain</title>
|
||||
<meta charset="UTF-8"/>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0"/>
|
||||
<link rel="stylesheet" href="/res/style/home.css"/>
|
||||
<link rel="stylesheet" href="/res/style/season.css"/>
|
||||
<link rel="stylesheet" href="/res/style/form.css"/>
|
||||
<link rel="stylesheet" href="/res/style/menu.css"/>
|
||||
<link href='https://fonts.googleapis.com/css?family=Ubuntu' rel='stylesheet' type='text/css'/>
|
||||
<link href="https://fonts.googleapis.com/css?family=Lato:100" rel="stylesheet" type="text/css"/>
|
||||
<link rel="shortcut icon" href="/res/img/tray32.png"/>
|
||||
<meta name="theme-color" content="#9FCF6C"/>
|
||||
<link rel="icon" sizes="180x180" href="/res/img/pixeldrain.png"/>
|
||||
<link rel="icon" sizes="256x256" href="/res/img/pixeldrain_big.png"/>
|
||||
|
||||
<style th:include="fragments :: background-pattern" th:inline="text"></style>
|
||||
|
||||
<script src='https://www.google.com/recaptcha/api.js'></script>
|
||||
|
||||
<meta name="description" content="PixelDrain is a free file sharing service, you
|
||||
can upload any file and you will be given a shareable link right away.
|
||||
PixelDrain also supports previews for images, videos, audio, PDFs and much more.
|
||||
Uncensored, unmonitored and unmoderated."/>
|
||||
<meta property="og:type" content="website" />
|
||||
<meta property="og:title" content="Register ~ PixelDrain" />
|
||||
<meta property="og:site_name" content="PixelDrain" />
|
||||
<meta property="og:description" content="Instant file and screenshot sharing." />
|
||||
<meta property="og:url" content="http://pixeldra.in/" />
|
||||
<meta property="og:image" content="/res/img/pixeldrain_big.png" />
|
||||
<meta property="og:image:type" content="image/png" />
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div id='body' class="body">
|
||||
<div th:replace="fragments :: menu"></div>
|
||||
<br/>
|
||||
|
||||
<h3>Register a new PixelDrain account</h3>
|
||||
<div id="message" th:switch="${messageType}">
|
||||
<div th:case="'info'" th:utext="${message}" id="text-info" class="text-info"></div>
|
||||
<div th:case="'warn'" th:utext="${message}" id="text-warning" class="text-warning"></div>
|
||||
</div>
|
||||
<form action="/register" method="POST">
|
||||
|
||||
|
||||
Username (Used to log in)<br/>
|
||||
<input name="username" type="text" th:value="${username}"/><br/>
|
||||
<br/>
|
||||
Enter your password twice (Why twice? So we can verify that you have not made any typing errors)<br/>
|
||||
<input name="password1" type="password" th:value="${password1}"/><br/>
|
||||
<input name="password2" type="password" th:value="${password2}"/><br/>
|
||||
<br/>
|
||||
Prove that you're not a robot (Click the white box)
|
||||
<div class="g-recaptcha" data-theme="dark"
|
||||
data-sitekey="6LdEeQ0TAAAAALBmDF_k_2LgbpuJM66PGspByViS">
|
||||
</div><br/>
|
||||
<br/>
|
||||
<input type="submit" value="Register"/>
|
||||
</form>
|
||||
</div>
|
||||
|
||||
<!-- Google Analytics Tracking Code -->
|
||||
<script>
|
||||
(function (i, s, o, g, r, a, m) {
|
||||
i['GoogleAnalyticsObject'] = r;
|
||||
i[r] = i[r] || function () {
|
||||
(i[r].q = i[r].q || []).push(arguments)
|
||||
}, i[r].l = 1 * new Date();
|
||||
a = s.createElement(o),
|
||||
m = s.getElementsByTagName(o)[0];
|
||||
a.async = 1;
|
||||
a.src = g;
|
||||
m.parentNode.insertBefore(a, m)
|
||||
})(window, document, 'script', '//www.google-analytics.com/analytics.js', 'ga');
|
||||
|
||||
ga('create', 'UA-24463738-4', 'auto');
|
||||
ga('send', 'pageview');
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
63
res/template/apidoc.html
Normal file
63
res/template/apidoc.html
Normal file
@@ -0,0 +1,63 @@
|
||||
{{define "apidoc"}}
|
||||
<!DOCTYPE html>
|
||||
<html xmlns:th="http://www.thymeleaf.org">
|
||||
<head>
|
||||
<title>PixelDrain ~ API Documentation</title>
|
||||
<meta charset="UTF-8"/>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0"/>
|
||||
<link rel="stylesheet" href="/res/style/layout.css"/>
|
||||
<link rel="stylesheet" href="/res/style/apidoc.css"/>
|
||||
<link href='http://fonts.googleapis.com/css?family=Ubuntu' rel='stylesheet' type='text/css'/>
|
||||
<link href="https://fonts.googleapis.com/css?family=Lato:100" rel="stylesheet" type="text/css"/>
|
||||
<link rel="shortcut icon" href="/res/img/tray32.png"/>
|
||||
<meta name="theme-color" content="#9FCF6C"/>
|
||||
<link rel="icon" sizes="180x180" href="/res/img/pixeldrain.png"/>
|
||||
<link rel="icon" sizes="256x256" href="/res/img/pixeldrain_big.png"/>
|
||||
|
||||
{{template "bgpattern"}}
|
||||
|
||||
<meta name="description" content="PixelDrain is a free file sharing service, you
|
||||
can upload any file and you will be given a shareable link right away.
|
||||
PixelDrain also supports previews for images, videos, audio, PDFs and much more.
|
||||
Uncensored, unmonitored and unmoderated."/>
|
||||
<meta property="og:type" content="website" />
|
||||
<meta property="og:title" content="API Documentation ~ PixelDrain" />
|
||||
<meta property="og:site_name" content="PixelDrain" />
|
||||
<meta property="og:description" content="Instant file and screenshot sharing." />
|
||||
<meta property="og:url" content="http://pixeldra.in/" />
|
||||
<meta property="og:image" content="/res/img/pixeldrain_big.png" />
|
||||
<meta property="og:image:type" content="image/png" />
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div id='body' class="body">
|
||||
{{template "menu"}}
|
||||
<h1>PixelDrain API Documentation</h1>
|
||||
<p>
|
||||
Welcome to the Pixeldrain API documentation.
|
||||
<br/>
|
||||
The methods for uploading and retrieving files don't require an
|
||||
API key. The methods for creating and retrieving lists also
|
||||
don't require an API key. All methods which delete or modify a
|
||||
resource <strong>do</strong> require an API key.
|
||||
<br/>
|
||||
<br/>
|
||||
Though API keys have not been implemented yet.
|
||||
</p>
|
||||
|
||||
<h2>File Methods</h2>
|
||||
{{template "api-file-post"}}
|
||||
{{template "api-file-id-get"}}
|
||||
{{template "api-file-id-download-get"}}
|
||||
{{template "api-file-id-info-get"}}
|
||||
{{template "api-file-id-thumbnail-get"}}
|
||||
{{template "api-file-id-delete"}}
|
||||
|
||||
<h2>List Methods</h2>
|
||||
{{template "api-list-post"}}
|
||||
{{template "footer"}}
|
||||
</div>
|
||||
{{template "analytics"}}
|
||||
</body>
|
||||
</html>
|
||||
{{end}}
|
86
res/template/donation.html
Normal file
86
res/template/donation.html
Normal file
@@ -0,0 +1,86 @@
|
||||
<!DOCTYPE html>
|
||||
<html xmlns:th="http://www.thymeleaf.org">
|
||||
<head>
|
||||
<title>Thank you for supporting Pixeldrain!</title>
|
||||
<meta charset="UTF-8"/>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0"/>
|
||||
<link rel="stylesheet" href="/res/style/layout.css"/>
|
||||
<link href='https://fonts.googleapis.com/css?family=Ubuntu' rel='stylesheet' type='text/css'/>
|
||||
<link href="https://fonts.googleapis.com/css?family=Lato:100" rel="stylesheet" type="text/css"/>
|
||||
<link rel="shortcut icon" href="/res/img/tray32.png"/>
|
||||
<meta name="theme-color" content="#9FCF6C"/>
|
||||
<link rel="icon" sizes="180x180" href="/res/img/pixeldrain.png"/>
|
||||
<link rel="icon" sizes="256x256" href="/res/img/pixeldrain_big.png"/>
|
||||
|
||||
<style>
|
||||
body, .checkers{
|
||||
background-image: url("/res/img/checker6.png");
|
||||
background-attachment: fixed;
|
||||
}
|
||||
</style>
|
||||
|
||||
<meta name="description" content="PixelDrain is a free file sharing service, you
|
||||
can upload any file and you will be given a shareable link right away.
|
||||
PixelDrain also supports previews for images, videos, audio, PDFs and much more.
|
||||
Uncensored, unmonitored and unmoderated."/>
|
||||
<meta property="og:type" content="website" />
|
||||
<meta property="og:title" content="Thanks! ~ PixelDrain" />
|
||||
<meta property="og:site_name" content="PixelDrain" />
|
||||
<meta property="og:description" content="Instant file and screenshot sharing." />
|
||||
<meta property="og:url" content="http://pixeldra.in/" />
|
||||
<meta property="og:image" content="/res/img/pixeldrain_big.png" />
|
||||
<meta property="og:image:type" content="image/png" />
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div id="body" class="body">
|
||||
<div th:replace="fragments :: menu"></div>
|
||||
<br/><br/>
|
||||
<span th:switch="${donation_success}">
|
||||
<span th:case="true">
|
||||
<span th:switch="${user_authenticated}">
|
||||
<span th:case="false">
|
||||
Thank you for your donation! You are amazing.
|
||||
<br/><br/>
|
||||
Sincerely,<br/>
|
||||
Fornax
|
||||
</span>
|
||||
<span th:case="true">
|
||||
Dear <span th:text="${user.getUsername()}"></span>,
|
||||
<br/><br/>
|
||||
Thank you for your donation. I really appreciate it!
|
||||
<br/><br/>
|
||||
Sincerely,<br/>
|
||||
Fornax
|
||||
</span>
|
||||
</span>
|
||||
</span>
|
||||
|
||||
<span th:case="false">
|
||||
It seems you have canceled your donation. I don't blame you, money is expensive :)
|
||||
<br/><br/>
|
||||
Sincerely,<br/>
|
||||
Fornax</span>
|
||||
</span>
|
||||
{{template "footer"}}
|
||||
</div>
|
||||
|
||||
<!-- Google Analytics Tracking Code -->
|
||||
<script>
|
||||
(function (i, s, o, g, r, a, m) {
|
||||
i['GoogleAnalyticsObject'] = r;
|
||||
i[r] = i[r] || function () {
|
||||
(i[r].q = i[r].q || []).push(arguments)
|
||||
}, i[r].l = 1 * new Date();
|
||||
a = s.createElement(o),
|
||||
m = s.getElementsByTagName(o)[0];
|
||||
a.async = 1;
|
||||
a.src = g;
|
||||
m.parentNode.insertBefore(a, m)
|
||||
})(window, document, 'script', '//www.google-analytics.com/analytics.js', 'ga');
|
||||
|
||||
ga('create', 'UA-24463738-4', 'auto');
|
||||
ga('send', 'pageview');
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
44
res/template/error.html
Normal file
44
res/template/error.html
Normal file
@@ -0,0 +1,44 @@
|
||||
{{define "error"}}
|
||||
<!DOCTYPE html>
|
||||
<html xmlns:th="http://www.thymeleaf.org">
|
||||
<head>
|
||||
<title>PixelDrain ~ Error</title>
|
||||
<meta charset="UTF-8"/>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0"/>
|
||||
<link rel="stylesheet" href="/res/style/layout.css"/>
|
||||
<link href='https://fonts.googleapis.com/css?family=Ubuntu' rel='stylesheet' type='text/css'/>
|
||||
<link href="https://fonts.googleapis.com/css?family=Lato:100" rel="stylesheet" type="text/css"/>
|
||||
<link rel="shortcut icon" href="/res/img/tray32.png"/>
|
||||
<meta name="theme-color" content="#9FCF6C"/>
|
||||
<link rel="icon" sizes="180x180" href="/res/img/pixeldrain.png"/>
|
||||
<link rel="icon" sizes="256x256" href="/res/img/pixeldrain_big.png"/>
|
||||
|
||||
{{template "bgpattern"}}
|
||||
|
||||
<meta name="description" content="PixelDrain is a free file sharing service, you can upload any file and you will be given a shareable link right away. PixelDrain also supports previews for images, videos, audio, PDFs and much more. Uncensored, unmonitored and unmoderated."/>
|
||||
<meta property="og:type" content="website" />
|
||||
<meta property="og:title" content="PixelDrain ~ Error" />
|
||||
<meta property="og:site_name" content="PixelDrain" />
|
||||
<meta property="og:description" content="Instant file and screenshot sharing." />
|
||||
<meta property="og:url" content="http://pixeldra.in/" />
|
||||
<meta property="og:image" content="/res/img/pixeldrain_big.png" />
|
||||
<meta property="og:image:type" content="image/png" />
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div id='body' class="body">
|
||||
{{template "menu"}}
|
||||
<br/>
|
||||
<h1>Some Error occured</h1>
|
||||
Either you made a mistake, or I made a mistake.
|
||||
<br/><br/>
|
||||
Anyway, there's nothing to see here, so you'll have to <a href='/'>head over to the index page</a>.
|
||||
<br/>
|
||||
<br/>
|
||||
Bye!
|
||||
{{template "footer"}}
|
||||
</div>
|
||||
{{template "analytics"}}
|
||||
</body>
|
||||
</html>
|
||||
{{end}}
|
36
res/template/file_info_popup.html
Normal file
36
res/template/file_info_popup.html
Normal file
@@ -0,0 +1,36 @@
|
||||
{{define "file_info_popup"}}
|
||||
<h3>About</h3>
|
||||
PixelDrain is a file sharing platform.
|
||||
<a href="/" target="_blank">Visit the main site for more information.</a>
|
||||
|
||||
<h3>Keyboard Controls</h3>
|
||||
<table>
|
||||
<tr><td colspan="2">File Shortcuts</td></tr>
|
||||
<tr><td>c</td><td> = Copy URL of this page</td></tr>
|
||||
<tr><td>i</td><td> = Toggle details window (this window)</td></tr>
|
||||
<tr><td>s</td><td> = Download the file you are currently viewing</td></tr>
|
||||
<tr><td colspan="2">List Shortcuts</td></tr>
|
||||
<tr><td>a or ←</td><td> = View previous item in list</td></tr>
|
||||
<tr><td>d or →</td><td> = View next item in list</td></tr>
|
||||
<tr><td>r</td><td> = Toggle shuffle (<b><u>r</u></b>andom)</td></tr>
|
||||
<tr><td>SHIFT + s</td><td> = Download all the files in the list as a zip archive</td></tr>
|
||||
</table>
|
||||
|
||||
<h3>Credits</h3>
|
||||
All server side code written by
|
||||
<a target="_blank" href="https://fornaxian.com/">Fornax (me)</a>.
|
||||
|
||||
<br/><br/>
|
||||
|
||||
Code syntax highlighting is by
|
||||
<a target="_blank" href="https://github.com/google/code-prettify">
|
||||
Google Code-prettify
|
||||
</a>.
|
||||
|
||||
<br/><br/>
|
||||
|
||||
Thanks to the Mozilla team for their wonderful PDF viewer
|
||||
<a target="_blank" href="https://github.com/mozilla/pdf.js">pdf.js</a>.
|
||||
|
||||
<br/><br/>
|
||||
{{end}}
|
27
res/template/file_not_found.html
Normal file
27
res/template/file_not_found.html
Normal file
@@ -0,0 +1,27 @@
|
||||
{{define "file_not_found"}}
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>File not found ~ PixelDrain</title>
|
||||
<meta charset="UTF-8"/>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0"/>
|
||||
<link rel="stylesheet" href="/res/style/viewer.css"/>
|
||||
<link href='https://fonts.googleapis.com/css?family=Ubuntu' rel='stylesheet' type='text/css'/>
|
||||
<link rel="shortcut icon" href="/res/img/tray32.png"/>
|
||||
<meta name="theme-color" content="#9FCF6C"/>
|
||||
<link rel="icon" sizes="180x180" href="res/img/pixeldrain.png"/>
|
||||
<link rel="icon" sizes="256x256" href="res/img/pixeldrain_big.png"/>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<h1>File not Found</h1>
|
||||
I'm sorry, but this file does not exist!<br/>
|
||||
It may have expired, or taken down by the owner.<br/>
|
||||
You can <a href='/'>Visit the homepage to upload your own files</a>.
|
||||
<br/><br/>
|
||||
It was fun having you, bye for now!
|
||||
|
||||
{{template "analytics"}}
|
||||
</body>
|
||||
</html>
|
||||
{{end}}
|
166
res/template/file_viewer.html
Normal file
166
res/template/file_viewer.html
Normal file
@@ -0,0 +1,166 @@
|
||||
{{define "file_viewer"}}
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>{{.FileName}} ~ PixelDrain File</title>
|
||||
<meta charset="UTF-8"/>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0"/>
|
||||
<link rel="stylesheet" href="/res/style/viewer.css"/>
|
||||
<link rel="stylesheet" href="/res/style/season.css"/>
|
||||
<link rel="stylesheet" href="/res/style/listview.css"/>
|
||||
<link href='https://fonts.googleapis.com/css?family=Ubuntu' rel='stylesheet' type='text/css'/>
|
||||
<link rel="shortcut icon" href="/res/img/tray32.png"/>
|
||||
<meta name="theme-color" content="#9FCF6C"/>
|
||||
<link rel="icon" sizes="180x180" href="/res/img/pixeldrain.png"/>
|
||||
<link rel="icon" sizes="256x256" href="/res/img/pixeldrain_big.png"/>
|
||||
|
||||
<link rel="stylesheet" href="https://ajax.googleapis.com/ajax/libs/jqueryui/1.11.4/themes/smoothness/jquery-ui.css"/>
|
||||
|
||||
<link rel="alternate" type="application/json+oembed" th:href="*{oEmbedHref}" th:title="*{ogTitle}" />
|
||||
|
||||
{{template "bgpattern"}}
|
||||
|
||||
<meta name="twitter:creator" content="@Fornax96" />
|
||||
<meta name="twitter:image" th:content="*{ogImage}" />
|
||||
<meta property="og:title" th:content="*{ogTitle}" />
|
||||
<meta property="og:type" th:content="*{ogType}" />
|
||||
<meta property="og:site_name" th:content="*{ogSiteName}" />
|
||||
<meta property="og:description" th:content="*{ogDescription}" />
|
||||
<meta property="description" th:content="*{description}" />
|
||||
<meta property="og:url" th:content="*{ogUrl}" />
|
||||
<meta property="og:image" th:content="*{ogImage}" />
|
||||
<meta property="og:image:url" th:content="*{ogImage}" />
|
||||
<meta property="article:author" content="Fornax96" />
|
||||
<link rel="image_src" th:href="*{ogImage}" />
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div id="listNavigator">
|
||||
<img src="/res/img/arrow-left.png" id="arrow-left" alt="Previous Item" onClick="ListNavigator.previousItem();" />
|
||||
<img src="/res/img/arrow-right.png" id="arrow-right" alt="Next Item" onClick="ListNavigator.nextItem();" />
|
||||
<div id="listNavigatorItems"></div>
|
||||
</div>
|
||||
<div id="toolbar">
|
||||
<!-- Ugly workaround to get rid of the scrollbar in non-webkit browsers -->
|
||||
<div>
|
||||
<div>
|
||||
<img id="button-expand-toolbar" src="/res/img/toolbar_show.png" alt="Expand Menu"
|
||||
onClick="Toolbar.toggle();"
|
||||
style="position: fixed; visibility:hidden; left: 0px; cursor: pointer" />
|
||||
|
||||
<button class="toolbar-button" onClick="Toolbar.toggle();">Hide Toolbar</button>
|
||||
|
||||
Views: <span id="views" th:text="${data.views}">0</span><br/>
|
||||
|
||||
<button id="btnDownload" class="toolbar-button" onClick="Toolbar.download();">
|
||||
<img src="/res/img/floppy_small.png" alt="Download this file"/>
|
||||
<span>Download</span>
|
||||
</button>
|
||||
|
||||
<button id="btnCopy" class="toolbar-button" onClick="Toolbar.copyUrl();">
|
||||
<img src="/res/img/clipboard_small.png" alt="Copy file URL to clipboard"/>
|
||||
<span>Copy</span>
|
||||
</button>
|
||||
|
||||
<button id="btnShare" onClick="Sharebar.toggle();" class="toolbar-button">
|
||||
<img src="/res/img/share_small.png" alt="Share this file on social media"/>
|
||||
<span>Share</span>
|
||||
</button>
|
||||
|
||||
<form action="/" target="_blank">
|
||||
<button id="btnHome" class="toolbar-button">
|
||||
<img src="/res/img/pixeldrain_small.png" alt="Back to the Home page"/>
|
||||
<span>Home</span>
|
||||
</button>
|
||||
</form>
|
||||
|
||||
<button id="btnDetails" class="toolbar-button" onClick="DetailsWindow.toggle();">
|
||||
<img src="/res/img/info_small.png" alt="Help"/>
|
||||
<span>Details</span>
|
||||
</button>
|
||||
|
||||
<iframe id='sponsors' data-aa='73974'
|
||||
src='//ad.a-ads.com/73974?size=120x600&background_color=000000&text_color=eeeeee&title_color=eeeeee&link_color=9fcf6c&link_hover_color=d2ffa1&title_hover_color=d2ffa1'
|
||||
scrolling='no' allowtransparency='true' seamless="seamless">
|
||||
</iframe>
|
||||
|
||||
<iframe id="frmDownload">
|
||||
</iframe>
|
||||
<textarea id="copy-text"></textarea>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="sharebar" class="sidebar">
|
||||
<img src="/res/img/arrows-collapse.png" alt="Slide Menu"
|
||||
onClick="Sharebar.toggle();" class="button-collapse"/>
|
||||
|
||||
Share on:<br/>
|
||||
<button class="sharebar-button" th:onclick="'window.open(\'' + ${reddit} + '\');'">
|
||||
<img src="/res/img/social_reddit.png" alt="Share on Reddit" style="width:40px; height: 40px;"/>
|
||||
<br/>Reddit
|
||||
</button>
|
||||
<button class="sharebar-button" th:onClick="'window.open(\'' + ${voat} + '\');'">
|
||||
<img src="/res/img/social_voat.png" alt="Share on Voat" style="width:40px; height: 40px;"/>
|
||||
<br/>Voat
|
||||
</button>
|
||||
<button class="sharebar-button" th:onClick="'window.open(\'' + ${facebook} + '\');'">
|
||||
<img src="/res/img/social_facebook.png" alt="Share on Facebook" style="width:40px; height: 40px;"/>
|
||||
<br/>Facebook
|
||||
</button>
|
||||
<button class="sharebar-button" th:onClick="'window.open(\'' + ${twitter} + '\');'">
|
||||
<img src="/res/img/social_twitter.png" alt="Share on Twitter" style="width:40px; height: 40px;"/>
|
||||
<br/>Twitter
|
||||
</button>
|
||||
<button class="sharebar-button" th:onClick="'window.open(\'' + ${googleplus} + '\');'">
|
||||
<img src="/res/img/social_googleplus.png" alt="Share on Google Plus" style="width:40px; height: 40px;"/>
|
||||
<br/>Google+
|
||||
</button>
|
||||
<button class="sharebar-button" th:onClick="'window.open(\'' + ${tumblr} + '\');'">
|
||||
<img src="/res/img/social_tumblr.png" alt="Share on Tumblr" style="width:40px; height: 40px;"/>
|
||||
<br/>Tumblr
|
||||
</button>
|
||||
<button class="sharebar-button" th:onClick="'window.open(\'' + ${stumbleupon} + '\');'">
|
||||
<img src="/res/img/social_stumbleupon.png" alt="Share on StumbleUpon" style="width:40px; height: 40px;"/>
|
||||
<br/>StumbleUpon
|
||||
</button>
|
||||
<button class="sharebar-button" th:onClick="'window.open(\'' + ${email} + '\');'">
|
||||
<img src="/res/img/social_email.png" alt="Share on E-Mail" style="width:40px; height: 40px;"/>
|
||||
<br/>E-Mail
|
||||
</button>
|
||||
</div>
|
||||
|
||||
<div id="info-popup" class="full-popup">
|
||||
<img alt="Close" src="/res/img/cross.png"
|
||||
style="position: absolute; top: 5px; right: 5px; width: 40px; height: 40px; cursor: pointer;"
|
||||
onclick="DetailsWindow.toggle();"/>
|
||||
Click the help button again to close this overlay.<br/>
|
||||
|
||||
<h3>File Info</h3>
|
||||
<span id="info-fileDetails"></span>
|
||||
<span id="info-about">{{template "file_info_popup"}}</span>
|
||||
</div>
|
||||
|
||||
<div id="filepreview">
|
||||
Loading...
|
||||
</div>
|
||||
|
||||
<script src="/res/script/jquery-2.1.4.min.js"></script>
|
||||
<script src="https://ajax.googleapis.com/ajax/libs/jqueryui/1.11.4/jquery-ui.min.js"></script>
|
||||
<script src="/res/script/Keyboard.js"></script>
|
||||
<script src="/res/script/Toolbar.js"></script>
|
||||
<script src="/res/script/Sharebar.js"></script>
|
||||
<script src="/res/script/DetailsWindow.js"></script>
|
||||
<script src="/res/script/Viewer.js"></script>
|
||||
<script src="/res/script/ListNavigator.js"></script>
|
||||
|
||||
<script>
|
||||
// This info gets filled in on the server side to prevent having to make an API call right after the page loads.
|
||||
// Just to slice another few milliseconds from the load time :)
|
||||
Viewer.init('{{.Type}}', {{.APIResponse}});
|
||||
</script>
|
||||
|
||||
{{template "analytics"}}
|
||||
</body>
|
||||
</html>
|
||||
{{end}}
|
79
res/template/file_viewer_embed.html
Normal file
79
res/template/file_viewer_embed.html
Normal file
@@ -0,0 +1,79 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title th:text="*{ogTitle}">PixelDrain</title>
|
||||
<meta charset="UTF-8"/>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0"/>
|
||||
<link rel="stylesheet" href="/res/style/viewer_embed.css"/>
|
||||
<link rel="stylesheet" href="/res/style/season.css"/>
|
||||
<link rel="stylesheet" href="/res/style/listview_embed.css"/>
|
||||
<link href='https://fonts.googleapis.com/css?family=Ubuntu' rel='stylesheet' type='text/css'/>
|
||||
<link rel="shortcut icon" href="/res/img/tray32.png"/>
|
||||
<meta name="theme-color" content="#9FCF6C"/>
|
||||
<link rel="icon" sizes="180x180" href="/res/img/pixeldrain.png"/>
|
||||
<link rel="icon" sizes="256x256" href="/res/img/pixeldrain_big.png"/>
|
||||
|
||||
<style th:include="fragments :: background-pattern" th:inline="text"></style>
|
||||
|
||||
<script src="/res/script/jquery-2.1.4.min.js"></script>
|
||||
<link rel="stylesheet" href="https://ajax.googleapis.com/ajax/libs/jqueryui/1.11.4/themes/smoothness/jquery-ui.css"/>
|
||||
|
||||
<script src="https://ajax.googleapis.com/ajax/libs/jqueryui/1.11.4/jquery-ui.min.js"></script>
|
||||
|
||||
<meta name="twitter:creator" content="@Fornax96" />
|
||||
<meta property="og:title" th:content="*{ogTitle}" />
|
||||
<meta property="og:type" th:content="*{ogType}" />
|
||||
<meta property="og:site_name" th:content="*{ogSiteName}" />
|
||||
<meta property="og:description" th:content="*{ogDescription}" />
|
||||
<meta property="description" th:content="*{description}" />
|
||||
<meta property="og:url" th:content="*{ogUrl}" />
|
||||
<meta property="og:image" th:content="*{ogImage}" />
|
||||
<meta property="article:author" content="Fornax96" />
|
||||
<link rel="image_src" th:href="*{ogImage}" />
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div id="listNavigator">
|
||||
<img src="/res/img/arrow-left.png" id="arrow-left" alt="Previous Item" onClick="ListNavigator.previousItem();" />
|
||||
<img src="/res/img/arrow-right.png" id="arrow-right" alt="Next Item" onClick="ListNavigator.nextItem();" />
|
||||
<div id="listNavigatorItems"></div>
|
||||
</div>
|
||||
|
||||
<div id="filepreview">
|
||||
Loading...
|
||||
</div>
|
||||
|
||||
<script src="/res/script/jquery-2.1.4.min.js"></script>
|
||||
<script src="https://ajax.googleapis.com/ajax/libs/jqueryui/1.11.4/jquery-ui.min.js"></script>
|
||||
<script src="/res/script/Keyboard.js"></script>
|
||||
<script src="/res/script/Toolbar.js"></script>
|
||||
<script src="/res/script/Sharebar.js"></script>
|
||||
<script src="/res/script/DetailsWindow.js"></script>
|
||||
<script src="/res/script/Viewer.js"></script>
|
||||
<script src="/res/script/ListNavigator.js"></script>
|
||||
|
||||
<script th:inline="javascript">
|
||||
// This info gets filled in on the server side to prevent having to make an API call right after the page loads.
|
||||
// Just to slice another few milliseconds from the load time :)
|
||||
Viewer.init([[${type}]], [[${id}]], [[${data}]]);
|
||||
</script>
|
||||
|
||||
<!-- Google Analytics Tracking code -->
|
||||
<script>
|
||||
(function (i, s, o, g, r, a, m) {
|
||||
i['GoogleAnalyticsObject'] = r;
|
||||
i[r] = i[r] || function () {
|
||||
(i[r].q = i[r].q || []).push(arguments)
|
||||
}, i[r].l = 1 * new Date();
|
||||
a = s.createElement(o),
|
||||
m = s.getElementsByTagName(o)[0];
|
||||
a.async = 1;
|
||||
a.src = g;
|
||||
m.parentNode.insertBefore(a, m)
|
||||
})(window, document, 'script', '//www.google-analytics.com/analytics.js', 'ga');
|
||||
|
||||
ga('create', 'UA-24463738-4', 'auto');
|
||||
ga('send', 'pageview');
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
19
res/template/fragments/analytics.html
Normal file
19
res/template/fragments/analytics.html
Normal file
@@ -0,0 +1,19 @@
|
||||
{{define "analytics"}}{{if not debugMode}}
|
||||
<!-- Google Analytics Tracking Code -->
|
||||
<script>
|
||||
(function (i, s, o, g, r, a, m) {
|
||||
i['GoogleAnalyticsObject'] = r;
|
||||
i[r] = i[r] || function () {
|
||||
(i[r].q = i[r].q || []).push(arguments)
|
||||
}, i[r].l = 1 * new Date();
|
||||
a = s.createElement(o),
|
||||
m = s.getElementsByTagName(o)[0];
|
||||
a.async = 1;
|
||||
a.src = g;
|
||||
m.parentNode.insertBefore(a, m)
|
||||
})(window, document, 'script', '//www.google-analytics.com/analytics.js', 'ga');
|
||||
|
||||
ga('create', 'UA-24463738-4', 'auto');
|
||||
ga('send', 'pageview');
|
||||
</script>
|
||||
{{end}}{{end}}
|
51
res/template/fragments/api/file-id-delete.html
Normal file
51
res/template/fragments/api/file-id-delete.html
Normal file
@@ -0,0 +1,51 @@
|
||||
{{define "api-file-id-delete"}}
|
||||
<details th:fragment="details" class="api_doc_details request_delete">
|
||||
<summary>DELETE: /file/{id}</summary>
|
||||
<div>
|
||||
<h3>Description</h3>
|
||||
<p>
|
||||
Deletes a file. Only works when the users owns the file.
|
||||
</p>
|
||||
<h3>Parameters</h3>
|
||||
<table>
|
||||
<tr>
|
||||
<td>Param</td>
|
||||
<td>Required</td>
|
||||
<td>Location</td>
|
||||
<td>Description</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>id</td>
|
||||
<td>true</td>
|
||||
<td>URL</td>
|
||||
<td>ID of the file to delete</td>
|
||||
</tr>
|
||||
</table>
|
||||
<h3>Returns</h3>
|
||||
<pre>HTTP 200: OK
|
||||
{
|
||||
"success": true,
|
||||
"value": "file_deleted",
|
||||
"message": "The file has been deleted."
|
||||
}</pre>
|
||||
<pre>HTTP 404: Not Found
|
||||
{
|
||||
"success": false,
|
||||
"value": "file_not_found",
|
||||
"message": "File ID was not found in the database."
|
||||
}</pre>
|
||||
<pre>HTTP 401: Unauthorized
|
||||
{
|
||||
"success": false,
|
||||
"value": "unauthorized",
|
||||
"message": "You are not logged in."
|
||||
}</pre>
|
||||
<pre>HTTP 403: Forbidden
|
||||
{
|
||||
"success": false,
|
||||
"value": "forbidden",
|
||||
"message": "This is not your file."
|
||||
}</pre>
|
||||
</div>
|
||||
</details>
|
||||
{{end}}
|
13
res/template/fragments/api/file-id-download-get.html
Normal file
13
res/template/fragments/api/file-id-download-get.html
Normal file
@@ -0,0 +1,13 @@
|
||||
{{define "api-file-id-download-get"}}
|
||||
<details th:fragment="details" class="api_doc_details request_get">
|
||||
<summary>GET: /file/{id}/download</summary>
|
||||
<div>
|
||||
<h3>Description</h3>
|
||||
<p>
|
||||
Same as GET /file/{id}, but with File Transfer HTTP
|
||||
headers. Will trigger a save file dialog when opened in
|
||||
a web browser. Does not support byte range requests.
|
||||
</p>
|
||||
</div>
|
||||
</details>
|
||||
{{end}}
|
29
res/template/fragments/api/file-id-get.html
Normal file
29
res/template/fragments/api/file-id-get.html
Normal file
@@ -0,0 +1,29 @@
|
||||
{{define "api-file-id-get"}}
|
||||
<details th:fragment="details" class="api_doc_details request_get">
|
||||
<summary>GET: /file/{id}</summary>
|
||||
<div>
|
||||
<h3>Description</h3>
|
||||
<p>
|
||||
Returns the full file associated with the ID. Supports
|
||||
byte range requests.
|
||||
</p>
|
||||
<h3>Parameters</h3>
|
||||
<table>
|
||||
<tr>
|
||||
<td>Param</td>
|
||||
<td>Required</td>
|
||||
<td>Location</td>
|
||||
<td>Description</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>id</td>
|
||||
<td>true</td>
|
||||
<td>URL</td>
|
||||
<td>ID of the file to request</td>
|
||||
</tr>
|
||||
</table>
|
||||
<h3>Returns</h3>
|
||||
A file output stream.
|
||||
</div>
|
||||
</details>
|
||||
{{end}}
|
50
res/template/fragments/api/file-id-info-get.html
Normal file
50
res/template/fragments/api/file-id-info-get.html
Normal file
@@ -0,0 +1,50 @@
|
||||
{{define "api-file-id-info-get"}}
|
||||
<details th:fragment="details" class="api_doc_details request_get">
|
||||
<summary>GET: /file/{id}/info</summary>
|
||||
<div>
|
||||
<h3>Description</h3>
|
||||
<p>
|
||||
Returns information about one or more files.
|
||||
You can also put a comma separated list of file IDs in
|
||||
the URL and it will return an array of file info,
|
||||
instead of a single object.
|
||||
</p>
|
||||
<h3>Parameters</h3>
|
||||
<table>
|
||||
<tr>
|
||||
<td>Param</td>
|
||||
<td>Required</td>
|
||||
<td>Location</td>
|
||||
<td>Description</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>id</td>
|
||||
<td>true</td>
|
||||
<td>URL</td>
|
||||
<td>ID(s) of the file</td>
|
||||
</tr>
|
||||
</table>
|
||||
<h3>Returns</h3>
|
||||
<pre>HTTP 200: OK
|
||||
{
|
||||
"success": true,
|
||||
"id": "123abc",
|
||||
"file_name": "screenshot.png",
|
||||
"date_upload": 1485894987, // Timestamp
|
||||
"date_last_view": 1485894987, // Timestamp
|
||||
"days_valid": 60, // Days of inactivity until it gets deleted
|
||||
"file_size": 5694837, // Bytes
|
||||
"views" 1234, // Amount of unique file views
|
||||
"mime_type" "image/png",
|
||||
"description": "File description",
|
||||
"mime_image": "http://pixeldra.in/res/img/mime/image-png.png", // Image associated with the mime type
|
||||
"thumbnail": "http://pixeldra.in/api/thumbnail/123abc" // Link to a thumbnail of this file
|
||||
}</pre>
|
||||
<pre>HTTP 404: Not Found
|
||||
{
|
||||
"success": false,
|
||||
"value": "file_not_found"
|
||||
}</pre>
|
||||
</div>
|
||||
</details>
|
||||
{{end}}
|
34
res/template/fragments/api/file-id-thumbnail-get.html
Normal file
34
res/template/fragments/api/file-id-thumbnail-get.html
Normal file
@@ -0,0 +1,34 @@
|
||||
{{define "api-file-id-thumbnail-get"}}
|
||||
<details th:fragment="details" class="api_doc_details request_get">
|
||||
<summary>GET: /file/{id}/thumbnail</summary>
|
||||
<div>
|
||||
<h3>Description</h3>
|
||||
<p>
|
||||
Returns a PNG thumbnail image representing the file.
|
||||
The thumbnail is always 100*100 px. If the source file
|
||||
is parsable by imagemagick the thumbnail will be
|
||||
generated from the file, if not it will be a generic
|
||||
mime type icon.
|
||||
</p>
|
||||
<h3>Parameters</h3>
|
||||
<table>
|
||||
<tr>
|
||||
<td>Param</td>
|
||||
<td>Required</td>
|
||||
<td>Location</td>
|
||||
<td>Description</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>id</td>
|
||||
<td>true</td>
|
||||
<td>URL</td>
|
||||
<td>ID of the file to get a thumbnail for</td>
|
||||
</tr>
|
||||
</table>
|
||||
<h3>Returns</h3>
|
||||
<p>
|
||||
A PNG image of 100*100 px.
|
||||
</p>
|
||||
</div>
|
||||
</details>
|
||||
{{end}}
|
86
res/template/fragments/api/file-post.html
Normal file
86
res/template/fragments/api/file-post.html
Normal file
@@ -0,0 +1,86 @@
|
||||
{{define "api-file-post"}}
|
||||
<details th:fragment="details" class="api_doc_details request_post">
|
||||
<summary>POST: /file</summary>
|
||||
<div>
|
||||
<h3>Description</h3>
|
||||
<p>
|
||||
Upload a file.
|
||||
</p>
|
||||
|
||||
<h3>Parameters</h3>
|
||||
<table>
|
||||
<tr>
|
||||
<td>Param</td>
|
||||
<td>Required</td>
|
||||
<td>Maximum Size</td>
|
||||
<td>Default</td>
|
||||
<td>Description</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>file</td>
|
||||
<td>true</td>
|
||||
<td>5 000 000 000 Bytes</td>
|
||||
<td>none</td>
|
||||
<td>Multipart file to upload</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>name</td>
|
||||
<td>false</td>
|
||||
<td>300 Characters</td>
|
||||
<td>Name of file param</td>
|
||||
<td>Name of the file to upload</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>description</td>
|
||||
<td>false</td>
|
||||
<td>5000 Characters</td>
|
||||
<td>Pixeldrain File</td>
|
||||
<td>Description of the file</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
<h3>Returns</h3>
|
||||
<pre>HTTP 200: OK
|
||||
{
|
||||
"success": true,
|
||||
"id": "abc123" // ID of the newly uploaded file
|
||||
}</pre>
|
||||
<pre>HTTP 422: Unprocessable Entity
|
||||
{
|
||||
"success": false,
|
||||
"value": "no_file",
|
||||
"message": "The file does not exist or is empty."
|
||||
}</pre>
|
||||
<pre>HTTP 500: Internal Server Error
|
||||
{
|
||||
"success": false,
|
||||
"value": "internal",
|
||||
"message": "An internal server error occurred."
|
||||
}</pre>
|
||||
<pre>HTTP 413: Payload Too Large
|
||||
{
|
||||
"success": false,
|
||||
"value": "file_too_large",
|
||||
"message": "The file you tried to upload is too large. Max 5000 MB allowed."
|
||||
}</pre>
|
||||
<pre>HTTP 500: Internal Server Error
|
||||
{
|
||||
"success": false,
|
||||
"value": "writing",
|
||||
"message": "Something went wrong while writing the file to disk, the server may be out of storage space."
|
||||
}</pre>
|
||||
<pre>HTTP 413: Payload Too Large
|
||||
{
|
||||
"success": false,
|
||||
"value": "name_too_long",
|
||||
"message": "File Name is too long, Max 300 characters allowed."
|
||||
}</pre>
|
||||
<pre>HTTP 413: Payload Too Large
|
||||
{
|
||||
"success": false,
|
||||
"value": "description_too_long",
|
||||
"message": "File Description is too long, Max 5000 characters allowed."
|
||||
}</pre>
|
||||
</div>
|
||||
</details>
|
||||
{{end}}
|
52
res/template/fragments/api/list-post.html
Normal file
52
res/template/fragments/api/list-post.html
Normal file
@@ -0,0 +1,52 @@
|
||||
{{define "api-list-post"}}
|
||||
<details th:fragment="details" class="api_doc_details request_post">
|
||||
<summary>POST: /list</summary>
|
||||
<div>
|
||||
<h3>Description</h3>
|
||||
<p>
|
||||
Creates a list of files that can be viewed together on the file
|
||||
viewer page.
|
||||
</p>
|
||||
<h3>Parameters</h3>
|
||||
<table>
|
||||
<tr>
|
||||
<td>Param</td>
|
||||
<td>Required</td>
|
||||
<td>Location</td>
|
||||
<td>Description</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>id</td>
|
||||
<td>true</td>
|
||||
<td>URL</td>
|
||||
<td>ID of the file to delete</td>
|
||||
</tr>
|
||||
</table>
|
||||
<h3>Returns</h3>
|
||||
<pre>HTTP 200: OK
|
||||
{
|
||||
"success": true,
|
||||
"value": "file_deleted",
|
||||
"message": "The file has been deleted."
|
||||
}</pre>
|
||||
<pre>HTTP 404: Not Found
|
||||
{
|
||||
"success": false,
|
||||
"value": "file_not_found",
|
||||
"message": "File ID was not found in the database."
|
||||
}</pre>
|
||||
<pre>HTTP 401: Unauthorized
|
||||
{
|
||||
"success": false,
|
||||
"value": "unauthorized",
|
||||
"message": "You are not logged in."
|
||||
}</pre>
|
||||
<pre>HTTP 403: Forbidden
|
||||
{
|
||||
"success": false,
|
||||
"value": "forbidden",
|
||||
"message": "This is not your file."
|
||||
}</pre>
|
||||
</div>
|
||||
</details>
|
||||
{{end}}
|
8
res/template/fragments/bgpattern.html
Normal file
8
res/template/fragments/bgpattern.html
Normal file
@@ -0,0 +1,8 @@
|
||||
{{define "bgpattern"}}
|
||||
<style>
|
||||
body, .checkers{
|
||||
background-image: url("/res/img/checker{{bgPatternCount}}.png");
|
||||
background-attachment: fixed;
|
||||
}
|
||||
</style>
|
||||
{{end}}
|
6
res/template/fragments/footer.html
Normal file
6
res/template/fragments/footer.html
Normal file
@@ -0,0 +1,6 @@
|
||||
{{define "footer"}}
|
||||
<br/>
|
||||
<div class="highlight bg-dark border-top border-bottom">
|
||||
Pixeldrain is a product by <a href="//fornaxian.com" target="_blank">Fornaxian Technologies</a>.
|
||||
</div>
|
||||
{{end}}
|
7
res/template/fragments/menu.html
Normal file
7
res/template/fragments/menu.html
Normal file
@@ -0,0 +1,7 @@
|
||||
{{define "menu"}}
|
||||
<div class="highlight bg-light border-top border-bottom menu">
|
||||
<a href="/">Home</a> ~
|
||||
<a href="/history">My Files</a> ~
|
||||
<a href="/api">API Documentation</a>
|
||||
</div>
|
||||
{{end}}
|
53
res/template/history.html
Normal file
53
res/template/history.html
Normal file
@@ -0,0 +1,53 @@
|
||||
{{define "history-cookies"}}
|
||||
<!DOCTYPE html>
|
||||
<html xmlns:th="http://www.thymeleaf.org">
|
||||
<head>
|
||||
<title>Upload History ~ PixelDrain</title>
|
||||
<meta charset="UTF-8"/>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0"/>
|
||||
<link rel="stylesheet" href="/res/style/layout.css"/>
|
||||
<link rel="stylesheet" href="/res/style/season.css"/>
|
||||
<link rel="stylesheet" href="/res/style/history.css"/>
|
||||
<link href='https://fonts.googleapis.com/css?family=Ubuntu' rel='stylesheet' type='text/css'/>
|
||||
<link href="https://fonts.googleapis.com/css?family=Lato:100" rel="stylesheet" type="text/css"/>
|
||||
<link rel="shortcut icon" href="/res/img/tray32.png"/>
|
||||
<meta name="theme-color" content="#9FCF6C"/>
|
||||
<link rel="icon" sizes="180x180" href="/res/img/pixeldrain.png"/>
|
||||
<link rel="icon" sizes="256x256" href="/res/img/pixeldrain_big.png"/>
|
||||
|
||||
{{template "bgpattern"}}
|
||||
|
||||
<script src="res/script/jquery-2.1.4.min.js"></script>
|
||||
<script src="res/script/jquery-cookie.js"></script>
|
||||
<link rel="stylesheet" href="https://ajax.googleapis.com/ajax/libs/jqueryui/1.11.4/themes/smoothness/jquery-ui.css"/>
|
||||
<script src="https://ajax.googleapis.com/ajax/libs/jqueryui/1.11.4/jquery-ui.min.js"></script>
|
||||
|
||||
<meta name="description" content="PixelDrain is a free file sharing service, you
|
||||
can upload any file and you will be given a shareable link right away.
|
||||
PixelDrain also supports previews for images, videos, audio, PDFs and much more.
|
||||
Uncensored, unmonitored and unmoderated."/>
|
||||
<meta property="og:type" content="website" />
|
||||
<meta property="og:title" content="File Upload History ~ PixelDrain" />
|
||||
<meta property="og:site_name" content="PixelDrain" />
|
||||
<meta property="og:description" content="Instant file and screenshot sharing." />
|
||||
<meta property="og:url" content="http://pixeldra.in/" />
|
||||
<meta property="og:image" content="/res/img/pixeldrain_big.png" />
|
||||
<meta property="og:image:type" content="image/png" />
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div id='body' class="body">
|
||||
{{template "menu"}}
|
||||
<br/>
|
||||
Here are all files you have previously uploaded to PixelDrain using this computer.
|
||||
This data is saved locally in your web browser and gets updated every time you upload a file through your current browser.
|
||||
<br/><br/>
|
||||
|
||||
<div id="uploadedFiles" class="uploadedFiles"></div>
|
||||
{{template "footer"}}
|
||||
</div>
|
||||
<script src="/res/script/history.js"></script>
|
||||
{{template "analytics"}}
|
||||
</body>
|
||||
</html>
|
||||
{{end}}
|
152
res/template/home.html
Normal file
152
res/template/home.html
Normal file
@@ -0,0 +1,152 @@
|
||||
{{define "home"}}
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>PixelDrain ~ Free file sharing service</title>
|
||||
<meta charset="UTF-8"/>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0"/>
|
||||
<link rel="stylesheet" href="/res/style/home.css"/>
|
||||
<link rel="stylesheet" href="/res/style/layout.css"/>
|
||||
<link rel="stylesheet" href="/res/style/history.css"/>
|
||||
<link href='https://fonts.googleapis.com/css?family=Ubuntu' rel='stylesheet' type='text/css'/>
|
||||
<link href="https://fonts.googleapis.com/css?family=Lato:100" rel="stylesheet" type="text/css"/>
|
||||
<link rel="shortcut icon" href="/res/img/tray32.png"/>
|
||||
<meta name="theme-color" content="#9FCF6C"/>
|
||||
<link rel="icon" sizes="180x180" href="/res/img/pixeldrain.png"/>
|
||||
<link rel="icon" sizes="256x256" href="/res/img/pixeldrain_big.png"/>
|
||||
|
||||
{{template "bgpattern"}}
|
||||
|
||||
<script src="/res/script/jquery-2.1.4.min.js"></script>
|
||||
|
||||
<meta name="description" content="PixelDrain is a free file sharing service, you
|
||||
can upload any file and you will be given a shareable link right away.
|
||||
PixelDrain also supports previews for images, videos, audio, PDFs and much more.
|
||||
Uncensored, unmonitored and unmoderated."/>
|
||||
<meta property="og:type" content="website" />
|
||||
<meta property="og:title" content="Home ~ PixelDrain" />
|
||||
<meta property="og:site_name" content="PixelDrain" />
|
||||
<meta property="og:description" content="Instant file and screenshot sharing." />
|
||||
<meta property="og:url" content="http://pixeldra.in/" />
|
||||
<meta property="og:image" content="/res/img/pixeldrain_big.png" />
|
||||
<meta property="og:image:type" content="image/png" />
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<img id="header-image" src="/res/img/header_blackchancery.png" alt="Header image"/>
|
||||
<div id="body" class="body">
|
||||
{{template "menu"}}
|
||||
<div class="highlight bg-middle border-bottom">
|
||||
<input id="fileInputField" type="file" name="file" multiple='multiple'/>
|
||||
<button id="selectFileButton" class="big-button">Upload Files</button>
|
||||
<button id="textButton" class="big-button" onClick="window.location.href = '/t/'">Upload Text</button><br/>
|
||||
|
||||
<div id="progress-bar" class="progress-bar">
|
||||
<span class="progress-text"></span>
|
||||
<div id="upload-progress" class="progressbar-inner">
|
||||
<span class="progress-text"></span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="uploads-completed"></div>
|
||||
</div>
|
||||
<div class="highlight bg-dark border-bottom">
|
||||
<a id="btnOpenAsList" href="#">Open uploaded files as list</a>
|
||||
</div>
|
||||
|
||||
<h1>Pixeldrain Public Beta<img src="/res/img/sia.png" style="height: 40px;"/></h1>
|
||||
<p>
|
||||
Note that this is an experimental version of Pixeldrain server,
|
||||
the Pixeldrain backend has been completely redesigned from the
|
||||
ground up to be more extensible, efficient and scalable. The
|
||||
server this web application runs on is considered a testing
|
||||
environment. Database resets can happen at any moment when
|
||||
architectural changes need to be applied.
|
||||
</p>
|
||||
<p>
|
||||
The Sia integration is still very experimental and could
|
||||
fail at any moment resulting in data loss. Do not upload files
|
||||
to this server that you cannot afford to lose. Use the stable
|
||||
main server instead:
|
||||
<a href="https://pixeldrain.com">https://pixeldrain.com</a>.
|
||||
</p>
|
||||
<p>
|
||||
But don't let all that stop you from trying the new Pixeldrain!
|
||||
The upload restrictions that the main site has haven't been
|
||||
implemented in this version yet, so you can upload as much as
|
||||
you want. The server only has 256 GiB of space available, if it
|
||||
runs out before the Sia integration is stable I won't hesitate
|
||||
to wipe the database and start over.
|
||||
</p>
|
||||
<h2>Legality</h2>
|
||||
<p>
|
||||
I cannot be held liable for any illegal and / or copyrighted
|
||||
material that's uploaded by the users of this application.
|
||||
Files uploaded to this website are subjected to local laws. If
|
||||
laws are being broken, and I've been notified of the fact I'll
|
||||
have to delete the offending content (as the server does not
|
||||
support geo filtering yet). If you find any files on this domain
|
||||
that break the law, please contact me at
|
||||
<a href="mailto:abuse@pixeldrain.com">abuse@pixeldrain.com</a>,
|
||||
and I'll take care of it.
|
||||
<br/>Please share responsibly.
|
||||
</p>
|
||||
<h2>Funding</h2>
|
||||
<p>
|
||||
I'm currently paying for the Sia storage myself, since the site
|
||||
doesn't have a revenue model yet. I'd appreciate it if you could
|
||||
send some Siacoins my way:
|
||||
26117c19ca3975b315d663dcbbc19cf9c07274f441689d4392ed380b2337589ef1aacfbdc93f.
|
||||
This address goes directly to the wallet on this server which is
|
||||
used for uploading files to Sia :). I promise you it will be put
|
||||
to good use!
|
||||
</p>
|
||||
<h2>Features</h2>
|
||||
<p>
|
||||
Here's a list of features this version of Pixeldrain has.
|
||||
</p>
|
||||
<h3>New</h3>
|
||||
<ul>
|
||||
<li>Files are replicated to the Sia network</li>
|
||||
<li>New API and documentation (<a href="/api">Check it out!</a>)</li>
|
||||
<li>Overhauled design, no ugly white glow around the site body</li>
|
||||
</ul>
|
||||
<h3>Upcoming</h3>
|
||||
<ul>
|
||||
<li>File and list management API</li>
|
||||
<li>File metadata, allowing applications to attach their own properties to a file (descriptions, icons, views, etc)</li>
|
||||
<li>Buttons to favorite and copy files to your account, so you can find them back later</li>
|
||||
<li>Pasting files from the clipboard</li>
|
||||
<li>Current viewer count on files/lists</li>
|
||||
<li>File revisions (update a file without changing the URL)</li>
|
||||
<li>Proper file manager with directories (still far away)</li>
|
||||
<li>Plenty more!</li>
|
||||
</ul>
|
||||
<h3>Missing</h3>
|
||||
<p>
|
||||
Features which are in
|
||||
<a href="https://pixeldrain.com">https://pixeldrain.com</a>, but
|
||||
not in <a href="https://sia.pixeldrain.com">https://sia.pixeldrain.com</a>.
|
||||
These will be added soon enough.
|
||||
</p>
|
||||
<ul>
|
||||
<li>File lists</li>
|
||||
<li>Zip explorer</li>
|
||||
<li>Text file viewer (yes, you can upload text but not view it yet)</li>
|
||||
<li>Some video formats (mime type detection is not complete)</li>
|
||||
<li>Registration / Login system</li>
|
||||
<li>Bandwidth Tracker</li>
|
||||
<li>View counter</li>
|
||||
<li>Seasonal themes</li>
|
||||
</ul>
|
||||
{{template "footer"}}
|
||||
</div>
|
||||
|
||||
<script type="text/javascript">var API_URL = "/api";</script>
|
||||
<script src="/res/script/Cookie.js"></script>
|
||||
<script src="/res/script/home.js"></script>
|
||||
<script src="/res/script/openlist.js"></script>
|
||||
{{template "analytics"}}
|
||||
</body>
|
||||
</html>
|
||||
{{end}}
|
82
res/template/paste.html
Normal file
82
res/template/paste.html
Normal file
@@ -0,0 +1,82 @@
|
||||
{{define "paste"}}
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>Paste ~ PixelDrain</title>
|
||||
<meta charset="UTF-8"/>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0"/>
|
||||
<link rel="stylesheet" href="/res/style/viewer.css"/>
|
||||
<link rel="stylesheet" href="/res/style/season.css"/>
|
||||
<link rel="stylesheet" href="/res/style/paste.css"/>
|
||||
<link href='https://fonts.googleapis.com/css?family=Ubuntu' rel='stylesheet' type='text/css'/>
|
||||
<link rel="shortcut icon" href="/res/img/tray32.png"/>
|
||||
<meta name="theme-color" content="#9FCF6C"/>
|
||||
<link rel="icon" sizes="180x180" href="res/img/pixeldrain.png"/>
|
||||
<link rel="icon" sizes="256x256" href="res/img/pixeldrain_big.png"/>
|
||||
|
||||
<style th:include="fragments :: background-pattern" th:inline="text"></style>
|
||||
|
||||
<script src="/res/script/jquery-2.1.4.min.js"></script>
|
||||
<link rel="stylesheet" href="https://ajax.googleapis.com/ajax/libs/jqueryui/1.11.4/themes/smoothness/jquery-ui.css"/>
|
||||
<script src="https://ajax.googleapis.com/ajax/libs/jqueryui/1.11.4/jquery-ui.min.js"></script>
|
||||
|
||||
<meta property="og:type" content="website" />
|
||||
<meta property="og:title" content="Paste ~ PixelDrain" />
|
||||
<meta property="og:site_name" content="PixelDrain" />
|
||||
<meta property="og:description" content="Upload text to PixelDrain" />
|
||||
<meta property="article:author" content="Fornax96" />
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div id="filepreview">
|
||||
<textarea id="textarea"
|
||||
class="textarea"
|
||||
placeholder="Your text here..."
|
||||
autofocus="autofocus"></textarea>
|
||||
</div>
|
||||
<div id="toolbar">
|
||||
<!-- Ugly workaround to get rid of the scrollbar in non-webkit browsers -->
|
||||
<div>
|
||||
<div>
|
||||
<button class="toolbar-button" onClick="uploadText();">
|
||||
<img src="/res/img/upload_small.png" alt="Start Upload"/>
|
||||
<span>Upload</span>
|
||||
</button>
|
||||
<form action="/">
|
||||
<button class="toolbar-button">
|
||||
<img src="/res/img/pixeldrain_small.png" alt="Visit the home page" style="width:22px; height: 22px;"/>
|
||||
<span>Home</span>
|
||||
</button>
|
||||
</form>
|
||||
<iframe id='sponsors' data-aa='73974'
|
||||
src='//ad.a-ads.com/73974?size=120x600&background_color=000000&text_color=eeeeee&title_color=eeeeee&link_color=9fcf6c&link_hover_color=d2ffa1&title_hover_color=d2ffa1'
|
||||
scrolling='no' allowtransparency='true' seamless="seamless">
|
||||
</iframe>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script src="/res/script/Cookie.js"></script>
|
||||
<script src="/res/script/paste.js"></script>
|
||||
|
||||
<!-- Google Analytics Tracking code -->
|
||||
<script>
|
||||
(function (i, s, o, g, r, a, m) {
|
||||
i['GoogleAnalyticsObject'] = r;
|
||||
i[r] = i[r] || function () {
|
||||
(i[r].q = i[r].q || []).push(arguments)
|
||||
}, i[r].l = 1 * new Date();
|
||||
a = s.createElement(o),
|
||||
m = s.getElementsByTagName(o)[0];
|
||||
a.async = 1;
|
||||
a.src = g;
|
||||
m.parentNode.insertBefore(a, m)
|
||||
})(window, document, 'script', '//www.google-analytics.com/analytics.js', 'ga');
|
||||
|
||||
ga('create', 'UA-24463738-4', 'auto');
|
||||
ga('send', 'pageview');
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
{{end}}
|
Reference in New Issue
Block a user