More shit

This commit is contained in:
flash 2015-05-03 16:25:57 +00:00
parent edd97209ff
commit ff488c6b84
13 changed files with 389 additions and 141 deletions

View file

@ -20,7 +20,9 @@
"20150428",
"20150429",
"20150430",
"20150501"
"20150501",
"20150502",
"20150503"
]
@ -856,6 +858,28 @@
"change": "Improve error page."
}
],
"20150502": [
{
"type": "ADD",
"change": "Add supporter page."
}
],
"20150503": [
{
"type": "UPD",
"change": "Improved manage navigation."
},
{
"type": "ADD",
"change": "Begin work on forum script."
}
]
}

View file

@ -0,0 +1,12 @@
<?php
/*
* Discussion Board
*/
namespace Sakura;
class Forum {
}

View file

@ -8,7 +8,7 @@
namespace Sakura;
// Define Sakura version
define('SAKURA_VERSION', '20150501');
define('SAKURA_VERSION', '20150503');
define('SAKURA_VLABEL', 'Heliotrope');
define('SAKURA_VTYPE', 'Development');
define('SAKURA_COLOUR', '#DF73FF');
@ -35,6 +35,7 @@ require_once ROOT .'_sakura/components/Configuration.php';
require_once ROOT .'_sakura/components/Templates.php';
require_once ROOT .'_sakura/components/Sessions.php';
require_once ROOT .'_sakura/components/Users.php';
require_once ROOT .'_sakura/components/Forum.php';
require_once ROOT .'_sakura/components/Manage.php';
require_once ROOT .'_sakura/components/Whois.php';
require_once ROOT .'_sakura/components/SockChat.php';

View file

@ -19,21 +19,28 @@
<div id="container">
<span id="top"></span>
<div class="header" id="header">
<a class="logo" href="/">
Broom Closet{{ page.activepage }} {{ page.activesub }}
</a>
<div class="logo">
<a href="/">Broom Closet</a> /
<a href="/{{ page.activepage }}/">{{ page.pages[page.activepage].desc }}</a> /
<a href="/{{ page.activepage }}/{{ page.activesub }}/">{{ page.pages[page.activepage].subs[page.activesub].desc }}</a>
</div>
<div class="nav">
{% for short,mode in page.pages %}
<div class="menu" id="{{ short }}Nav">
<div>{{ mode.desc|raw }}</div>
{% for short,page in mode.pages %}
<a href="/{{ short }}/">{{ page.title }}</a>
<div class="menu" id="siteNav">
<div style="color: {{ user.colour }};">{{ user.data.username }}</div>
<a href="//{{ sakura.urls.main }}/">Return to Site Index</a>
<a href="//{{ sakura.urls.main }}/logout?mode=logout&time={{ php.time }}&session={{ php.sessionid }}&redirect=//{{ sakura.urls.main }}/">Logout</a>
</div>
<div class="menu" id="pageNav">
<div>Navigation</div>
{% for short,page in page.pages %}
<a href="/{{ short }}/">{{ page.desc }}</a>
{% endfor %}
</div>
{% endfor %}
</div>
<div class="menu" id="subNav">
<div>Section title here</div>
<a href="#">Front page</a>
<div>{{ page.pages[page.activepage].desc }}</div>
{% for short,sub in page.pages[page.activepage].subs %}
<a href="/{{ page.activepage }}/{{ short }}/">{{ sub.desc }}</a>
{% endfor %}
</div>
</div>
</div>

View file

@ -0,0 +1,37 @@
{% include 'global/header.tpl' %}
<h1>Latest 5 reports</h1>
<table>
<thead>
<tr>
<th>
Subject
</th>
<th>
User reported
</th>
<th>
Reporter
</th>
<th>
Report time
</th>
</tr>
</thead>
<tbody>
<tr>
<th>
Faggot exists really
</th>
<th>
Nippon Nick
</th>
<th>
Japan Joe
</th>
<th>
1969-69-69 69:69:69 JST
</th>
</tr>
</tbody>
</table>
{% include 'global/footer.tpl' %}

View file

@ -1,3 +1,3 @@
{% include 'global/header.tpl' %}
<a href="#">meow</a>
{% include 'global/footer.tpl' %}

View file

@ -121,7 +121,7 @@
<a class="menu-item" href="//{{ sakura.urls.chat }}/" title="Chat with other Flashii members">Chat</a>
{% if user.checklogin %}
<a class="menu-item" href="//{{ sakura.urls.main }}/members" title="View a list with all the activated user accounts">Members</a>
<a class="menu-item menu-donate" href="//{{ sakura.urls.main }}/support" title="Give us money to keep the site (and other services) up and running">Support</a>
<a class="menu-item menu-donate" href="//{{ sakura.urls.main }}/support" title="Give us money to keep the site (and other services) up and running">Support us</a>
{% endif %}
</div>
<div class="menu-ucp" id="navMenuUser">

View file

@ -0,0 +1,60 @@
{% include 'global/header.tpl' %}
<div class="content donate">
{#<h1 style="font-size: 5em; line-height: 1.5em;">Note to Flashwave: Don't forget to update this with the proper shit.</h1>#}
<div class="head">Support Flashii (Get Tenshi)</div>
<div style="font-size: .9em; margin-bottom: 10px;">
<p>In order to keep the site, its services and improvements on it going I need money but I'm not that big of a fan of asking for money without really giving anything special in return.</p>
<p>Thus Tenshi exists. Tenshi is the &quot;premium&quot; user group on Flashii which gives you access to an extra set of features (which are listed further down on this page).</p>
<p>A set of new features is planned as well! Be sure to look out for them.</p>
</div>
<div class="sectionHeader">
Why should I get Tenshi?
<div style="float: right; font-size: 10px; text-align: right;">
Click a box to expand its contents.
</div>
</div>
<div class="featureParent">
{% for id,box in page.whytenshi %}
<div class="featureBox" id="fbw{{ id }}" onclick="donatePage(this.id);">
<div class="featureBoxHeader">
{{ box[0]|raw }}
</div>
<div class="featureBoxDesc">
{{ box[1]|raw }}
</div>
</div>
{% endfor %}
</div>
<div class="sectionHeader">
What do I get in return?
<div style="float: right; font-size: 10px; text-align: right;">
Click a box to expand its contents.
</div>
</div>
<div class="featureParent">
{% for id,box in page.tenshifeatures %}
<div class="featureBox" id="fbr{{ id }}" onclick="donatePage(this.id);">
<div class="featureBoxHeader">
{{ box[0]|raw }}
</div>
<div class="featureBoxDesc">
{{ box[1]|raw }}
</div>
</div>
{% endfor %}
</div>
<div class="sectionHeader">Payment Options</div>
{% if user.checklogin %}
<span style="font-size: 8pt;">We do not (and probably will never) accept cryptocurrencies, sorry. Right now the only option is PayPal but we'll try to add more options in the future.</span>
<form action="https://www.paypal.com/cgi-bin/webscr" method="post" target="_top" class="paypal-donate-form">
<input type="hidden" name="cmd" value="_s-xclick" />
<input type="hidden" name="encrypted" value="-----BEGIN PKCS7-----MIIHVwYJKoZIhvcNAQcEoIIHSDCCB0QCAQExggEwMIIBLAIBADCBlDCBjjELMAkGA1UEBhMCVVMxCzAJBgNVBAgTAkNBMRYwFAYDVQQHEw1Nb3VudGFpbiBWaWV3MRQwEgYDVQQKEwtQYXlQYWwgSW5jLjETMBEGA1UECxQKbGl2ZV9jZXJ0czERMA8GA1UEAxQIbGl2ZV9hcGkxH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UYp4FnGPuA88+qJHjwZmt3TV2R6Jg4/H8R4dQ3958pcxDOpVjeg6o/vn+PhYbik6wBC6n1q9+oOsx9MNhmJPWBFeA2tiJ3aSFQ/QkfrI7fB6de54ywl58sAqC+opGA/ld3zUMzUJJ7nGopSeqX1dawpj2sc=-----END PKCS7-----" />
<input type="image" src="https://www.paypalobjects.com/en_US/GB/i/btn/btn_donateCC_LG.gif" name="submit" alt="PayPal The safer, easier way to pay online." style="border: 0;" />
<img alt="" src="https://www.paypalobjects.com/en_US/i/scr/pixel.gif" style="border: 0; width: 1px; height: 1px;" />
</form>{#<h1 style="text-align: center;">&lt;PayPal donate button here&gt;</h1>#}
{% else %}
<h1 style="text-align: center;">You need to be logged in to donate!</h1>
{% endif %}
</div>
<script type="text/javascript">window.onload = function() {donatePage();}</script>
{% include 'global/footer.tpl' %}

View file

@ -61,9 +61,12 @@ a:active {
font-size: 3em;
line-height: 1.7em;
margin: 0 20px;
display: inline-block;
}
.header > .logo > a {
color: inherit !important;
text-decoration: none !important;
display: inline-block;
}
.header > .nav {

18
forum/index.php Normal file
View file

@ -0,0 +1,18 @@
<?php
/*
* Sakura Forum Index
*/
// Declare Namespace
namespace Sakura;
// Include components
require_once str_replace(basename(__DIR__), '', dirname(__FILE__)) .'_sakura/sakura.php';
// Add page specific things
$renderData['page'] = [
'title' => Configuration::getConfig('sitename') .' Forum'
];
// Print page contents
print Templates::render('forum/index.tpl', $renderData);

View file

@ -18,7 +18,7 @@ RewriteRule ^feedback?/?$ http://forum.flash.moe/viewforum.php?f=22
RewriteRule ^credits?/?$ credits.php
RewriteRule ^index?/?$ index.php
RewriteRule ^login?/?$|logout?/?$|activate?/?$|register?/?$|forgotpassword?/?|authenticate?/?$ authenticate.php
RewriteRule ^donate?/?$|support?/?$ support.php
RewriteRule ^donate?/?$|support?/?$ donate.php
RewriteRule ^contact?/?$ infopage.php?r=contact
RewriteRule ^changelog?/?$ changelog.php
RewriteRule ^faq?/?$ faq.php

70
main/donate.php Normal file
View file

@ -0,0 +1,70 @@
<?php
/*
* Sakura Support/Donate page
*/
// Declare Namespace
namespace Sakura;
// Include components
require_once str_replace(basename(__DIR__), '', dirname(__FILE__)) .'_sakura/sakura.php';
// Set default variables
$renderData['page'] = [
'title' => 'Support Flashii',
'whytenshi' => [
[
'Maintained by one person!',
'The site, server and it\'s code are all maintained and paid for by one guy in the Netherlands.'
],
[
'No ads!',
'Unlike a good chunk of the internet we don\'t make money by shoving ads in your face.'
],
[
'Helping us survive!',
'It helps us with getting new hardware to make your Flashii Experience&trade; better and paying the bills to stay alive.'
],
[
'Extra features!',
'You get some extra things to play with if you donate more than $5!'
]
],
'tenshifeatures' => [
[
'A special colour',
'Your username will be <span style="font-weight:bold;color:#EE9400;">orange</span> so you can be recognised in chat and elsewhere on the site!'
],
[
'Early access',
'You get early access to new features before regular users such as access the developement domain.'
],
[
'Username',
'You get the ability to change your username once a month.'
],
[
'User title',
'You get the ability to change your user title whenever you wish to.'
],
[
'Chat logs',
'<del>You can read the <a class="default" href="http://chat.flashii.net/logs" target="_blank">chat logs</a> where all the messages since the original launch are saved.</del><br />Temporarily unavailable due to permissioning issues, <a href="/u/303" class="default">go yell at malloc</a>.'
],
[
'Private channel',
'You get your own Private Channel in the Chat.'
],
[
'Profile background',
'You get the ability to set a custom background on your profile.'
],
[
'A good feeling',
'You get the good feeling of helping me keep Flashii alive and growing (and of course the fact that you get all your special stuff that you can brag about to regular users).'
]
]
];
// Print page contents
print Templates::render('main/donate.tpl', $renderData);

View file

@ -5,140 +5,140 @@
// Declare Namespace
namespace Sakura;
die('<h1>still broom closet</h1>');
// Define that we are in Management mode
define('SAKURA_MANAGE', true);
// Include components
require_once str_replace(basename(__DIR__), '', dirname(__FILE__)) .'_sakura/sakura.php';
// Management pages
// Management pages
$managePages = [
// Moderation
'mod' => [
'desc' => '<span style="color: #0C0;">Moderator</span> actions',
'pages' => [
'index' => [
'title' => 'Index',
'sub' => [
'front-page' => [
'desc' => 'Front Page'
]
]
],
'message-board' => [
'title' => 'Message Board',
'sub' => []
],
'reports' => [
'title' => 'Reports',
'sub' => []
],
'banning' => [
'title' => 'Banning',
'sub' => []
],
'warnings' => [
'title' => 'Warnings',
'sub' => []
],
'user-notes' => [
'title' => 'User notes',
'sub' => []
],
'action-logs' => [
'title' => 'Action Logs',
'sub' => []
'index' => [
'desc' => 'Index',
'subs' => [
'front-page' => [
'desc' => 'Front Page'
]
]
],
// Administrative
'adm' => [
'desc' => '<span style="color: #C00;">Administrator</span> actions',
'pages' => [
'statistics' => [
'title' => 'Statistics',
'sub' => []
],
'general-settings' => [
'title' => 'General Settings',
'sub' => []
],
'users' => [
'title' => 'Users',
'sub' => []
],
'ranks' => [
'title' => 'Ranks',
'sub' => []
],
'permissions' => [
'title' => 'Permissions',
'sub' => []
],
'customise' => [
'title' => 'Customise',
'sub' => []
],
'system' => [
'title' => 'System',
'sub' => []
'reports' => [
'desc' => 'Reports',
'subs' => [
'front-page' => [
'desc' => 'Front Page'
]
]
],
'banning' => [
'desc' => 'Banning',
'subs' => [
'front-page' => [
'desc' => 'Front Page'
]
]
],
'warnings' => [
'desc' => 'Warnings',
'subs' => [
'front-thing' => [
'desc' => 'thing'
]
]
],
'user-notes' => [
'desc' => 'User notes',
'subs' => [
'front-page' => [
'desc' => 'Front Page'
]
]
],
'action-logs' => [
'desc' => 'Action logs',
'subs' => [
'front-page' => [
'desc' => 'Front Page'
]
]
],
'action-logs' => [
'desc' => 'Action logs',
'subs' => [
'front-page' => [
'desc' => 'Front Page'
]
]
],
'statistics' => [
'desc' => 'Statistics',
'subs' => [
'front-page' => [
'desc' => 'Front Page'
]
]
],
'general-settings' => [
'desc' => 'General Settings',
'subs' => [
'front-page' => [
'desc' => 'Front Page'
]
]
],
'users' => [
'desc' => 'Users',
'subs' => [
'front-page' => [
'desc' => 'Front Page'
]
]
],
'ranks' => [
'desc' => 'Ranks',
'subs' => [
'front-page' => [
'desc' => 'Front Page'
]
]
],
'permissions' => [
'desc' => 'Permissions',
'subs' => [
'front-page' => [
'desc' => 'Front Page'
]
]
],
'info-pages' => [
'desc' => 'Info pages',
'subs' => [
'front-page' => [
'desc' => 'Front Page'
]
]
],
'system' => [
'desc' => 'System',
'subs' => [
'front-page' => [
'desc' => 'Front Page'
]
]
]
];
@ -148,11 +148,27 @@ $renderData['page'] = [
'title' => 'Manage Index',
'pages' => $managePages,
'activepage' => ,
'subs' => ,
'activesub' =>
'activepage' => $_MANAGE_ACTIVE_PAGE = (
isset($_GET['page']) ?
(
array_key_exists($_GET['page'], $managePages) ?
$_GET['page'] :
key($managePages)
) :
key($managePages)
),
'subs' => $_MANAGE_SUBS = $managePages[$_MANAGE_ACTIVE_PAGE]['subs'],
'activesub' => $_MANAGE_ACTIVE_SUB = (
isset($_GET['sub']) ?
(
array_key_exists($_GET['sub'], $_MANAGE_SUBS) ?
$_GET['sub'] :
key($_MANAGE_SUBS)
) :
key($_MANAGE_SUBS)
)
];
// Print page contents
print Templates::render('main/index.tpl', $renderData);
print Templates::render('pages/'. $_MANAGE_ACTIVE_PAGE .'/'. $_MANAGE_ACTIVE_SUB .'.tpl', $renderData);