   `entry_url_source` varchar(255) COLLATE utf8mb4_bin DEFAULT NULL,
   `entry_screenshot_url` varchar(255) COLLATE utf8mb4_bin DEFAULT NULL,
   `entry_color` varchar(45) COLLATE utf8mb4_bin DEFAULT 'FFFFFF',
-  `entry_deleted` tinyint(1) DEFAULT '0',
-  PRIMARY KEY (`entry_id`)
-) ENGINE=MyISAM AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_bin;
-
-DELIMITER ;;
-CREATE TRIGGER entry_insert AFTER INSERT ON `entry` FOR EACH ROW 
-BEGIN
+  `entry_deleted` tinyint(1) DEFAULT '0'
+) ENGINE=MyISAM DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_bin;
+
+--
+-- Triggers `entry`
+--
+DELIMITER $$
+CREATE TRIGGER `entry_delete` BEFORE DELETE ON `entry` FOR EACH ROW BEGIN
+    INSERT INTO `entry_changelog`
+		(`change_id`,
+		`change_type`,
+		`change_datetime`,
+		`entry_id`,
+		`entry_datetime`,
+		`entry_ip`,
+		`entry_user_agent`,
+		`entry_jam_id`,
+		`entry_jam_number`,
+		`entry_title`,
+		`entry_description`,
+		`entry_author`,
+		`entry_url`,
+		`entry_url_web`,
+		`entry_url_windows`,
+		`entry_url_linux`,
+		`entry_url_mac`,
+		`entry_url_android`,
+		`entry_url_ios`,
+		`entry_url_source`,
+		`entry_screenshot_url`,
+		`entry_color`,
+		`entry_deleted`)
+	VALUES
+		(null,
+		"DELETE",
+		Now(),
+		old.entry_id,
+		old.entry_datetime,
+		old.entry_ip,
+		old.entry_user_agent,
+		old.entry_jam_id,
+		old.entry_jam_number,
+		old.entry_title,
+		old.entry_description,
+		old.entry_author,
+		old.entry_url,
+		old.entry_url_web,
+		old.entry_url_windows,
+		old.entry_url_linux,
+		old.entry_url_mac,
+		old.entry_url_android,
+		old.entry_url_ios,
+		old.entry_url_source,
+		old.entry_screenshot_url,
+		old.entry_color,
+		old.entry_deleted);
+END
+$$
+DELIMITER ;
+DELIMITER $$
+CREATE TRIGGER `entry_insert` AFTER INSERT ON `entry` FOR EACH ROW BEGIN
     INSERT INTO `entry_changelog`
 		(`change_id`,
 		`change_type`,

  `session_id` varchar(255) NOT NULL,
  `session_user_id` int(11) DEFAULT NULL,
  `session_datetime_started` datetime DEFAULT NULL,
  `session_datetime_last_used` datetime DEFAULT NULL,
  PRIMARY KEY (`session_id`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_bin;

--
-- Table structure for table `theme`
--

CREATE TABLE `theme` (
  `theme_id` int(11) NOT NULL AUTO_INCREMENT,
  `theme_datetime` datetime NOT NULL,
  `theme_ip` varchar(45) COLLATE utf8mb4_bin NOT NULL,
  `theme_user_agent` varchar(255) COLLATE utf8mb4_bin NOT NULL,
  `theme_text` varchar(255) COLLATE utf8mb4_bin NOT NULL,
  `theme_author` varchar(255) COLLATE utf8mb4_bin NOT NULL,
  `theme_banned` tinyint(1) DEFAULT '0',
  `theme_deleted` tinyint(1) DEFAULT '0',
  PRIMARY KEY (`theme_id`)
) ENGINE=MyISAM AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_bin;

--
-- Table structure for table `themevote`
--

CREATE TABLE `themevote` (
  `themevote_id` int(11) NOT NULL AUTO_INCREMENT,
  `themevote_datetime` datetime NOT NULL,
  `themevote_ip` varchar(45) COLLATE utf8mb4_bin NOT NULL,
  `themevote_user_agent` varchar(255) COLLATE utf8mb4_bin NOT NULL,
  `themevote_theme_id` int(11) NOT NULL,
  `themevote_username` varchar(255) COLLATE utf8mb4_bin NOT NULL,
  `themevote_type` int(11) NOT NULL,
  PRIMARY KEY (`themevote_id`)
) ENGINE=MyISAM AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_bin;

--
-- Table structure for table `user`
--

CREATE TABLE `user` (
  `user_id` int(11) NOT NULL AUTO_INCREMENT,
  `user_username` varchar(45) COLLATE utf8mb4_bin NOT NULL,
  `user_datetime` datetime DEFAULT NULL,
  `user_register_ip` varchar(45) COLLATE utf8mb4_bin DEFAULT NULL,

  `asset_description` mediumtext COLLATE utf8mb4_bin NOT NULL,
  `asset_type` varchar(45) COLLATE utf8mb4_bin NOT NULL,
  `asset_content` mediumtext COLLATE utf8mb4_bin NOT NULL,
  `asset_deleted` tinyint(1) DEFAULT '0'
) ENGINE=MyISAM DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_bin;

-- --------------------------------------------------------

--
-- Table structure for table `entry`
--

CREATE TABLE `entry` (
  `entry_id` int(11) NOT NULL,
  `entry_datetime` datetime DEFAULT NULL,
  `entry_ip` varchar(45) COLLATE utf8mb4_bin DEFAULT NULL,
  `entry_user_agent` mediumtext COLLATE utf8mb4_bin,
