Adding snufficon
|
@ -1,4 +1,2 @@
|
|||
- Requires `SQLite3` (`sudo apt install php-sqlite3` on Debian)
|
||||
- API requires mod_rewrite (`sudo a2enmod rewrite`) and configuring `AllowOverride all` for .htaccess
|
||||
|
||||
The icon is from https://www.flaticon.com/free-icon/hedgehog_10807489
|
||||
|
|
BIN
favicon.ico
Before Width: | Height: | Size: 1 MiB |
BIN
icon.png
Before Width: | Height: | Size: 29 KiB |
19
index.php
|
@ -1,5 +1,11 @@
|
|||
<?php
|
||||
require_once "inc/database.php";
|
||||
function getRandomIcon() {
|
||||
$files = glob('./snufficon/*.png');
|
||||
$random_file_num = array_rand($files);
|
||||
return $files[$random_file_num];;
|
||||
}
|
||||
$randomicon = getRandomIcon();
|
||||
$database = new DataBase();
|
||||
if(!$database) {
|
||||
die($database->lastErrorMsg());
|
||||
|
@ -10,7 +16,7 @@ if(!$database) {
|
|||
<head>
|
||||
<meta charset="UTF-8" />
|
||||
<link rel="stylesheet" href="style.css" />
|
||||
<link rel="icon" type="image/x-icon" href="icon.png">
|
||||
<link rel="icon" type="image/x-icon" href="snufficon/happy.png">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
||||
<title>Snuffler</title>
|
||||
</head>
|
||||
|
@ -33,7 +39,7 @@ if(!$database) {
|
|||
</div>
|
||||
|
||||
<div id="centerbox">
|
||||
<div id="titlebox"><img src="icon.png" alt="" />Snuffler</div>
|
||||
<div id="titlebox"><img src="<?php echo $randomicon; ?>" alt="" />Snuffler</div>
|
||||
|
||||
<?php
|
||||
if (!$database->getAuthedUserId()) {
|
||||
|
@ -77,7 +83,14 @@ foreach($posts as $post) {
|
|||
echo '<br><small>@' . $post["user.handle"] . '</small>';
|
||||
echo '<p>' . $post["post.text"] . '</p>';
|
||||
echo '<hr><small>' . date("D j.n.Y \@ G:i", $post["post.time"]) . '</small>';
|
||||
echo '<span class="postactions">👍5 👎0 💬2</span>';
|
||||
echo '
|
||||
<span class="postactions">
|
||||
<img class="reactionaction" src="snufficon/thumbs_up.png" />
|
||||
<img class="reactionaction" src="snufficon/thumbs_down.png" />
|
||||
<img class="reactionaction" src="snufficon/joy.png" />
|
||||
<img class="reactionaction" src="snufficon/sob.png" />
|
||||
<img class="reactionaction" src="snufficon/heart_eyes.png" />
|
||||
</span>';
|
||||
echo "</div>";
|
||||
|
||||
}
|
||||
|
|
BIN
snufficon/angel.png
Normal file
After Width: | Height: | Size: 9.1 KiB |
BIN
snufficon/angry.png
Normal file
After Width: | Height: | Size: 8.6 KiB |
BIN
snufficon/cat_face.png
Normal file
After Width: | Height: | Size: 10 KiB |
BIN
snufficon/clown.png
Normal file
After Width: | Height: | Size: 18 KiB |
BIN
snufficon/cold.png
Normal file
After Width: | Height: | Size: 19 KiB |
BIN
snufficon/cold_sweat.png
Normal file
After Width: | Height: | Size: 13 KiB |
BIN
snufficon/cowboy.png
Normal file
After Width: | Height: | Size: 8.2 KiB |
BIN
snufficon/cross_eyes.png
Normal file
After Width: | Height: | Size: 8.3 KiB |
BIN
snufficon/disappointed_relieved.png
Normal file
After Width: | Height: | Size: 11 KiB |
BIN
snufficon/drool.png
Normal file
After Width: | Height: | Size: 10 KiB |
BIN
snufficon/exploding_head.png
Normal file
After Width: | Height: | Size: 12 KiB |
BIN
snufficon/expressionless.png
Normal file
After Width: | Height: | Size: 7.9 KiB |
BIN
snufficon/fearful.png
Normal file
After Width: | Height: | Size: 10 KiB |
BIN
snufficon/flush.png
Normal file
After Width: | Height: | Size: 11 KiB |
BIN
snufficon/giggle.png
Normal file
After Width: | Height: | Size: 13 KiB |
BIN
snufficon/hand_over_mouth.png
Normal file
After Width: | Height: | Size: 9.3 KiB |
BIN
snufficon/happy.png
Normal file
After Width: | Height: | Size: 8.8 KiB |
BIN
snufficon/head_bandage.png
Normal file
After Width: | Height: | Size: 9.4 KiB |
BIN
snufficon/heart_eyes.png
Normal file
After Width: | Height: | Size: 12 KiB |
BIN
snufficon/holding_back_tears.png
Normal file
After Width: | Height: | Size: 9.8 KiB |
BIN
snufficon/hot.png
Normal file
After Width: | Height: | Size: 21 KiB |
BIN
snufficon/hug.png
Normal file
After Width: | Height: | Size: 13 KiB |
BIN
snufficon/joy.png
Normal file
After Width: | Height: | Size: 9.6 KiB |
BIN
snufficon/kissing.png
Normal file
After Width: | Height: | Size: 13 KiB |
BIN
snufficon/kissing_heart.png
Normal file
After Width: | Height: | Size: 9 KiB |
BIN
snufficon/laughing.png
Normal file
After Width: | Height: | Size: 8.2 KiB |
BIN
snufficon/lying.png
Normal file
After Width: | Height: | Size: 8.2 KiB |
BIN
snufficon/mask.png
Normal file
After Width: | Height: | Size: 7.9 KiB |
BIN
snufficon/melting.png
Normal file
After Width: | Height: | Size: 11 KiB |
BIN
snufficon/money_face.png
Normal file
After Width: | Height: | Size: 9.9 KiB |
BIN
snufficon/mouthless.png
Normal file
After Width: | Height: | Size: 7.6 KiB |
BIN
snufficon/nerd.png
Normal file
After Width: | Height: | Size: 9.7 KiB |
BIN
snufficon/partying.png
Normal file
After Width: | Height: | Size: 15 KiB |
BIN
snufficon/peeking_eye.png
Normal file
After Width: | Height: | Size: 10 KiB |
BIN
snufficon/pleading_face.png
Normal file
After Width: | Height: | Size: 9.7 KiB |
BIN
snufficon/raging.png
Normal file
After Width: | Height: | Size: 18 KiB |
BIN
snufficon/raised_eyebrow.png
Normal file
After Width: | Height: | Size: 8.7 KiB |
BIN
snufficon/rolling_eyes.png
Normal file
After Width: | Height: | Size: 8.8 KiB |
BIN
snufficon/sad.png
Normal file
After Width: | Height: | Size: 7.9 KiB |
BIN
snufficon/saluting.png
Normal file
After Width: | Height: | Size: 8.5 KiB |
BIN
snufficon/scream.png
Normal file
After Width: | Height: | Size: 13 KiB |
BIN
snufficon/see_no_evil.png
Normal file
After Width: | Height: | Size: 9.8 KiB |
BIN
snufficon/shrug.png
Normal file
After Width: | Height: | Size: 11 KiB |
BIN
snufficon/shush.png
Normal file
After Width: | Height: | Size: 9.9 KiB |
BIN
snufficon/sick.png
Normal file
After Width: | Height: | Size: 20 KiB |
BIN
snufficon/sleeping.png
Normal file
After Width: | Height: | Size: 9 KiB |
BIN
snufficon/smiling.png
Normal file
After Width: | Height: | Size: 12 KiB |
BIN
snufficon/smiling_with_hearts.png
Normal file
After Width: | Height: | Size: 14 KiB |
BIN
snufficon/smiling_with_stars.png
Normal file
After Width: | Height: | Size: 12 KiB |
BIN
snufficon/smirk.png
Normal file
After Width: | Height: | Size: 8.6 KiB |
BIN
snufficon/sneeze.png
Normal file
After Width: | Height: | Size: 9.5 KiB |
BIN
snufficon/sob.png
Normal file
After Width: | Height: | Size: 11 KiB |
BIN
snufficon/spiral_eyes.png
Normal file
After Width: | Height: | Size: 13 KiB |
BIN
snufficon/star_struck.png
Normal file
After Width: | Height: | Size: 9.4 KiB |
BIN
snufficon/sunglasses.png
Normal file
After Width: | Height: | Size: 8.6 KiB |
BIN
snufficon/swearing.png
Normal file
After Width: | Height: | Size: 17 KiB |
BIN
snufficon/sweat.png
Normal file
After Width: | Height: | Size: 8.7 KiB |
BIN
snufficon/sweat_smile.png
Normal file
After Width: | Height: | Size: 11 KiB |
BIN
snufficon/thermometer.png
Normal file
After Width: | Height: | Size: 13 KiB |
BIN
snufficon/thinking.png
Normal file
After Width: | Height: | Size: 10 KiB |
BIN
snufficon/thumbs_down.png
Normal file
After Width: | Height: | Size: 13 KiB |
BIN
snufficon/thumbs_up.png
Normal file
After Width: | Height: | Size: 13 KiB |
BIN
snufficon/tongue_out.png
Normal file
After Width: | Height: | Size: 9.3 KiB |
BIN
snufficon/tongue_out_closed_eyes.png
Normal file
After Width: | Height: | Size: 8.8 KiB |
BIN
snufficon/tongue_out_winking.png
Normal file
After Width: | Height: | Size: 8.6 KiB |
BIN
snufficon/triumph.png
Normal file
After Width: | Height: | Size: 11 KiB |
BIN
snufficon/upside_down.png
Normal file
After Width: | Height: | Size: 8.2 KiB |
BIN
snufficon/vomiting.png
Normal file
After Width: | Height: | Size: 11 KiB |
BIN
snufficon/wink.png
Normal file
After Width: | Height: | Size: 8.6 KiB |
BIN
snufficon/woozy.png
Normal file
After Width: | Height: | Size: 12 KiB |
BIN
snufficon/yawning.png
Normal file
After Width: | Height: | Size: 9.3 KiB |
BIN
snufficon/zany.png
Normal file
After Width: | Height: | Size: 10 KiB |
BIN
snufficon/zipper_mouth.png
Normal file
After Width: | Height: | Size: 8.6 KiB |
BIN
snuffmoji/angel.png
Normal file
After Width: | Height: | Size: 9.1 KiB |
BIN
snuffmoji/angry.png
Normal file
After Width: | Height: | Size: 8.6 KiB |
BIN
snuffmoji/cat_face.png
Normal file
After Width: | Height: | Size: 10 KiB |
BIN
snuffmoji/clown.png
Normal file
After Width: | Height: | Size: 18 KiB |
BIN
snuffmoji/cold.png
Normal file
After Width: | Height: | Size: 19 KiB |
BIN
snuffmoji/cold_sweat.png
Normal file
After Width: | Height: | Size: 13 KiB |
BIN
snuffmoji/cowboy.png
Normal file
After Width: | Height: | Size: 8.2 KiB |
BIN
snuffmoji/cross_eyes.png
Normal file
After Width: | Height: | Size: 8.3 KiB |
BIN
snuffmoji/disappointed_relieved.png
Normal file
After Width: | Height: | Size: 11 KiB |
BIN
snuffmoji/drool.png
Normal file
After Width: | Height: | Size: 10 KiB |
BIN
snuffmoji/exploding_head.png
Normal file
After Width: | Height: | Size: 12 KiB |
BIN
snuffmoji/expressionless.png
Normal file
After Width: | Height: | Size: 7.9 KiB |
BIN
snuffmoji/fearful.png
Normal file
After Width: | Height: | Size: 10 KiB |
BIN
snuffmoji/flush.png
Normal file
After Width: | Height: | Size: 11 KiB |
BIN
snuffmoji/giggle.png
Normal file
After Width: | Height: | Size: 13 KiB |
BIN
snuffmoji/hand_over_mouth.png
Normal file
After Width: | Height: | Size: 9.3 KiB |
BIN
snuffmoji/happy.png
Normal file
After Width: | Height: | Size: 8.8 KiB |
BIN
snuffmoji/head_bandage.png
Normal file
After Width: | Height: | Size: 9.4 KiB |
BIN
snuffmoji/heart_eyes.png
Normal file
After Width: | Height: | Size: 12 KiB |
BIN
snuffmoji/holding_back_tears.png
Normal file
After Width: | Height: | Size: 9.8 KiB |
BIN
snuffmoji/hot.png
Normal file
After Width: | Height: | Size: 21 KiB |
BIN
snuffmoji/hug.png
Normal file
After Width: | Height: | Size: 13 KiB |
BIN
snuffmoji/joy.png
Normal file
After Width: | Height: | Size: 9.6 KiB |