PHP Classes

File: opds.sql

Recommend this page to a friend!
  Classes of Pierre FAUQUE   OPDS PHP Ebook Publisher Class   opds.sql   Download  
File: opds.sql
Role: Auxiliary data
Content type: text/plain
Description: Script to build the database
Class: OPDS PHP Ebook Publisher Class
Publish and distribute ebooks for download
Author: By
Last change:
Date: 4 years ago
Size: 17,942 bytes
 

Contents

Class file image Download
-- MySQL dump 10.13 Distrib 5.5.40, for debian-linux-gnu (x86_64) -- -- Host: localhost Database: opds -- ------------------------------------------------------ -- Server version 5.5.40-0+wheezy1 /*!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 utf8 */; /*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */; /*!40103 SET TIME_ZONE='+00:00' */; /*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */; /*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */; /*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */; /*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */; -- -- Table structure for table `opds_Authors` -- DROP TABLE IF EXISTS `opds_Authors`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `opds_Authors` ( `idaut` int(11) NOT NULL AUTO_INCREMENT COMMENT 'Author ID', `lname` varchar(30) NOT NULL COMMENT 'Author''s lastname', `fname` varchar(30) NOT NULL COMMENT 'Author''s firstname', `bdate` date NOT NULL COMMENT 'Date of birth', `ddate` date NOT NULL COMMENT 'Date of death', `uri` varchar(80) NOT NULL COMMENT 'URL of the author''s page', `bio` text NOT NULL COMMENT 'Author''s brief description', `upda` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT 'Date of registration update', PRIMARY KEY (`idaut`) ) ENGINE=MyISAM AUTO_INCREMENT=3 DEFAULT CHARSET=utf8 COMMENT='Table of authors'; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `opds_Authors` -- LOCK TABLES `opds_Authors` WRITE; /*!40000 ALTER TABLE `opds_Authors` DISABLE KEYS */; INSERT INTO `opds_Authors` VALUES (1,'BARLOW','John Perry','1947-10-03','2018-02-07','https://fr.wikipedia.org/wiki/John_Perry_Barlow','John Perry Barlow was born in a ranch near Pinedale, Wyoming and died in San Francisco. He is a poet, essayist, retired breeder, militant libertarian. He was also lyricist for the psychedelic rock band Grateful Dead, as well as a founding member of the Electronic Frontier Foundation and the Freedom of the Press Foundation. He is known for his Declaration of Cyberspace Independence, a text written at the 1996 Davos forum, to protest a telecoms censorship law that had just been signed by US Vice President Al Gore.','2020-05-12 15:39:44'),(2,'HEILAND','Dave','0000-00-00','0000-00-00','http://www.fauque.fr/opds/authors/dheiland.php','','2020-05-13 17:38:10'); /*!40000 ALTER TABLE `opds_Authors` ENABLE KEYS */; UNLOCK TABLES; -- -- Table structure for table `opds_Categories` -- DROP TABLE IF EXISTS `opds_Categories`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `opds_Categories` ( `idcat` int(11) NOT NULL AUTO_INCREMENT COMMENT 'Category ID', `cat` varchar(30) NOT NULL COMMENT 'Category label', `descc` tinytext NOT NULL COMMENT 'Brief description', `active` tinyint(4) NOT NULL DEFAULT '1' COMMENT 'Displayable in the web catalog (0|1)', `updc` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT 'Date of registration update', PRIMARY KEY (`idcat`) ) ENGINE=MyISAM AUTO_INCREMENT=3 DEFAULT CHARSET=utf8 COMMENT='Table of categories'; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `opds_Categories` -- LOCK TABLES `opds_Categories` WRITE; /*!40000 ALTER TABLE `opds_Categories` DISABLE KEYS */; INSERT INTO `opds_Categories` VALUES (1,'Various writings','Miscellaneous writings without characteristic genre',1,'2020-05-12 15:47:51'),(2,'Computing','Books on computers (hardware, software, methods, analysis, etc.)',1,'2020-05-13 17:20:59'); /*!40000 ALTER TABLE `opds_Categories` ENABLE KEYS */; UNLOCK TABLES; -- -- Table structure for table `opds_Config` -- DROP TABLE IF EXISTS `opds_Config`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `opds_Config` ( `key` varchar(20) NOT NULL COMMENT 'Configuration item label', `value` varchar(50) NOT NULL COMMENT 'Configuration item value', `statut` varchar(20) NOT NULL COMMENT 'Necessity of the field' ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COMMENT='Table of configuration'; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `opds_Config` -- LOCK TABLES `opds_Config` WRITE; /*!40000 ALTER TABLE `opds_Config` DISABLE KEYS */; INSERT INTO `opds_Config` VALUES ('author','','mandatory'),('rootsite','','mandatory'),('rootopds','/opds','mandatory'),('docsdir','ebooks','mandatory'),('imgdir','img','mandatory'),('authdir','authors','mandatory'),('email','','optionnal'),('favicon','','optionnal'); /*!40000 ALTER TABLE `opds_Config` ENABLE KEYS */; UNLOCK TABLES; -- -- Table structure for table `opds_Documents` -- DROP TABLE IF EXISTS `opds_Documents`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `opds_Documents` ( `iddoc` int(11) NOT NULL AUTO_INCREMENT COMMENT 'Document ID', `title` varchar(60) NOT NULL COMMENT 'Document title', `descd` text NOT NULL COMMENT 'Document description', `issued` varchar(10) NOT NULL COMMENT 'Year/Date of issue', `idscat` int(11) NOT NULL COMMENT 'Sub-category ID', `active` int(11) NOT NULL DEFAULT '1' COMMENT 'Displayable in the web catalog (0|1)', `updd` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT 'Date of registration update', PRIMARY KEY (`iddoc`) ) ENGINE=MyISAM AUTO_INCREMENT=4 DEFAULT CHARSET=utf8 COMMENT='Table of publishable documents'; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `opds_Documents` -- LOCK TABLES `opds_Documents` WRITE; /*!40000 ALTER TABLE `opds_Documents` DISABLE KEYS */; INSERT INTO `opds_Documents` VALUES (1,'Cyberspace Declaration of Independence','The Declaration of Cyberspace Independence is a document written on February 8, 1996 in Davos, Switzerland by John Perry Barlow, one of the founders of the Electronic Frontier Foundation. He supports the idea that no government (or any other form of power) can impose and appropriate the Internet, then in full expansion. It was written in part in response to the passage of the Telecommunications Act of 1996 in the United States.\r\nThe Declaration sets out, in sixteen short paragraphs, the rejection of the appropriation of the Internet by an external government, in particular that of the United States. He claims that the United States has not had the \"consent of the governed\" to apply its laws on the Internet, and that the Internet is outside the borders of any country. He specifies that the Internet regulates itself, with its own codes and social languages, based on the ethics of reciprocity. It does so in language evocative of the Declaration of Independence of the United States, which is obvious in its last paragraphs. Although the document mentions the Telecommunications Act, it also accuses China, Germany, France, Russia, Singapore, and Italy of stifling the Internet.\r\nBy the time the document was written, Barlow had already written extensively on the Internet and its social and legal phenomena. He is also one of the founding members of the Electronic Frontier Foundation. One of his most famous works remains \"The Economy of Ideas\", then published in March 1994 in Wired magazine, he alluded to Thomas Jefferson and some of the ideas he would write in his statement. (Wikipedia source)','1996-02-08',1,1,'2020-05-12 16:18:50'),(2,'Sigil User Guide v0.7.2','Sigil was designed to make it easy to create great ebooks using the EPUB format. If you are formatting books for your own use, or you are a professional editor publishing books on multiple platforms, then Sigil is for you. You can use Sigil to format and package your books into an EPUB that looks exactly the way you want it to using an advanced set of features that have made Sigil one of most popular EPUB editors available.\r\nThis open-source and completely free software is written and supported entirely by volunteers. The Sigil development team includes John Schember (the lead developer and maintainer of Sigil), Grant Drake and Dave Heiland. Sigil was originally created by Strahinja Markovic in 2009 and remains completely free to download and use. Support is also provided by other volunteers who contribute code, translations and helpful answers to user\'s questions. See the Help->About menu in Sigil for a complete list of contributors.','2013-04-14',2,1,'2020-05-13 17:29:14'),(3,'Sigil User Guide v0.9.15','Sigil was designed to make it easy to create great ebooks using the EPUB format. If you are formatting books for your own use, or you are a professional editor publishing books on multiple platforms, then Sigil is for you. You can use Sigil to format and package your books into an EPUB that looks exactly the way you want it to using an advanced set of features that have made Sigil one of most popular EPUB editors available.\r\nThis open-source and completely free software is written and supported entirely by volunteers. The Sigil development team includes John Schember (the lead developer and maintainer of Sigil), Grant Drake and Dave Heiland. Sigil was originally created by Strahinja Markovic in 2009 and remains completely free to download and use. Support is also provided by other volunteers who contribute code, translations and helpful answers to user\'s questions. See the Help->About menu in Sigil for a complete list of contributors.','2019-09-03',2,1,'2020-05-16 16:58:35'); /*!40000 ALTER TABLE `opds_Documents` ENABLE KEYS */; UNLOCK TABLES; -- -- Table structure for table `opds_Keywords` -- DROP TABLE IF EXISTS `opds_Keywords`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `opds_Keywords` ( `idkw` int(11) NOT NULL AUTO_INCREMENT COMMENT 'Keyword ID', `keyword` varchar(30) NOT NULL COMMENT 'Keyword label', PRIMARY KEY (`idkw`) ) ENGINE=MyISAM AUTO_INCREMENT=9 DEFAULT CHARSET=utf8 COMMENT='Table of keywords'; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `opds_Keywords` -- LOCK TABLES `opds_Keywords` WRITE; /*!40000 ALTER TABLE `opds_Keywords` DISABLE KEYS */; INSERT INTO `opds_Keywords` VALUES (1,'internet'),(2,'liberty'),(3,'independence'),(4,'cyberspace'),(5,'editor'),(6,'ebooks'),(7,'publication'),(8,'opds'); /*!40000 ALTER TABLE `opds_Keywords` ENABLE KEYS */; UNLOCK TABLES; -- -- Table structure for table `opds_PublishedIn` -- DROP TABLE IF EXISTS `opds_PublishedIn`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `opds_PublishedIn` ( `iddoc` int(11) NOT NULL COMMENT 'Document ID', `idtype` int(11) NOT NULL COMMENT 'Type ID of the ebook', `lang` varchar(2) NOT NULL COMMENT 'Language of the document', `filename` varchar(90) NOT NULL COMMENT 'Filename of the ebook', `thumb` varchar(30) NOT NULL COMMENT 'Filename of the thumbnail', `descpe` text NOT NULL COMMENT 'Ebook description', `updpe` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT 'Date of registration update', PRIMARY KEY (`iddoc`,`idtype`) ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COMMENT='Table of ebooks (document-published-in-such-type)'; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `opds_PublishedIn` -- LOCK TABLES `opds_PublishedIn` WRITE; /*!40000 ALTER TABLE `opds_PublishedIn` DISABLE KEYS */; INSERT INTO `opds_PublishedIn` VALUES (1,1,'fr','John_Perry_Barlow_-_Declaration_d\'independance_du_Cyberespace.epub','th_cyberespace.png','This publication contains the original text and its French translation. The texts were found at URLs http://editions-hache.com/essais/barlow/barlow1.html (for English text) and http://editions-hache.com/essais/barlow/barlow2.html (for French text). The EPUB was done with Sigil v0.7.2 by Pierre Fauque on 2017-02-24','2020-05-12 17:01:05'),(2,1,'en','Dave_Heiland_-_Sigil_User_Guide-072.epub','th_sigil.png','The User Guide for Sigil, a cross platform, open-source application program for creating ePub format e-books. The User Guide is available for free downloading in ePub format from the Sigil documentation page on Github.','2020-05-13 17:46:56'),(3,1,'en','Dave_Heiland_-_Sigil_User_Guide-0915.epub','th_sigil.png','The User Guide for Sigil 0.9.15, a cross platform, open-source application program for creating ePub format e-books. The User Guide is available for free downloading in ePub format from the Sigil documentation page on Github.','2020-05-16 17:05:49'),(1,2,'fr','John_Perry_Barlow_-_Declaration_d\'independance_du_Cyberespace.mobi','th_cyberespace.png','This publication contains the original text and its French translation. The texts were found at URLs http://editions-hache.com/essais/barlow/barlow1.html (for English text) and http://editions-hache.com/essais/barlow/barlow2.html (for French text). The EPUB was done with Sigil v0.7.2 by Pierre Fauque on 2017-02-24 and converted in .mobi format with Format Factory','2020-05-12 17:01:05'); /*!40000 ALTER TABLE `opds_PublishedIn` ENABLE KEYS */; UNLOCK TABLES; -- -- Table structure for table `opds_References` -- DROP TABLE IF EXISTS `opds_References`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `opds_References` ( `iddoc` int(11) NOT NULL COMMENT 'Document ID', `idkw` int(11) NOT NULL COMMENT 'Keyword ID', PRIMARY KEY (`iddoc`,`idkw`) ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COMMENT='Table of classified documents'; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `opds_References` -- LOCK TABLES `opds_References` WRITE; /*!40000 ALTER TABLE `opds_References` DISABLE KEYS */; INSERT INTO `opds_References` VALUES (1,1),(1,2),(1,3),(1,4),(2,5),(2,6),(2,7),(2,8),(3,5),(3,6),(3,7),(3,8); /*!40000 ALTER TABLE `opds_References` ENABLE KEYS */; UNLOCK TABLES; -- -- Table structure for table `opds_SCategories` -- DROP TABLE IF EXISTS `opds_SCategories`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `opds_SCategories` ( `idscat` int(11) NOT NULL AUTO_INCREMENT COMMENT 'Sub-catgory ID', `scat` varchar(30) NOT NULL COMMENT 'Sub-category label', `descsc` tinytext NOT NULL COMMENT 'Brief description', `active` int(11) NOT NULL DEFAULT '1' COMMENT 'Displayable in the web catalog (0|1)', `idcat` int(11) NOT NULL DEFAULT '3' COMMENT 'Category ID', `updsc` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT 'Date of registration update', PRIMARY KEY (`idscat`) ) ENGINE=MyISAM AUTO_INCREMENT=3 DEFAULT CHARSET=utf8 COMMENT='Table of sub-categories'; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `opds_SCategories` -- LOCK TABLES `opds_SCategories` WRITE; /*!40000 ALTER TABLE `opds_SCategories` DISABLE KEYS */; INSERT INTO `opds_SCategories` VALUES (1,'Declarations','Various declarations (political, artistic, societal, medical, ethical, etc.)',1,1,'2020-05-12 15:50:26'),(2,'Editors','Ebooks about editor softwares (text, music, videos, ebooks, etc.)',1,2,'2020-05-13 17:23:29'); /*!40000 ALTER TABLE `opds_SCategories` ENABLE KEYS */; UNLOCK TABLES; -- -- Table structure for table `opds_Types` -- DROP TABLE IF EXISTS `opds_Types`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `opds_Types` ( `idtype` int(11) NOT NULL AUTO_INCREMENT COMMENT 'Ebook type ID', `type` varchar(15) NOT NULL COMMENT 'Ebook Type label', `format` varchar(20) NOT NULL COMMENT 'Format to use', PRIMARY KEY (`idtype`) ) ENGINE=MyISAM AUTO_INCREMENT=5 DEFAULT CHARSET=utf8 COMMENT='Table of ebooks types'; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `opds_Types` -- LOCK TABLES `opds_Types` WRITE; /*!40000 ALTER TABLE `opds_Types` DISABLE KEYS */; INSERT INTO `opds_Types` VALUES (1,'EPUB','epub+zip'),(2,'MOBI','x-mobipocket-ebook'),(3,'PDF','pdf'),(4,'ZIP','zip'); /*!40000 ALTER TABLE `opds_Types` ENABLE KEYS */; UNLOCK TABLES; -- -- Table structure for table `opds_Write` -- DROP TABLE IF EXISTS `opds_Write`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `opds_Write` ( `iddoc` int(11) NOT NULL COMMENT 'Document ID', `idaut` int(11) NOT NULL COMMENT 'Author ID', PRIMARY KEY (`iddoc`,`idaut`) ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COMMENT='Table of identified creations'; /*!40101 SET character_set_client = @saved_cs_client */; -- -- Dumping data for table `opds_Write` -- LOCK TABLES `opds_Write` WRITE; /*!40000 ALTER TABLE `opds_Write` DISABLE KEYS */; INSERT INTO `opds_Write` VALUES (1,1),(2,2),(3,2); /*!40000 ALTER TABLE `opds_Write` ENABLE KEYS */; UNLOCK TABLES; /*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */; /*!40101 SET SQL_MODE=@OLD_SQL_MODE */; /*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */; /*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */; /*!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 */; /*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */; -- Dump completed on 2020-05-24 0:21:22