core/set/install/page_mysql.php

16 lines
577 B
PHP
Raw Normal View History

2023-04-09 19:52:26 +05:00
<?php
\DB::set("CREATE TABLE IF NOT EXISTS `pages_comments` (
`id` int(10) NOT NULL AUTO_INCREMENT,
`user_id` int(10) NOT NULL,
`txt` longtext NOT NULL,
`status` int(1) NOT NULL DEFAULT 0,
`t` varchar(30) NOT NULL,
`page_id` int(10) NOT NULL,
PRIMARY KEY (`id`),
KEY `user_id` (`user_id`),
KEY `page_id` (`page_id`),
CONSTRAINT `pages_comments_ibfk_1` FOREIGN KEY (`user_id`) REFERENCES `users` (`id`),
CONSTRAINT `pages_comments_ibfk_2` FOREIGN KEY (`page_id`) REFERENCES `pages` (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_general_ci");
?>