My personal blog. https://blog.airikr.me
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

210 lines
5.2 KiB

-- phpMyAdmin SQL Dump
-- version 4.9.7
-- https://www.phpmyadmin.net/
--
-- Host: localhost:3306
-- Generation Time: Jun 09, 2021 at 02:39 PM
-- Server version: 10.3.27-MariaDB-0+deb10u1
-- PHP Version: 7.4.18
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET AUTOCOMMIT = 0;
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8mb4 */;
--
-- Database: `blog`
--
CREATE DATABASE IF NOT EXISTS `blog` DEFAULT CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci;
USE `blog`;
-- --------------------------------------------------------
--
-- Table structure for table `comments`
--
DROP TABLE IF EXISTS `comments`;
CREATE TABLE `comments` (
`id` int(11) NOT NULL,
`id_post` int(11) NOT NULL,
`visitor_name` varchar(20) NOT NULL,
`visitor_email` text DEFAULT NULL,
`visitor_url` tinytext NOT NULL,
`visitor_comment` text NOT NULL,
`visitor_ipaddress` text DEFAULT NULL,
`comment_password` text NOT NULL,
`timestamp_published` varchar(20) NOT NULL,
`timestamp_edited` varchar(20) DEFAULT NULL,
`timestamp_accepted` tinyint(4) DEFAULT NULL,
`timestamp_denied` tinyint(4) DEFAULT NULL,
`is_public` tinyint(4) DEFAULT NULL,
`is_denied` tinyint(4) DEFAULT NULL,
`is_spam` tinyint(4) DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
-- --------------------------------------------------------
--
-- Table structure for table `files`
--
DROP TABLE IF EXISTS `files`;
CREATE TABLE `files` (
`id` int(11) NOT NULL,
`file_name` text NOT NULL,
`file_name_md5` varchar(32) NOT NULL,
`file_extension` varchar(4) NOT NULL,
`field_alt` varchar(200) NOT NULL,
`timestamp_uploaded` varchar(20) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
-- --------------------------------------------------------
--
-- Table structure for table `posts`
--
DROP TABLE IF EXISTS `posts`;
CREATE TABLE `posts` (
`id` int(11) NOT NULL,
`id_unique` varchar(13) NOT NULL,
`subject` varchar(80) NOT NULL,
`cover_hash` varchar(32) DEFAULT NULL,
`cover_url` text DEFAULT NULL,
`cover_owner` text DEFAULT NULL,
`cover_owner_url` text DEFAULT NULL,
`content_beforebreak` text NOT NULL,
`content_afterbreak` text DEFAULT NULL,
`tags` text DEFAULT NULL,
`is_inenglish` varchar(2) DEFAULT NULL,
`hasbeencorrected` tinyint(4) DEFAULT NULL,
`readers` smallint(6) DEFAULT NULL,
`timestamp_saved` tinytext DEFAULT NULL,
`timestamp_published` tinytext DEFAULT NULL,
`timestamp_edited` tinytext DEFAULT NULL,
`is_pinned` tinyint(4) DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
-- --------------------------------------------------------
--
-- Table structure for table `users`
--
DROP TABLE IF EXISTS `users`;
CREATE TABLE `users` (
`id` int(11) NOT NULL,
`username` tinytext NOT NULL,
`password` text DEFAULT NULL,
`info_name` varchar(50) NOT NULL,
`info_url` text NOT NULL,
`info_email` text DEFAULT NULL,
`twofactorcode` tinytext DEFAULT NULL,
`is_admin` tinyint(4) DEFAULT NULL,
`is_guest` tinyint(4) DEFAULT NULL,
`timestamp_lastlogin` varchar(20) DEFAULT NULL,
`timestamp_lastactive` tinytext DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
-- --------------------------------------------------------
--
-- Table structure for table `webmention`
--
DROP TABLE IF EXISTS `webmention`;
CREATE TABLE `webmention` (
`id` int(11) NOT NULL,
`id_post` varchar(20) NOT NULL,
`url` text NOT NULL,
`author_name` text NOT NULL,
`author_avatar` text NOT NULL,
`author_avatar_locally` text NOT NULL,
`author_url` text NOT NULL,
`webmention_received` varchar(15) NOT NULL,
`webmention_source` text NOT NULL,
`webmention_target` text NOT NULL,
`content_html` text DEFAULT NULL,
`content_text` text DEFAULT NULL,
`type` varchar(7) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
--
-- Indexes for dumped tables
--
--
-- Indexes for table `comments`
--
ALTER TABLE `comments`
ADD UNIQUE KEY `id` (`id`);
--
-- Indexes for table `files`
--
ALTER TABLE `files`
ADD UNIQUE KEY `id` (`id`);
--
-- Indexes for table `posts`
--
ALTER TABLE `posts`
ADD UNIQUE KEY `id` (`id`);
--
-- Indexes for table `users`
--
ALTER TABLE `users`
ADD UNIQUE KEY `id` (`id`);
--
-- Indexes for table `webmention`
--
ALTER TABLE `webmention`
ADD UNIQUE KEY `id` (`id`);
--
-- AUTO_INCREMENT for dumped tables
--
--
-- AUTO_INCREMENT for table `comments`
--
ALTER TABLE `comments`
MODIFY `id` int(11) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT for table `files`
--
ALTER TABLE `files`
MODIFY `id` int(11) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT for table `posts`
--
ALTER TABLE `posts`
MODIFY `id` int(11) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT for table `users`
--
ALTER TABLE `users`
MODIFY `id` int(11) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT for table `webmention`
--
ALTER TABLE `webmention`
MODIFY `id` int(11) NOT NULL AUTO_INCREMENT;
COMMIT;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;