Author: frik85
Date: Tue Aug 14 19:26:16 2007
New Revision: 28339
URL:
http://svn.reactos.org/svn/reactos?rev=28339&view=rev
Log:
RosCMS update:
* install-script: easy to use install-script to setup RosCMS (only PHP 4+ & MySQL 4+
are required)
* up-to-date SQL-dumb file
* if you want to install RosCMS on your server, try out the prepaired package:
http://www.reactos.org/?page=roscms
Added:
trunk/web/reactos.org/htdocs/roscms/roscms.sql
Modified:
trunk/web/reactos.org/htdocs/roscms/inc/home.php
trunk/web/reactos.org/htdocs/roscms/inc/user_overview.php
trunk/web/reactos.org/htdocs/roscms/install.php
trunk/web/reactos.org/sql/roscms.sql
Modified:
trunk/web/reactos.org/htdocs/roscms/inc/home.php
URL:
http://svn.reactos.org/svn/reactos/trunk/web/reactos.org/htdocs/roscms/inc/…
==============================================================================
---
trunk/web/reactos.org/htdocs/roscms/inc/home.php (original)
+++
trunk/web/reactos.org/htdocs/roscms/inc/home.php Tue Aug 14 19:26:16 2007
@@ -20,10 +20,15 @@
?>
<?php /*require("inc/data_menu.php"); */ ?>
<p> </p>
-<h2>RosCMS v2 to RosCMS v3 update</h2>
-<h4>RosCMS v2 will be replaced by RosCMS v3 in a few hours, come back
later!</h4>
-<p>If you have any questions, please join #reactos-web IRC channel. See
reactos.org
website for more information about our IRC channels.<br /><br />
-Klemens Friedl, 2007-07-30 11:10 GMT+1</p>
+<h2>RosCMS v3 - Status </h2>
+<p><strong>RosCMS v2 got replaced by RosCMS v3 on
2007-07-31!</strong></p>
+<h4>Tutorials</h4>
+<p>Please read and/or watch the<strong> <a
href="http://www.reactos.org/?page=tutorial_roscms">RosCMS
Tutorials</a></strong> to learn more about RosCMS v3 new interface and its
features! </p>
+<h4>Welcome page </h4>
+<p>Please change your RosCMS-bookmark to "<a
href="http://www.reactos.org/roscms/?page=data&branch=welcome&…p;branch=welcome</a>".
The new <a
href="http://www.reactos.org/roscms/?page=data&branch=welcome&…
Welcome-page</a> should be your first start point to get the latest information
about the website translation process and anything related to website content changes.
</p>
+<p>If you have any questions, please join #reactos-web IRC channel. See
reactos.org
website for more information about our IRC channels.<br />
+ <br />
+Klemens Friedl, 2007-07-31 15:42 GMT+1</p>
<p> </p>
<p> </p>
Modified:
trunk/web/reactos.org/htdocs/roscms/inc/user_overview.php
URL:
http://svn.reactos.org/svn/reactos/trunk/web/reactos.org/htdocs/roscms/inc/…
==============================================================================
---
trunk/web/reactos.org/htdocs/roscms/inc/user_overview.php (original)
+++
trunk/web/reactos.org/htdocs/roscms/inc/user_overview.php Tue Aug 14 19:26:16 2007
@@ -91,8 +91,9 @@
<td valign="top"><font size="2"
face="Arial, Helvetica, sans-serif">Description:</font></td>
<td colspan="2" valign="top"> <font
size="2" face="Arial, Helvetica, sans-serif"><?php
- include("../editor/bbcode/cbparser.php");
- echo @bb2html($result_usraccount['user_description'],'');
+ //include("../editor/bbcode/cbparser.php");
+ //echo @bb2html($result_usraccount['user_description'],'');
+ echo $result_usraccount['user_description'];
?></font></td>
</tr>
Modified:
trunk/web/reactos.org/htdocs/roscms/install.php
URL:
http://svn.reactos.org/svn/reactos/trunk/web/reactos.org/htdocs/roscms/inst…
==============================================================================
---
trunk/web/reactos.org/htdocs/roscms/install.php (original)
+++
trunk/web/reactos.org/htdocs/roscms/install.php Tue Aug 14 19:26:16 2007
@@ -30,7 +30,7 @@
if( !mysql_query( $cmd ) )
{
$ret = FALSE;
- echo "<br>" . mysql_errno() . ": " . mysql_error();
+ echo "<br />" . mysql_errno() . ": " . mysql_error();
}
$done = false;
@@ -52,92 +52,343 @@
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/1999/REC-html401-19991224/loose.dtd">
<html>
<head>
- <title>RosCMS Install Script</title>
+ <title>RosCMS v3 - Install Script</title>
+ <style type="text/css">
+ <!--
+
+ body {
+ font-family: Verdana;
+ font-size: 12px;
+ }
+
+ hr {
+ margin: 5px 0 5px 0;
+ color: #8D8D8D;
+ }
+
+ h1 {
+ font-size: 24px;
+ color: #5984C3;
+ font-weight: bold;
+ }
+
+ h2 {
+ font-size: 22px;
+ color: #5984C3;
+ font-weight: bold;
+ }
+
+ h3 {
+ font-size: 18px;
+ color: #5984C3;
+ font-weight: bold;
+ }
+
+ a {
+ font-size: 12px;
+ color: #006090;
+ }
+
+ a:hover {
+ background-color: #DDEEFF;
+ color: #000000;
+ }
+ -->
+ </style>
</head>
<body>
<?php
if ($rpm_ready == "step2") {
?>
- <h1>RosCMS - Install Script - Step2</h1>
+ <h1>RosCMS v3 - Install Script - Step2</h1>
<form id="form1" method="post"
action="install.php?ready=step3">
<h3>Database Information</h3>
<table>
<tr>
<td>Database Host Name:</td>
- <td><input name="dbHost" type="text"
id="dbHost" value="localhost" /></td>
+ <td><input name="dbHost" type="text"
id="dbHost" value="localhost" size="25"
maxlength="255" /></td>
</tr>
<tr>
<td>Database User Name:</td>
- <td><input name="dbUser" type="text"
id="dbUser" value="root" /></td>
+ <td><input name="dbUser" type="text"
id="dbUser" value="root" size="25" maxlength="255"
/></td>
</tr>
<tr>
<td>Database User Password:</td>
- <td><input name="dbPass" type="text"
id="dbPass" /></td>
+ <td><input name="dbPass" type="text"
id="dbPass" size="25" maxlength="255" /></td>
</tr>
<tr>
<td>Database Name:</td>
- <td><input name="dbName" type="text"
id="dbName" value="domainname" /></td>
+ <td><input name="dbName" type="text"
id="dbName" value="roscms" size="25"
maxlength="255" /></td>
</tr>
</table>
<h3>Server Information</h3>
- <p>Complete Server Path: <input name="path_server"
type="text" id="path_server"
value="http://localhost/domain.com/" size="50" /></p>
-
+ <p>Complete Server Path: <input name="path_server"
type="text" id="path_server"
value="http://localhost/domain.com/" size="50"
maxlength="255" />
+ </p>
+
+ <h3>RosCMS Settings</h3>
+ <p>RosCMS directory :
+ <input name="roscmsdir" type="text"
id="roscmsdir" value="roscms" size="20"
maxlength="50" />
+ </p>
+ <p>Default Language:
+ <input name="lang_std" type="text"
id="lang_std" value="en" size="5" maxlength="2"
/>
+ </p>
+ <p>Default Language Name:
+ <input name="lang_std_full" type="text"
id="lang_std_full" value="English" size="20"
maxlength="50" />
+ </p>
+ <p>Default Translation Language:
+ <input name="lang_std_trans" type="text"
id="lang_std_trans" value="de" size="5"
maxlength="2" />
+ </p>
+
+ <h3>Super Administrator Account</h3>
+ <p>Account-Name:
+ <input name="admin_name" type="text" id="admin_name"
value="Admin" size="20" maxlength="50" />
+ </p>
+ <p>Fullname:
+ <input name="admin_fullname" type="text"
id="admin_fullname" value="Administrator" size="20"
maxlength="50" />
+</p>
+ <p>Password:
+ <input name="admin_pwd" type="password"
id="admin_pwd" size="20" maxlength="50" />
+ <font size="1">(6 or more characters)</font></p>
+ <p>E-Mail Address:
+ <input name="admin_email" type="text"
id="admin_email" value="admin(a)domain.com" size="50"
maxlength="255" />
+</p>
<p> </p>
-
<input type="submit" name="Submit" value="Install RosCMS
..." />
</form>
<?php
}
else if ($rpm_ready == "step3") {
- echo "<h1>RosCMS - Install Script - Step3</h1>";
+ echo "<h1>RosCMS v3 - Install Script - Step3</h1>";
$dbHost = "localhost";
$dbUser = "root";
$dbPass = "";
$dbName = "roscms";
$path_server = "";
+ $path_roscms = "";
+ $lang_std = "";
+ $lang_std_full = "";
+ $lang_std_trans = "";
+ $admin_name = "";
+ $admin_fullname = "";
+ $admin_pwd = "";
+ $admin_email = "";
if (array_key_exists("dbHost", $_POST))
$dbHost=htmlspecialchars($_POST["dbHost"]);
if (array_key_exists("dbUser", $_POST))
$dbUser=htmlspecialchars($_POST["dbUser"]);
if (array_key_exists("dbPass", $_POST))
$dbPass=htmlspecialchars($_POST["dbPass"]);
if (array_key_exists("dbName", $_POST))
$dbName=htmlspecialchars($_POST["dbName"]);
if (array_key_exists("path_server", $_POST))
$path_server=htmlspecialchars($_POST["path_server"]);
+ if (array_key_exists("roscmsdir", $_POST))
$path_roscms=htmlspecialchars($_POST["roscmsdir"]);
+ if (array_key_exists("lang_std", $_POST))
$lang_std=htmlspecialchars($_POST["lang_std"]);
+ if (array_key_exists("lang_std_full", $_POST))
$lang_std_full=htmlspecialchars($_POST["lang_std_full"]);
+ if (array_key_exists("lang_std_trans", $_POST))
$lang_std_trans=htmlspecialchars($_POST["lang_std_trans"]);
+ if (array_key_exists("admin_name", $_POST))
$admin_name=htmlspecialchars($_POST["admin_name"]);
+ if (array_key_exists("admin_fullname", $_POST))
$admin_fullname=htmlspecialchars($_POST["admin_fullname"]);
+ if (array_key_exists("admin_pwd", $_POST))
$admin_pwd=htmlspecialchars($_POST["admin_pwd"]);
+ if (array_key_exists("admin_email", $_POST))
$admin_email=htmlspecialchars($_POST["admin_email"]);
+
+
+ if ($path_server == "") {
+ die("Invalid server-path!");
+ }
+
+ if ($path_roscms == "" || $lang_std == "" || $lang_std_full ==
"" || lang_std_trans == "") {
+ die("Invalid RosCMS config settings!");
+ }
+
+ if ($admin_name == "" || $admin_pwd == "" || $admin_email ==
"") {
+ die("Invalid account settings!");
+ }
echo "Connecting to the MySQL Server... ";
$connect = mysql_connect($dbHost, $dbUser, $dbPass) or die("Cannot connect to the
MySQL Server!");
- echo "OK<br>";
+ echo "OK<br />";
echo "Creating the Database... ";
mysql_query("CREATE DATABASE `". mysql_real_escape_string($dbName)
."`") or die( mysql_errno() . ": " . mysql_error() );
- echo "OK<br>";
+ echo "OK<br />";
echo "Selecting the Database... ";
- mysql_select_db($dbName, $connect) or die("Cannot find and select
<b>$dbName</b>!");
- echo "OK<br>";
+ mysql_select_db($dbName, $connect) or die("Cannot find and select
<b>".$dbName."</b>!");
+ echo "OK<br />";
echo "Importing the SQL Data... ";
- if( !import_sql_dump( "roscms.sql" ) )
- exit;
-
- /* TODO: The complete server path has to be saved somewhere */
+ if( !import_sql_dump( "roscms.sql" ) ) {
+ die("Error: import not successfull!");
+ }
+ echo "<br />";
+
+ echo "Adding first account... ";
+ $insert_account = mysql_query("INSERT INTO `users` ( `user_id` , `user_name` ,
`user_roscms_password` , `user_roscms_getpwd_id` , `user_timestamp_touch` ,
`user_timestamp_touch2` , `user_login_counter` , `user_account_enabled` ,
`user_account_hidden` , `user_register` , `user_fullname` , `user_email` , `user_website`
, `user_language` , `user_country` , `user_timezone` , `user_occupation` ,
`user_description` , `user_setting_multisession` , `user_setting_browseragent` ,
`user_setting_ipaddress` , `user_setting_timeout` )
+ VALUES (
+ NULL ,
+ '".mysql_real_escape_string($admin_name)."',
+ MD5( '".mysql_real_escape_string($admin_pwd)."' ) ,
+ '',
+ '',
+ NOW( ) ,
+ '0',
+ 'yes',
+ 'no',
+ NOW( ) ,
+ '".mysql_real_escape_string($admin_fullname)."',
+ '".mysql_real_escape_string($admin_email)."',
+ '".mysql_real_escape_string($path_server)."',
+ '".mysql_real_escape_string($lang_std)."',
+ '',
+ '',
+ '',
+ '',
+ 'true',
+ 'true',
+ 'true',
+ 'true'
+ );") or die("Cannot insert first account!");
+ echo "OK<br />";
+
+ echo "Adding account memberships... ";
+ $insert_membership = mysql_query("INSERT INTO `usergroup_members` (
`usergroupmember_userid` , `usergroupmember_usergroupid` )
+ VALUES (
+ '1',
+ 'user'
+ ),
+ (
+ '1',
+ 'ros_sadmin'
+ );") or die("Cannot insert account memberships!");
+ echo "OK<br />";
+
+
+ // RosCMS settings
+ echo "Creating roscms config file... ";
+ $fp = fopen("custom.php", "w");
+ flock($fp,2);
+ fputs($fp, '<?php
+
+ /*
+ RosCMS - ReactOS Content Management System
+ Copyright (C) 2007 Klemens Friedl <frik85(a)reactos.org>
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ */
+
+
+ global $rpm_page;
+
+ $roscms_extern_brand = "RosCMS";
+ $roscms_extern_version = "v3";
+ $roscms_extern_version_detail = "v3.0731";
+
+ $roscms_intern_webserver_pages = "'.$path_server.'";
+
+ $roscms_intern_roscms_dir = "'.$path_roscms.'";
+ $roscms_intern_webserver_roscms =
"'.$path_server.'".$roscms_intern_roscms_dir."/";
+ $roscms_intern_page_link = $roscms_intern_webserver_roscms . "?page=";
+ $roscms_intern_script_name = $roscms_intern_page_link . $rpm_page;
+
+ $roscms_intern_script_branch = $roscms_intern_script_name. "&branch=";
+
+ $roscms_standard_language="'.$lang_std.'"; // en/de/fr/...
+ $roscms_standard_language_full="'.$lang_std_full.'"; //
English/German/...
+ $roscms_standard_language_trans="'.$lang_std_trans.'"; //
en/de/fr/...');
+
+ fputs($fp, "\n ?>");
+ flock($fp, 3);
+ fclose($fp);
+ echo "OK<br />";
+
+ // RosCMS database login config
+ echo "Creating roscms database config file... ";
+ $fp = fopen("connect.db.php", "w");
+ flock($fp,2);
+ fputs($fp, '<?php
+ /*
+ RosCMS - ReactOS Content Management System
+ Copyright (C) 2005-2007 Klemens Friedl <frik85(a)reactos.org>
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ */
+
+
+ // Database:
+ $dbHost = "'.$dbHost.'";
+ $dbUser = "'.$dbUser.'";
+ $dbPass = "'.$dbPass.'";
+ $dbName = "'.$dbName.'";
+ $roscms_database = $dbName;
+
+ $connect = @mysql_connect($dbHost, $dbUser, $dbPass) or die("ERROR: Cannot
connect to the database!");
+ $selectDB = @mysql_select_db($dbName, $connect) or die("Cannot find and select
<b>".$dbName."</b>!");
+
+ // Delete (set nothing) the vars after usage:
+ $dbHost = "";
+ $dbUser = "";
+ $dbPass = "";
+ $dbName = "";');
+
+ fputs($fp, "\n ?>");
+ flock($fp, 3);
+ fclose($fp);
+ echo "OK<br />";
+
echo "<p> </p>";
echo "<p><b>RosCMS was set up
successfully!</b></p>";
+
+ echo "<p> </p>";
+ echo "<p>Delete this \"install.php\" file on the server and <a
href=\"index.php?page=login\">then login into RosCMS</a> with your
account.</p>";
+
}
else {
?>
- <h1>RosCMS - Install Script - Step1</h1>
+ <h1>RosCMS v3 - Install Script - Step1</h1>
<p><i>© Klemens Friedl 2005-2007, GNU GPL 2
license</i></p>
<p> </p>
<?php
if (get_magic_quotes_gpc()) {
die("<p>ERROR: Disable 'magic quotes' in php.ini
(=Off)</p>");
}
-?>
- <p>Your PHP installation is configured correctly. Click <i>Next</i>
to continue!</p>
+
+ $phpver = explode('-', phpversion());
+ $phpver = $phpver[0];
+
+ if (substr($phpver, 0, 1) <= 3) {
+ die("<p>ERROR: RosCMS v3 don't work with versions prior to PHP
4!</p>");
+ }
+ else if (substr($phpver, 0, 1) == 4) {
+ echo "<p>RosCMS v3 should work fine with PHP 4, make sure you use an
up-to-date PHP 4 version. If possible and reasonable, upgrade to PHP 5 or
later.</p>";
+ }
+?>
+ <p>Your PHP installation is configured correctly. RosCMS has been tested with
MySQL 4 and 5. </p>
+ <p>Click <i>Next</i> to continue!</p>
<p><a href="install.php?ready=step2"><b>Next
></b></a></p>
<?php
Added:
trunk/web/reactos.org/htdocs/roscms/roscms.sql
URL:
http://svn.reactos.org/svn/reactos/trunk/web/reactos.org/htdocs/roscms/rosc…
==============================================================================
---
trunk/web/reactos.org/htdocs/roscms/roscms.sql (added)
+++
trunk/web/reactos.org/htdocs/roscms/roscms.sql Tue Aug 14 19:26:16 2007
@@ -1,0 +1,486 @@
+-- Database: `roscms`
+--
+-- Date: 2007-08-13 11:12
+-- MySQL-Version: 5.0.33
+-- PHP-Version: 5.2.1
+--
+
+-- --------------------------------------------------------
+
+--
+-- Tabellenstruktur für Tabelle `data_`
+--
+
+CREATE TABLE `data_` (
+ `data_id` int(11) NOT NULL auto_increment,
+ `data_name` varchar(100) collate utf8_unicode_ci NOT NULL COMMENT 'together with
page_type unique entries',
+ `data_type` varchar(10) collate utf8_unicode_ci NOT NULL COMMENT '"page",
"layout", "content", "script"',
+ `data_acl` varchar(50) collate utf8_unicode_ci NOT NULL default 'default',
+ PRIMARY KEY (`data_id`),
+ KEY `data_name` (`data_name`,`data_type`),
+ KEY `data_type` (`data_type`),
+ KEY `data_acl` (`data_acl`)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci COMMENT='all RosCMS v1
"pages", "content", "dyncontent" and
"inctext"';
+
+INSERT INTO `data_` VALUES (1, 'index', 'page', 'defaultpage');
+INSERT INTO `data_` VALUES (2, 'default', 'template', 'layout');
+INSERT INTO `data_` VALUES (3, 'index', 'content', 'default');
+INSERT INTO `data_` VALUES (4, 'news', 'script', 'script');
+INSERT INTO `data_` VALUES (5, 'news_page', 'content',
'default');
+
+
+-- --------------------------------------------------------
+
+--
+-- Tabellenstruktur für Tabelle `data_a`
+--
+
+CREATE TABLE `data_a` (
+ `data_id` int(11) NOT NULL auto_increment,
+ `data_name` varchar(100) collate utf8_unicode_ci NOT NULL COMMENT 'together with
page_type unique entries',
+ `data_type` varchar(10) collate utf8_unicode_ci NOT NULL COMMENT '"page",
"layout", "content", "script"',
+ `data_acl` varchar(50) collate utf8_unicode_ci NOT NULL default 'default',
+ PRIMARY KEY (`data_id`),
+ KEY `data_name` (`data_name`,`data_type`),
+ KEY `data_type` (`data_type`),
+ KEY `data_acl` (`data_acl`)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci COMMENT='all RosCMS v1
"pages", "content", "dyncontent" and
"inctext"';
+
+-- --------------------------------------------------------
+
+--
+-- Tabellenstruktur für Tabelle `data_revision`
+--
+
+CREATE TABLE `data_revision` (
+ `rev_id` int(11) NOT NULL auto_increment COMMENT 'unique revisions id',
+ `data_id` int(11) NOT NULL,
+ `rev_version` int(11) NOT NULL COMMENT 'version number increase with every entry
change',
+ `rev_language` varchar(10) collate utf8_unicode_ci NOT NULL COMMENT 'language code
("en", "de", etc.)',
+ `rev_usrid` int(11) NOT NULL COMMENT 'user id who saved the entry',
+ `rev_datetime` datetime NOT NULL,
+ `rev_date` date NOT NULL,
+ `rev_time` time NOT NULL,
+ PRIMARY KEY (`rev_id`),
+ KEY `data_id` (`data_id`),
+ KEY `rev_language` (`rev_language`),
+ KEY `rev_version` (`rev_version`),
+ KEY `rev_datetime` (`rev_datetime`),
+ KEY `rev_usrid` (`rev_usrid`)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
+
+INSERT INTO `data_revision` VALUES (1, 1, 1, 'en', 1, '2007-08-13
17:03:44', '2007-08-13', '17:03:44');
+INSERT INTO `data_revision` VALUES (2, 2, 1, 'en', 1, '2007-08-13
17:05:03', '2007-08-13', '17:05:03');
+INSERT INTO `data_revision` VALUES (6, 3, 2, 'en', 1, '2007-08-13
17:15:15', '2007-08-13', '17:15:15');
+INSERT INTO `data_revision` VALUES (5, 4, 2, 'en', 1, '2007-08-13
17:11:36', '2007-08-13', '17:11:36');
+INSERT INTO `data_revision` VALUES (7, 5, 1, 'en', 1, '2007-08-13
17:15:20', '2007-08-13', '17:15:20');
+INSERT INTO `data_revision` VALUES (8, 5, 1, 'en', 1, '2007-08-13
17:15:45', '2007-08-13', '17:15:45');
+
+
+-- --------------------------------------------------------
+
+--
+-- Tabellenstruktur für Tabelle `data_revision_a`
+--
+
+CREATE TABLE `data_revision_a` (
+ `rev_id` int(11) NOT NULL auto_increment COMMENT 'unique revisions id',
+ `data_id` int(11) NOT NULL,
+ `rev_version` int(11) NOT NULL COMMENT 'version number increase with every entry
change',
+ `rev_language` varchar(10) collate utf8_unicode_ci NOT NULL COMMENT 'language code
("en", "de", etc.)',
+ `rev_usrid` int(11) NOT NULL COMMENT 'user id who saved the entry',
+ `rev_datetime` datetime NOT NULL,
+ `rev_date` date NOT NULL,
+ `rev_time` time NOT NULL,
+ PRIMARY KEY (`rev_id`),
+ KEY `data_id` (`data_id`),
+ KEY `rev_language` (`rev_language`),
+ KEY `rev_version` (`rev_version`),
+ KEY `rev_datetime` (`rev_datetime`),
+ KEY `rev_usrid` (`rev_usrid`)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
+
+-- --------------------------------------------------------
+
+--
+-- Tabellenstruktur für Tabelle `data_security`
+--
+
+CREATE TABLE `data_security` (
+ `sec_name` varchar(50) collate utf8_unicode_ci NOT NULL,
+ `sec_fullname` varchar(100) collate utf8_unicode_ci NOT NULL,
+ `sec_description` varchar(255) collate utf8_unicode_ci NOT NULL,
+ `sec_branch` varchar(10) collate utf8_unicode_ci NOT NULL,
+ `sec_lev1_read` tinyint(4) NOT NULL default '0',
+ `sec_lev1_write` tinyint(4) NOT NULL default '0',
+ `sec_lev1_add` tinyint(4) NOT NULL default '0',
+ `sec_lev1_pub` tinyint(4) NOT NULL default '0',
+ `sec_lev1_trans` tinyint(4) NOT NULL default '0',
+ `sec_lev2_read` tinyint(4) NOT NULL default '0',
+ `sec_lev2_write` tinyint(4) NOT NULL default '0',
+ `sec_lev2_add` tinyint(4) NOT NULL default '0',
+ `sec_lev2_pub` tinyint(4) NOT NULL default '0',
+ `sec_lev2_trans` tinyint(4) NOT NULL default '0',
+ `sec_lev3_read` tinyint(4) NOT NULL default '0',
+ `sec_lev3_write` tinyint(4) NOT NULL default '0',
+ `sec_lev3_add` tinyint(4) NOT NULL default '0',
+ `sec_lev3_pub` tinyint(4) NOT NULL default '0',
+ `sec_lev3_trans` tinyint(4) NOT NULL default '0',
+ `sec_allow` varchar(255) collate utf8_unicode_ci NOT NULL,
+ `sec_deny` varchar(255) collate utf8_unicode_ci NOT NULL,
+ PRIMARY KEY (`sec_name`)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci COMMENT='RosCMS content
security';
+
+INSERT INTO `data_security` VALUES ('default', 'Content (default)',
'Default content security ACL; normal translator cannot publish nor add new
content', 'website', 1, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, '',
'');
+INSERT INTO `data_security` VALUES ('script', 'Script or Variable',
'Entry contain scripts, variables or similar content which can only be accessed and
altered by admins.', 'website', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 0,
'', '');
+INSERT INTO `data_security` VALUES ('layout', 'Layout', 'Website
layout related content, changing may destroy the website layout, so be careful!',
'website', 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 1, 1, 1, 1, 1, '',
'|transmaint|');
+INSERT INTO `data_security` VALUES ('announcement', 'Official
announcement', 'Official announcement, which shouldn''t be altered by
anyone except admins and devs', 'website', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1,
1, 1, 1, '|developer|', '');
+INSERT INTO `data_security` VALUES ('notrans', 'No translation needed',
'Content don''t need a translation.', '', 1, 0, 0, 0, 0, 1, 1, 1,
1, 0, 1, 1, 1, 1, 1, '', '');
+INSERT INTO `data_security` VALUES ('rosversion', 'ReactOS versions
number', 'Currrent ReactOS version number, change the related contents on every
release day!', 'website', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 0,
'|developer|', '');
+INSERT INTO `data_security` VALUES ('defaultpage', 'Page (default)',
'Default page security ACL', 'website', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1,
1, 1, 1, 1, '|developer|', '');
+INSERT INTO `data_security` VALUES ('defaultmenu', 'Menu (default)',
'Menu content which can be translated by language maintainers', 'website',
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, '|transmaint|', '');
+INSERT INTO `data_security` VALUES ('system', 'System', 'RosCMS
system', 'website', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
'|ros_sadmin|', '');
+INSERT INTO `data_security` VALUES ('readonly', 'Read-Only', 'Read
only, noone can alter this', 'website', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0,
0, 0, '', '');
+INSERT INTO `data_security` VALUES ('langmaint', 'Language Maintainer',
'Language-Group related content', 'website', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
1, 1, 1, 1, 1, '|transmaint|', '');
+
+
+-- --------------------------------------------------------
+
+--
+-- Tabellenstruktur für Tabelle `data_stext`
+--
+
+CREATE TABLE `data_stext` (
+ `stext_id` int(11) NOT NULL auto_increment,
+ `data_rev_id` int(11) NOT NULL,
+ `stext_name` varchar(100) collate utf8_unicode_ci NOT NULL,
+ `stext_content` varchar(255) collate utf8_unicode_ci NOT NULL,
+ PRIMARY KEY (`stext_id`),
+ KEY `data_rev_id` (`data_rev_id`),
+ FULLTEXT KEY `stext_content` (`stext_content`)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
+
+INSERT INTO `data_stext` VALUES (14, 1, 'description', 'test page');
+INSERT INTO `data_stext` VALUES (13, 1, 'comment', '');
+INSERT INTO `data_stext` VALUES (12, 2, 'description', 'test template');
+INSERT INTO `data_stext` VALUES (15, 1, 'title', 'Index');
+INSERT INTO `data_stext` VALUES (19, 6, 'description', 'test content');
+INSERT INTO `data_stext` VALUES (18, 5, 'description', 'news php
script');
+INSERT INTO `data_stext` VALUES (22, 7, 'description', 'news issue 1');
+INSERT INTO `data_stext` VALUES (23, 7, 'title', 'News_page');
+INSERT INTO `data_stext` VALUES (26, 8, 'description', 'news issue 2');
+INSERT INTO `data_stext` VALUES (27, 8, 'title', 'News_page');
+
+
+-- --------------------------------------------------------
+
+--
+-- Tabellenstruktur für Tabelle `data_stext_a`
+--
+
+CREATE TABLE `data_stext_a` (
+ `stext_id` int(11) NOT NULL auto_increment,
+ `data_rev_id` int(11) NOT NULL,
+ `stext_name` varchar(100) collate utf8_unicode_ci NOT NULL,
+ `stext_content` varchar(255) collate utf8_unicode_ci NOT NULL,
+ PRIMARY KEY (`stext_id`),
+ KEY `data_rev_id` (`data_rev_id`),
+ FULLTEXT KEY `stext_content` (`stext_content`)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
+
+-- --------------------------------------------------------
+
+--
+-- Tabellenstruktur für Tabelle `data_tag`
+--
+
+CREATE TABLE `data_tag` (
+ `tag_id` int(11) NOT NULL auto_increment,
+ `data_id` int(11) NOT NULL,
+ `data_rev_id` int(11) NOT NULL,
+ `tag_name_id` int(11) NOT NULL,
+ `tag_value_id` int(11) NOT NULL,
+ `tag_usrid` int(11) NOT NULL,
+ PRIMARY KEY (`tag_id`),
+ KEY `data_id` (`data_id`),
+ KEY `data_rev_id` (`data_rev_id`),
+ KEY `tag_name_id` (`tag_name_id`),
+ KEY `tag_value_id` (`tag_value_id`),
+ KEY `tag_usrid` (`tag_usrid`)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
+
+INSERT INTO `data_tag` VALUES (11, 1, 1, 1, 5, -1);
+INSERT INTO `data_tag` VALUES (2, 1, 1, 2, 2, -1);
+INSERT INTO `data_tag` VALUES (10, 2, 2, 1, 5, -1);
+INSERT INTO `data_tag` VALUES (15, 4, 5, 5, 7, -1);
+INSERT INTO `data_tag` VALUES (14, 4, 5, 1, 5, -1);
+INSERT INTO `data_tag` VALUES (24, 3, 6, 1, 5, -1);
+INSERT INTO `data_tag` VALUES (22, 5, 7, 1, 5, -1);
+INSERT INTO `data_tag` VALUES (18, 5, 7, 6, 9, -1);
+INSERT INTO `data_tag` VALUES (21, 5, 8, 1, 5, -1);
+INSERT INTO `data_tag` VALUES (20, 5, 8, 6, 10, -1);
+
+
+-- --------------------------------------------------------
+
+--
+-- Tabellenstruktur für Tabelle `data_tag_a`
+--
+
+CREATE TABLE `data_tag_a` (
+ `tag_id` int(11) NOT NULL auto_increment,
+ `data_id` int(11) NOT NULL,
+ `data_rev_id` int(11) NOT NULL,
+ `tag_name_id` int(11) NOT NULL,
+ `tag_value_id` int(11) NOT NULL,
+ `tag_usrid` int(11) NOT NULL,
+ PRIMARY KEY (`tag_id`),
+ KEY `data_id` (`data_id`),
+ KEY `data_rev_id` (`data_rev_id`),
+ KEY `tag_name_id` (`tag_name_id`),
+ KEY `tag_value_id` (`tag_value_id`),
+ KEY `tag_usrid` (`tag_usrid`)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
+
+-- --------------------------------------------------------
+
+--
+-- Tabellenstruktur für Tabelle `data_tag_name`
+--
+
+CREATE TABLE `data_tag_name` (
+ `tn_id` int(11) NOT NULL auto_increment,
+ `tn_name` varchar(100) collate utf8_unicode_ci NOT NULL,
+ PRIMARY KEY (`tn_id`)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
+
+INSERT INTO `data_tag_name` VALUES (1, 'status');
+INSERT INTO `data_tag_name` VALUES (2, 'extension');
+INSERT INTO `data_tag_name` VALUES (4, 'star');
+INSERT INTO `data_tag_name` VALUES (5, 'kind');
+INSERT INTO `data_tag_name` VALUES (6, 'number');
+
+
+-- --------------------------------------------------------
+
+--
+-- Tabellenstruktur für Tabelle `data_tag_name_a`
+--
+
+CREATE TABLE `data_tag_name_a` (
+ `tn_id` int(11) NOT NULL auto_increment,
+ `tn_name` varchar(100) collate utf8_unicode_ci NOT NULL,
+ PRIMARY KEY (`tn_id`)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
+
+-- --------------------------------------------------------
+
+--
+-- Tabellenstruktur für Tabelle `data_tag_value`
+--
+
+CREATE TABLE `data_tag_value` (
+ `tv_id` int(11) NOT NULL auto_increment,
+ `tv_value` varchar(255) collate utf8_unicode_ci NOT NULL,
+ PRIMARY KEY (`tv_id`)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
+
+INSERT INTO `data_tag_value` VALUES (7, 'php');
+INSERT INTO `data_tag_value` VALUES (2, 'html');
+INSERT INTO `data_tag_value` VALUES (4, 'off');
+INSERT INTO `data_tag_value` VALUES (5, 'stable');
+INSERT INTO `data_tag_value` VALUES (9, '1');
+INSERT INTO `data_tag_value` VALUES (10, '2');
+
+
+-- --------------------------------------------------------
+
+--
+-- Tabellenstruktur für Tabelle `data_tag_value_a`
+--
+
+CREATE TABLE `data_tag_value_a` (
+ `tv_id` int(11) NOT NULL auto_increment,
+ `tv_value` varchar(255) collate utf8_unicode_ci NOT NULL,
+ PRIMARY KEY (`tv_id`)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
+
+-- --------------------------------------------------------
+
+--
+-- Tabellenstruktur für Tabelle `data_text`
+--
+
+CREATE TABLE `data_text` (
+ `text_id` int(11) NOT NULL auto_increment,
+ `data_rev_id` int(11) NOT NULL,
+ `text_name` varchar(100) collate utf8_unicode_ci NOT NULL,
+ `text_content` text collate utf8_unicode_ci NOT NULL,
+ PRIMARY KEY (`text_id`),
+ KEY `data_rev_id` (`data_rev_id`),
+ FULLTEXT KEY `text_content` (`text_content`)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
+
+INSERT INTO `data_text` VALUES (9, 1, 'content', '[#templ_default]');
+INSERT INTO `data_text` VALUES (8, 2, 'content',
'[#cont_head][#cont_menu_top][#cont_menu_side][#cont_contmenu_[#%NAME%]][#cont_menu_search][#cont_menu_language][#cont_menu_misc][#cont_%NAME%][#cont_bottom]');
+INSERT INTO `data_text` VALUES (13, 6, 'content', '<h1>Welcome to
RosCMS v3</h1><p>RosCMS test page</p>[#inc_news]');
+INSERT INTO `data_text` VALUES (15, 7, 'content', 'news #1 ...');
+INSERT INTO `data_text` VALUES (17, 8, 'content', 'news #2');
+INSERT INTO `data_text` VALUES (12, 5, 'content', '<h3>News</h3>
<?php $tmp_year = "2085"; $query_content = mysql_query("SELECT
d.data_name, r.rev_usrid, s1.stext_content AS ''title'', s2.stext_content
AS ''description'', v.tv_value as ''numb'', r.rev_date
FROM data_ d, data_revision r, data_stext s1, data_stext s2, data_tag a, data_tag_name n,
data_tag_value v WHERE d.data_name = ''news_page'' AND d.data_type =
''content'' AND r.data_id = d.data_id AND (r.rev_language =
''".mysql_real_escape_string($roscms_template_var_lang)."'' OR
r.rev_language = ''en'') AND r.rev_version > 0 AND s1.data_rev_id =
r.rev_id AND s1.stext_name = ''title'' AND s2.data_rev_id = r.rev_id
AND s2.stext_name = ''description'' AND r.data_id = a.data_id AND
r.rev_id = a.data_rev_id AND a.tag_usrid = ''-1'' AND a.tag_name_id =
n.tn_id AND n.tn_name = ''number'' AND a.tag_value_id = v.tv_id ORDER
BY r.rev_datetime DESC LIMIT 3;"); while($result_content =
mysql_fetch_array($query_content)) {
+if ($tmp_year > substr($result_content[''rev_date''], 0, 4)) {
$tmp_year = substr($result_content[''rev_date''], 0, 4); echo
"<h3>".$tmp_year."</h3>"; } $query_usraccount=
mysql_query("SELECT user_name, user_fullname FROM users WHERE user_id =
''".mysql_real_escape_string($result_content["rev_usrid"])."''
LIMIT 1;"); $result_usraccount=mysql_fetch_array($query_usraccount); ?> <p
align="left"><b><font color="#666666"><?php echo
$result_content[''rev_date'']; ?>, <?php if
($result_usraccount[''user_fullname'']) { echo
$result_usraccount[''user_fullname'']; } else { echo
$result_usraccount[''user_name'']; } ?>
</font></b><br /> <b><a href="<?php echo
"[#link_".$result_content["data_name"]."_".$result_content["numb"]."]";
?>"><?php echo $result_content["title"];
?></a></b><br /> <?php echo
$result_content["description"]; ?></p> <?php } // end while ?>
');
+
+
+-- --------------------------------------------------------
+
+--
+-- Tabellenstruktur für Tabelle `data_text_a`
+--
+
+CREATE TABLE `data_text_a` (
+ `text_id` int(11) NOT NULL auto_increment,
+ `data_rev_id` int(11) NOT NULL,
+ `text_name` varchar(100) collate utf8_unicode_ci NOT NULL,
+ `text_content` text collate utf8_unicode_ci NOT NULL,
+ PRIMARY KEY (`text_id`),
+ KEY `data_rev_id` (`data_rev_id`),
+ FULLTEXT KEY `text_content` (`text_content`)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
+
+-- --------------------------------------------------------
+
+--
+-- Tabellenstruktur für Tabelle `data_user_filter`
+--
+
+CREATE TABLE `data_user_filter` (
+ `filt_id` int(11) NOT NULL auto_increment,
+ `filt_usrid` int(11) NOT NULL,
+ `filt_title` varchar(50) collate utf8_unicode_ci NOT NULL,
+ `filt_type` smallint(6) NOT NULL default '1',
+ `filt_string` varchar(255) collate utf8_unicode_ci NOT NULL,
+ `filt_datetime` datetime NOT NULL,
+ `filt_usage` int(11) NOT NULL,
+ `filt_usagedate` datetime NOT NULL,
+ PRIMARY KEY (`filt_id`),
+ KEY `filt_usrid` (`filt_usrid`),
+ KEY `filt_name` (`filt_title`)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
+
+-- --------------------------------------------------------
+
+--
+-- Tabellenstruktur für Tabelle `languages`
+--
+
+CREATE TABLE `languages` (
+ `lang_id` varchar(10) collate utf8_unicode_ci NOT NULL default '',
+ `lang_name` varchar(100) collate utf8_unicode_ci NOT NULL default '',
+ `lang_name_org` varchar(100) collate utf8_unicode_ci NOT NULL,
+ `lang_level` int(11) NOT NULL default '0',
+ PRIMARY KEY (`lang_id`)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci COMMENT='available
languages';
+
+INSERT INTO `languages` VALUES ('en', 'English', 'English', 10);
+INSERT INTO `languages` VALUES ('de', 'German', 'Deutsch', 8);
+
+
+-- --------------------------------------------------------
+
+--
+-- Tabellenstruktur für Tabelle `subsys_mappings`
+--
+
+CREATE TABLE `subsys_mappings` (
+ `map_roscms_userid` bigint(20) NOT NULL default '0',
+ `map_subsys_name` varchar(10) character set utf8 NOT NULL default '',
+ `map_subsys_userid` int(7) NOT NULL default '0',
+ PRIMARY KEY (`map_roscms_userid`,`map_subsys_name`)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
+
+-- --------------------------------------------------------
+
+--
+-- Tabellenstruktur für Tabelle `user_sessions`
+--
+
+CREATE TABLE `user_sessions` (
+ `usersession_id` varchar(32) character set utf8 NOT NULL default '' COMMENT
'Unique ID of this session',
+ `usersession_user_id` bigint(20) NOT NULL default '0' COMMENT 'User this
session belongs to',
+ `usersession_expires` datetime default NULL COMMENT 'Expiry date/time (NULL if does
not expire)',
+ `usersession_browseragent` varchar(255) character set utf8 NOT NULL default ''
COMMENT 'HTTP_USER_AGENT when this session was created',
+ `usersession_ipaddress` varchar(15) character set utf8 NOT NULL default ''
COMMENT 'IP address from which this session was created',
+ `usersession_created` datetime NOT NULL default '0000-00-00 00:00:00' COMMENT
'session created (date/time) - all session will get deleted ... by date',
+ PRIMARY KEY (`usersession_id`)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci PACK_KEYS=0
COMMENT='Sessions';
+
+-- --------------------------------------------------------
+
+--
+-- Tabellenstruktur für Tabelle `usergroup_members`
+--
+
+CREATE TABLE `usergroup_members` (
+ `usergroupmember_userid` bigint(20) NOT NULL default '0',
+ `usergroupmember_usergroupid` varchar(10) collate utf8_unicode_ci NOT NULL default
'user'
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
+
+-- --------------------------------------------------------
+
+--
+-- Tabellenstruktur für Tabelle `usergroups`
+--
+
+CREATE TABLE `usergroups` (
+ `usrgroup_name_id` varchar(10) collate utf8_unicode_ci NOT NULL default '',
+ `usrgroup_name` varchar(100) collate utf8_unicode_ci NOT NULL default '',
+ `usrgroup_intern_id` varchar(25) collate utf8_unicode_ci NOT NULL default '',
+ `usrgroup_seclev` tinyint(4) NOT NULL default '0',
+ `usrgroup_securitylevel` tinyint(4) NOT NULL default '0',
+ `usrgroup_description` varchar(255) collate utf8_unicode_ci NOT NULL default
'',
+ PRIMARY KEY (`usrgroup_name_id`),
+ UNIQUE KEY `usrgroup_name` (`usrgroup_name`)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
+
+INSERT INTO `usergroups` VALUES ('ros_admin', 'Administrator',
'roscms_usrgrp_admin', 3, 70, 'Administrator-Group');
+INSERT INTO `usergroups` VALUES ('user', 'User',
'roscms_usrgrp_user', 0, 0, 'Normal Visitors');
+INSERT INTO `usergroups` VALUES ('developer', 'Developer',
'roscms_usrgrp_dev', 2, 50, 'Developer');
+INSERT INTO `usergroups` VALUES ('moderator', 'Moderator',
'roscms_usrgrp_team', 2, 20, 'Website Moderators');
+INSERT INTO `usergroups` VALUES ('translator', 'Translator',
'roscms_usrgrp_trans', 1, 10, 'Translators');
+INSERT INTO `usergroups` VALUES ('ros_sadmin', 'Super-Administrator',
'roscms_usrgrp_sadmin', 3, 100, 'Super-Administrator-Group');
+INSERT INTO `usergroups` VALUES ('transmaint', 'Tranlation Maintainer',
'roscms_usrgrp_trans', 2, 15, 'Translation Maintainer');
+
+
+-- --------------------------------------------------------
+
+--
+-- Tabellenstruktur für Tabelle `users`
+--
+
+CREATE TABLE `users` (
+ `user_id` bigint(20) NOT NULL auto_increment,
+ `user_name` varchar(20) collate utf8_unicode_ci NOT NULL default '',
+ `user_roscms_password` varchar(32) collate utf8_unicode_ci NOT NULL default
'',
+ `user_roscms_getpwd_id` varchar(50) collate utf8_unicode_ci NOT NULL default
'',
+ `user_timestamp_touch` varchar(50) collate utf8_unicode_ci NOT NULL default
'',
+ `user_timestamp_touch2` timestamp NULL default CURRENT_TIMESTAMP on update
CURRENT_TIMESTAMP,
+ `user_login_counter` bigint(20) NOT NULL default '0',
+ `user_account_enabled` varchar(10) collate utf8_unicode_ci NOT NULL default
'no',
+ `user_account_hidden` varchar(5) collate utf8_unicode_ci NOT NULL default
'no',
+ `user_register` timestamp NULL default NULL,
+ `user_fullname` varchar(100) collate utf8_unicode_ci NOT NULL default '',
+ `user_email` varchar(150) collate utf8_unicode_ci NOT NULL default '',
+ `user_website` varchar(150) collate utf8_unicode_ci NOT NULL default '',
+ `user_language` varchar(2) collate utf8_unicode_ci NOT NULL default '',
+ `user_country` varchar(2) collate utf8_unicode_ci NOT NULL default '',
+ `user_timezone` varchar(3) collate utf8_unicode_ci NOT NULL default '',
+ `user_occupation` varchar(50) collate utf8_unicode_ci NOT NULL default '',
+ `user_description` varchar(255) collate utf8_unicode_ci NOT NULL default '',
+ `user_setting_multisession` varchar(5) collate utf8_unicode_ci NOT NULL default
'false',
+ `user_setting_browseragent` varchar(5) collate utf8_unicode_ci NOT NULL default
'true',
+ `user_setting_ipaddress` varchar(5) collate utf8_unicode_ci NOT NULL default
'true',
+ `user_setting_timeout` varchar(5) collate utf8_unicode_ci NOT NULL default
'true',
+ PRIMARY KEY (`user_id`),
+ UNIQUE KEY `user_name` (`user_name`),
+ UNIQUE KEY `user_email` (`user_email`)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci COMMENT='RosCMS User
Table';
+
Modified:
trunk/web/reactos.org/sql/roscms.sql
URL:
http://svn.reactos.org/svn/reactos/trunk/web/reactos.org/sql/roscms.sql?rev…
==============================================================================
---
trunk/web/reactos.org/sql/roscms.sql (original)
+++
trunk/web/reactos.org/sql/roscms.sql Tue Aug 14 19:26:16 2007
@@ -1,58 +1,55 @@
--- phpMyAdmin SQL Dump
--- version 2.9.2
---
http://www.phpmyadmin.net
---
--- Host: localhost
--- Erstellungszeit: 27. Mai 2007 um 13:02
--- Server Version: 5.0.33
+-- Database: `roscms`
+--
+-- Date: 2007-08-13 11:12
+-- MySQL-Version: 5.0.33
-- PHP-Version: 5.2.1
--
--- Datenbank: `roscms`
---
-
--- --------------------------------------------------------
-
---
--- Tabellenstruktur für Tabelle `content`
---
-
-CREATE TABLE `content` (
- `content_id` bigint(20) NOT NULL auto_increment,
- `content_name` varchar(100) collate utf8_unicode_ci NOT NULL default '',
- `content_lang` varchar(10) collate utf8_unicode_ci NOT NULL default 'all',
- `content_text` text collate utf8_unicode_ci NOT NULL,
- `content_version` int(11) NOT NULL default '0',
- `content_active` tinyint(4) NOT NULL default '0',
- `content_visible` tinyint(4) NOT NULL default '0',
- `content_type` varchar(10) collate utf8_unicode_ci NOT NULL default 'default',
- `content_description` varchar(255) collate utf8_unicode_ci NOT NULL default
'',
- `content_editor` varchar(10) collate utf8_unicode_ci NOT NULL default '',
- `content_usrname_id` bigint(20) NOT NULL default '0',
- `content_date` date NOT NULL default '0000-00-00',
- `content_time` time NOT NULL default '00:00:00',
- `content_altered` varchar(1) collate utf8_unicode_ci NOT NULL default '0',
- PRIMARY KEY (`content_id`)
-) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci
COMMENT='Contents';
-
--- --------------------------------------------------------
-
---
--- Tabellenstruktur für Tabelle `data_`
+
+-- --------------------------------------------------------
+
+--
+-- Tabellenstruktur für Tabelle `data_`
--
CREATE TABLE `data_` (
`data_id` int(11) NOT NULL auto_increment,
`data_name` varchar(100) collate utf8_unicode_ci NOT NULL COMMENT 'together with
page_type unique entries',
`data_type` varchar(10) collate utf8_unicode_ci NOT NULL COMMENT '"page",
"layout", "content", "script"',
+ `data_acl` varchar(50) collate utf8_unicode_ci NOT NULL default 'default',
PRIMARY KEY (`data_id`),
KEY `data_name` (`data_name`,`data_type`),
- KEY `data_type` (`data_type`)
-) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci COMMENT='all RosCMS v2
"pages", "content", "dyncontent" and
"inctext"';
-
--- --------------------------------------------------------
-
---
--- Tabellenstruktur für Tabelle `data_revision`
+ KEY `data_type` (`data_type`),
+ KEY `data_acl` (`data_acl`)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci COMMENT='all RosCMS v1
"pages", "content", "dyncontent" and
"inctext"';
+
+INSERT INTO `data_` VALUES (1, 'index', 'page', 'defaultpage');
+INSERT INTO `data_` VALUES (2, 'default', 'template', 'layout');
+INSERT INTO `data_` VALUES (3, 'index', 'content', 'default');
+INSERT INTO `data_` VALUES (4, 'news', 'script', 'script');
+INSERT INTO `data_` VALUES (5, 'news_page', 'content',
'default');
+
+
+-- --------------------------------------------------------
+
+--
+-- Tabellenstruktur für Tabelle `data_a`
+--
+
+CREATE TABLE `data_a` (
+ `data_id` int(11) NOT NULL auto_increment,
+ `data_name` varchar(100) collate utf8_unicode_ci NOT NULL COMMENT 'together with
page_type unique entries',
+ `data_type` varchar(10) collate utf8_unicode_ci NOT NULL COMMENT '"page",
"layout", "content", "script"',
+ `data_acl` varchar(50) collate utf8_unicode_ci NOT NULL default 'default',
+ PRIMARY KEY (`data_id`),
+ KEY `data_name` (`data_name`,`data_type`),
+ KEY `data_type` (`data_type`),
+ KEY `data_acl` (`data_acl`)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci COMMENT='all RosCMS v1
"pages", "content", "dyncontent" and
"inctext"';
+
+-- --------------------------------------------------------
+
+--
+-- Tabellenstruktur für Tabelle `data_revision`
--
CREATE TABLE `data_revision` (
@@ -67,13 +64,23 @@
PRIMARY KEY (`rev_id`),
KEY `data_id` (`data_id`),
KEY `rev_language` (`rev_language`),
- KEY `rev_version` (`rev_version`)
-) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
-
--- --------------------------------------------------------
-
---
--- Tabellenstruktur für Tabelle `data_revision_a`
+ KEY `rev_version` (`rev_version`),
+ KEY `rev_datetime` (`rev_datetime`),
+ KEY `rev_usrid` (`rev_usrid`)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
+
+INSERT INTO `data_revision` VALUES (1, 1, 1, 'en', 1, '2007-08-13
17:03:44', '2007-08-13', '17:03:44');
+INSERT INTO `data_revision` VALUES (2, 2, 1, 'en', 1, '2007-08-13
17:05:03', '2007-08-13', '17:05:03');
+INSERT INTO `data_revision` VALUES (6, 3, 2, 'en', 1, '2007-08-13
17:15:15', '2007-08-13', '17:15:15');
+INSERT INTO `data_revision` VALUES (5, 4, 2, 'en', 1, '2007-08-13
17:11:36', '2007-08-13', '17:11:36');
+INSERT INTO `data_revision` VALUES (7, 5, 1, 'en', 1, '2007-08-13
17:15:20', '2007-08-13', '17:15:20');
+INSERT INTO `data_revision` VALUES (8, 5, 1, 'en', 1, '2007-08-13
17:15:45', '2007-08-13', '17:15:45');
+
+
+-- --------------------------------------------------------
+
+--
+-- Tabellenstruktur für Tabelle `data_revision_a`
--
CREATE TABLE `data_revision_a` (
@@ -86,13 +93,61 @@
`rev_date` date NOT NULL,
`rev_time` time NOT NULL,
PRIMARY KEY (`rev_id`),
- KEY `data_id` (`data_id`)
-) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
-
--- --------------------------------------------------------
-
---
--- Tabellenstruktur für Tabelle `data_stext`
+ KEY `data_id` (`data_id`),
+ KEY `rev_language` (`rev_language`),
+ KEY `rev_version` (`rev_version`),
+ KEY `rev_datetime` (`rev_datetime`),
+ KEY `rev_usrid` (`rev_usrid`)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
+
+-- --------------------------------------------------------
+
+--
+-- Tabellenstruktur für Tabelle `data_security`
+--
+
+CREATE TABLE `data_security` (
+ `sec_name` varchar(50) collate utf8_unicode_ci NOT NULL,
+ `sec_fullname` varchar(100) collate utf8_unicode_ci NOT NULL,
+ `sec_description` varchar(255) collate utf8_unicode_ci NOT NULL,
+ `sec_branch` varchar(10) collate utf8_unicode_ci NOT NULL,
+ `sec_lev1_read` tinyint(4) NOT NULL default '0',
+ `sec_lev1_write` tinyint(4) NOT NULL default '0',
+ `sec_lev1_add` tinyint(4) NOT NULL default '0',
+ `sec_lev1_pub` tinyint(4) NOT NULL default '0',
+ `sec_lev1_trans` tinyint(4) NOT NULL default '0',
+ `sec_lev2_read` tinyint(4) NOT NULL default '0',
+ `sec_lev2_write` tinyint(4) NOT NULL default '0',
+ `sec_lev2_add` tinyint(4) NOT NULL default '0',
+ `sec_lev2_pub` tinyint(4) NOT NULL default '0',
+ `sec_lev2_trans` tinyint(4) NOT NULL default '0',
+ `sec_lev3_read` tinyint(4) NOT NULL default '0',
+ `sec_lev3_write` tinyint(4) NOT NULL default '0',
+ `sec_lev3_add` tinyint(4) NOT NULL default '0',
+ `sec_lev3_pub` tinyint(4) NOT NULL default '0',
+ `sec_lev3_trans` tinyint(4) NOT NULL default '0',
+ `sec_allow` varchar(255) collate utf8_unicode_ci NOT NULL,
+ `sec_deny` varchar(255) collate utf8_unicode_ci NOT NULL,
+ PRIMARY KEY (`sec_name`)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci COMMENT='RosCMS content
security';
+
+INSERT INTO `data_security` VALUES ('default', 'Content (default)',
'Default content security ACL; normal translator cannot publish nor add new
content', 'website', 1, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, '',
'');
+INSERT INTO `data_security` VALUES ('script', 'Script or Variable',
'Entry contain scripts, variables or similar content which can only be accessed and
altered by admins.', 'website', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 0,
'', '');
+INSERT INTO `data_security` VALUES ('layout', 'Layout', 'Website
layout related content, changing may destroy the website layout, so be careful!',
'website', 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 1, 1, 1, 1, 1, '',
'|transmaint|');
+INSERT INTO `data_security` VALUES ('announcement', 'Official
announcement', 'Official announcement, which shouldn''t be altered by
anyone except admins and devs', 'website', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1,
1, 1, 1, '|developer|', '');
+INSERT INTO `data_security` VALUES ('notrans', 'No translation needed',
'Content don''t need a translation.', '', 1, 0, 0, 0, 0, 1, 1, 1,
1, 0, 1, 1, 1, 1, 1, '', '');
+INSERT INTO `data_security` VALUES ('rosversion', 'ReactOS versions
number', 'Currrent ReactOS version number, change the related contents on every
release day!', 'website', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 0,
'|developer|', '');
+INSERT INTO `data_security` VALUES ('defaultpage', 'Page (default)',
'Default page security ACL', 'website', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1,
1, 1, 1, 1, '|developer|', '');
+INSERT INTO `data_security` VALUES ('defaultmenu', 'Menu (default)',
'Menu content which can be translated by language maintainers', 'website',
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, '|transmaint|', '');
+INSERT INTO `data_security` VALUES ('system', 'System', 'RosCMS
system', 'website', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
'|ros_sadmin|', '');
+INSERT INTO `data_security` VALUES ('readonly', 'Read-Only', 'Read
only, noone can alter this', 'website', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0,
0, 0, '', '');
+INSERT INTO `data_security` VALUES ('langmaint', 'Language Maintainer',
'Language-Group related content', 'website', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
1, 1, 1, 1, 1, '|transmaint|', '');
+
+
+-- --------------------------------------------------------
+
+--
+-- Tabellenstruktur für Tabelle `data_stext`
--
CREATE TABLE `data_stext` (
@@ -105,10 +160,22 @@
FULLTEXT KEY `stext_content` (`stext_content`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
--- --------------------------------------------------------
-
---
--- Tabellenstruktur für Tabelle `data_stext_a`
+INSERT INTO `data_stext` VALUES (14, 1, 'description', 'test page');
+INSERT INTO `data_stext` VALUES (13, 1, 'comment', '');
+INSERT INTO `data_stext` VALUES (12, 2, 'description', 'test template');
+INSERT INTO `data_stext` VALUES (15, 1, 'title', 'Index');
+INSERT INTO `data_stext` VALUES (19, 6, 'description', 'test content');
+INSERT INTO `data_stext` VALUES (18, 5, 'description', 'news php
script');
+INSERT INTO `data_stext` VALUES (22, 7, 'description', 'news issue 1');
+INSERT INTO `data_stext` VALUES (23, 7, 'title', 'News_page');
+INSERT INTO `data_stext` VALUES (26, 8, 'description', 'news issue 2');
+INSERT INTO `data_stext` VALUES (27, 8, 'title', 'News_page');
+
+
+-- --------------------------------------------------------
+
+--
+-- Tabellenstruktur für Tabelle `data_stext_a`
--
CREATE TABLE `data_stext_a` (
@@ -117,13 +184,14 @@
`stext_name` varchar(100) collate utf8_unicode_ci NOT NULL,
`stext_content` varchar(255) collate utf8_unicode_ci NOT NULL,
PRIMARY KEY (`stext_id`),
+ KEY `data_rev_id` (`data_rev_id`),
FULLTEXT KEY `stext_content` (`stext_content`)
-) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
-
--- --------------------------------------------------------
-
---
--- Tabellenstruktur für Tabelle `data_tag`
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
+
+-- --------------------------------------------------------
+
+--
+-- Tabellenstruktur für Tabelle `data_tag`
--
CREATE TABLE `data_tag` (
@@ -141,10 +209,43 @@
KEY `tag_usrid` (`tag_usrid`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
--- --------------------------------------------------------
-
---
--- Tabellenstruktur für Tabelle `data_tag_name`
+INSERT INTO `data_tag` VALUES (11, 1, 1, 1, 5, -1);
+INSERT INTO `data_tag` VALUES (2, 1, 1, 2, 2, -1);
+INSERT INTO `data_tag` VALUES (10, 2, 2, 1, 5, -1);
+INSERT INTO `data_tag` VALUES (15, 4, 5, 5, 7, -1);
+INSERT INTO `data_tag` VALUES (14, 4, 5, 1, 5, -1);
+INSERT INTO `data_tag` VALUES (24, 3, 6, 1, 5, -1);
+INSERT INTO `data_tag` VALUES (22, 5, 7, 1, 5, -1);
+INSERT INTO `data_tag` VALUES (18, 5, 7, 6, 9, -1);
+INSERT INTO `data_tag` VALUES (21, 5, 8, 1, 5, -1);
+INSERT INTO `data_tag` VALUES (20, 5, 8, 6, 10, -1);
+
+
+-- --------------------------------------------------------
+
+--
+-- Tabellenstruktur für Tabelle `data_tag_a`
+--
+
+CREATE TABLE `data_tag_a` (
+ `tag_id` int(11) NOT NULL auto_increment,
+ `data_id` int(11) NOT NULL,
+ `data_rev_id` int(11) NOT NULL,
+ `tag_name_id` int(11) NOT NULL,
+ `tag_value_id` int(11) NOT NULL,
+ `tag_usrid` int(11) NOT NULL,
+ PRIMARY KEY (`tag_id`),
+ KEY `data_id` (`data_id`),
+ KEY `data_rev_id` (`data_rev_id`),
+ KEY `tag_name_id` (`tag_name_id`),
+ KEY `tag_value_id` (`tag_value_id`),
+ KEY `tag_usrid` (`tag_usrid`)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
+
+-- --------------------------------------------------------
+
+--
+-- Tabellenstruktur für Tabelle `data_tag_name`
--
CREATE TABLE `data_tag_name` (
@@ -153,10 +254,29 @@
PRIMARY KEY (`tn_id`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
--- --------------------------------------------------------
-
---
--- Tabellenstruktur für Tabelle `data_tag_value`
+INSERT INTO `data_tag_name` VALUES (1, 'status');
+INSERT INTO `data_tag_name` VALUES (2, 'extension');
+INSERT INTO `data_tag_name` VALUES (4, 'star');
+INSERT INTO `data_tag_name` VALUES (5, 'kind');
+INSERT INTO `data_tag_name` VALUES (6, 'number');
+
+
+-- --------------------------------------------------------
+
+--
+-- Tabellenstruktur für Tabelle `data_tag_name_a`
+--
+
+CREATE TABLE `data_tag_name_a` (
+ `tn_id` int(11) NOT NULL auto_increment,
+ `tn_name` varchar(100) collate utf8_unicode_ci NOT NULL,
+ PRIMARY KEY (`tn_id`)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
+
+-- --------------------------------------------------------
+
+--
+-- Tabellenstruktur für Tabelle `data_tag_value`
--
CREATE TABLE `data_tag_value` (
@@ -165,10 +285,30 @@
PRIMARY KEY (`tv_id`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
--- --------------------------------------------------------
-
---
--- Tabellenstruktur für Tabelle `data_text`
+INSERT INTO `data_tag_value` VALUES (7, 'php');
+INSERT INTO `data_tag_value` VALUES (2, 'html');
+INSERT INTO `data_tag_value` VALUES (4, 'off');
+INSERT INTO `data_tag_value` VALUES (5, 'stable');
+INSERT INTO `data_tag_value` VALUES (9, '1');
+INSERT INTO `data_tag_value` VALUES (10, '2');
+
+
+-- --------------------------------------------------------
+
+--
+-- Tabellenstruktur für Tabelle `data_tag_value_a`
+--
+
+CREATE TABLE `data_tag_value_a` (
+ `tv_id` int(11) NOT NULL auto_increment,
+ `tv_value` varchar(255) collate utf8_unicode_ci NOT NULL,
+ PRIMARY KEY (`tv_id`)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
+
+-- --------------------------------------------------------
+
+--
+-- Tabellenstruktur für Tabelle `data_text`
--
CREATE TABLE `data_text` (
@@ -181,10 +321,19 @@
FULLTEXT KEY `text_content` (`text_content`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
--- --------------------------------------------------------
-
---
--- Tabellenstruktur für Tabelle `data_text_a`
+INSERT INTO `data_text` VALUES (9, 1, 'content', '[#templ_default]');
+INSERT INTO `data_text` VALUES (8, 2, 'content',
'[#cont_head][#cont_menu_top][#cont_menu_side][#cont_contmenu_[#%NAME%]][#cont_menu_search][#cont_menu_language][#cont_menu_misc][#cont_%NAME%][#cont_bottom]');
+INSERT INTO `data_text` VALUES (13, 6, 'content', '<h1>Welcome to
RosCMS v3</h1><p>RosCMS test page</p>[#inc_news]');
+INSERT INTO `data_text` VALUES (15, 7, 'content', 'news #1 ...');
+INSERT INTO `data_text` VALUES (17, 8, 'content', 'news #2');
+INSERT INTO `data_text` VALUES (12, 5, 'content', '<h3>News</h3>
<?php $tmp_year = "2085"; $query_content = mysql_query("SELECT
d.data_name, r.rev_usrid, s1.stext_content AS ''title'', s2.stext_content
AS ''description'', v.tv_value as ''numb'', r.rev_date
FROM data_ d, data_revision r, data_stext s1, data_stext s2, data_tag a, data_tag_name n,
data_tag_value v WHERE d.data_name = ''news_page'' AND d.data_type =
''content'' AND r.data_id = d.data_id AND (r.rev_language =
''".mysql_real_escape_string($roscms_template_var_lang)."'' OR
r.rev_language = ''en'') AND r.rev_version > 0 AND s1.data_rev_id =
r.rev_id AND s1.stext_name = ''title'' AND s2.data_rev_id = r.rev_id
AND s2.stext_name = ''description'' AND r.data_id = a.data_id AND
r.rev_id = a.data_rev_id AND a.tag_usrid = ''-1'' AND a.tag_name_id =
n.tn_id AND n.tn_name = ''number'' AND a.tag_value_id = v.tv_id ORDER
BY r.rev_datetime DESC LIMIT 3;"); while($result_content =
mysql_fetch_array($query_content)) {
+if ($tmp_year > substr($result_content[''rev_date''], 0, 4)) {
$tmp_year = substr($result_content[''rev_date''], 0, 4); echo
"<h3>".$tmp_year."</h3>"; } $query_usraccount=
mysql_query("SELECT user_name, user_fullname FROM users WHERE user_id =
''".mysql_real_escape_string($result_content["rev_usrid"])."''
LIMIT 1;"); $result_usraccount=mysql_fetch_array($query_usraccount); ?> <p
align="left"><b><font color="#666666"><?php echo
$result_content[''rev_date'']; ?>, <?php if
($result_usraccount[''user_fullname'']) { echo
$result_usraccount[''user_fullname'']; } else { echo
$result_usraccount[''user_name'']; } ?>
</font></b><br /> <b><a href="<?php echo
"[#link_".$result_content["data_name"]."_".$result_content["numb"]."]";
?>"><?php echo $result_content["title"];
?></a></b><br /> <?php echo
$result_content["description"]; ?></p> <?php } // end while ?>
');
+
+
+-- --------------------------------------------------------
+
+--
+-- Tabellenstruktur für Tabelle `data_text_a`
--
CREATE TABLE `data_text_a` (
@@ -193,13 +342,14 @@
`text_name` varchar(100) collate utf8_unicode_ci NOT NULL,
`text_content` text collate utf8_unicode_ci NOT NULL,
PRIMARY KEY (`text_id`),
+ KEY `data_rev_id` (`data_rev_id`),
FULLTEXT KEY `text_content` (`text_content`)
-) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
-
--- --------------------------------------------------------
-
---
--- Tabellenstruktur für Tabelle `data_user_filter`
+) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
+
+-- --------------------------------------------------------
+
+--
+-- Tabellenstruktur für Tabelle `data_user_filter`
--
CREATE TABLE `data_user_filter` (
@@ -219,118 +369,25 @@
-- --------------------------------------------------------
--
--- Tabellenstruktur für Tabelle `dyn_content`
---
-
-CREATE TABLE `dyn_content` (
- `dyn_id` bigint(20) NOT NULL auto_increment,
- `dyn_content_id` bigint(20) NOT NULL default '0',
- `dyn_content_nr` int(11) NOT NULL default '0',
- `dyn_content_name` varchar(100) collate utf8_unicode_ci NOT NULL default '',
- `dyn_content_lang` varchar(10) collate utf8_unicode_ci NOT NULL default 'all',
- `dyn_content_text1` varchar(255) collate utf8_unicode_ci NOT NULL default '',
- `dyn_content_text2` varchar(255) collate utf8_unicode_ci NOT NULL default '',
- `dyn_content_text3` varchar(255) collate utf8_unicode_ci NOT NULL default '',
- `dyn_content_text4` longtext collate utf8_unicode_ci NOT NULL,
- `dyn_content_version` int(11) NOT NULL default '0',
- `dyn_content_active` tinyint(4) NOT NULL default '0',
- `dyn_content_visible` tinyint(4) NOT NULL default '0',
- `dyn_content_editor` varchar(10) collate utf8_unicode_ci NOT NULL default '',
- `dyn_content_usrname_id` bigint(20) NOT NULL default '0',
- `dyn_content_date` date NOT NULL default '0000-00-00',
- `dyn_content_time` time NOT NULL default '00:00:00',
- `dyn_altered` varchar(1) collate utf8_unicode_ci NOT NULL default '0',
- PRIMARY KEY (`dyn_id`)
-) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci
COMMENT='Contents';
-
--- --------------------------------------------------------
-
---
--- Tabellenstruktur für Tabelle `include_text`
---
-
-CREATE TABLE `include_text` (
- `inc_id` bigint(20) NOT NULL auto_increment,
- `inc_level` tinyint(4) NOT NULL default '0',
- `inc_word` varchar(255) collate utf8_unicode_ci NOT NULL default '',
- `inc_text` text collate utf8_unicode_ci NOT NULL,
- `inc_lang` varchar(10) collate utf8_unicode_ci NOT NULL default 'all',
- `inc_extra` varchar(20) collate utf8_unicode_ci NOT NULL default '',
- `inc_vis` tinyint(4) NOT NULL default '0',
- `inc_seclevel` tinyint(4) NOT NULL default '50',
- `inc_usrname_id` bigint(20) NOT NULL default '0',
- `inc_date` date NOT NULL default '0000-00-00',
- `inc_time` time NOT NULL default '00:00:00',
- `inc_altered` varchar(1) collate utf8_unicode_ci NOT NULL default '0',
- PRIMARY KEY (`inc_id`)
-) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci COMMENT='Replace words
with text phrases';
-
--- --------------------------------------------------------
-
---
--- Tabellenstruktur für Tabelle `languages`
+-- Tabellenstruktur für Tabelle `languages`
--
CREATE TABLE `languages` (
`lang_id` varchar(10) collate utf8_unicode_ci NOT NULL default '',
`lang_name` varchar(100) collate utf8_unicode_ci NOT NULL default '',
- `lang_level` int(11) NOT NULL default '0'
+ `lang_name_org` varchar(100) collate utf8_unicode_ci NOT NULL,
+ `lang_level` int(11) NOT NULL default '0',
+ PRIMARY KEY (`lang_id`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci COMMENT='available
languages';
--- --------------------------------------------------------
-
---
--- Tabellenstruktur für Tabelle `pages`
---
-
-CREATE TABLE `pages` (
- `page_id` bigint(20) NOT NULL auto_increment,
- `page_name` varchar(50) collate utf8_unicode_ci NOT NULL default '',
- `page_language` varchar(50) collate utf8_unicode_ci NOT NULL default '',
- `pages_extra` varchar(20) collate utf8_unicode_ci NOT NULL default '',
- `pages_extention` varchar(10) collate utf8_unicode_ci NOT NULL default
'default',
- `page_text` text collate utf8_unicode_ci NOT NULL,
- `page_version` int(11) NOT NULL default '0',
- `page_active` tinyint(4) NOT NULL default '0',
- `page_visible` tinyint(4) NOT NULL default '0',
- `page_usrname_id` bigint(20) NOT NULL default '0',
- `page_date` date NOT NULL default '0000-00-00',
- `page_time` time NOT NULL default '00:00:00',
- `page_generate_usrid` bigint(20) NOT NULL default '0',
- `page_generate_timestamp` varchar(50) collate utf8_unicode_ci NOT NULL default
'',
- `page_generate_force` char(1) collate utf8_unicode_ci NOT NULL default '0',
- `page_title` varchar(150) collate utf8_unicode_ci NOT NULL default '',
- `page_description` varchar(255) collate utf8_unicode_ci NOT NULL default '',
- PRIMARY KEY (`page_id`),
- KEY `page_generate_force` (`page_generate_force`)
-) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci COMMENT='Pages';
-
--- --------------------------------------------------------
-
---
--- Tabellenstruktur für Tabelle `roscms_security_log`
---
-
-CREATE TABLE `roscms_security_log` (
- `roscms_sec_log_id` bigint(20) NOT NULL auto_increment,
- `roscms_sec_log_section` varchar(100) collate utf8_unicode_ci NOT NULL default
'',
- `roscms_sec_log_priority` int(11) NOT NULL default '100',
- `roscms_sec_log_reason` varchar(255) collate utf8_unicode_ci NOT NULL default
'',
- `roscms_sec_log_user` varchar(100) collate utf8_unicode_ci NOT NULL default
'roscms_system',
- `roscms_sec_log_useraccount` varchar(100) collate utf8_unicode_ci NOT NULL default
'',
- `roscms_sec_log_userip` varchar(255) collate utf8_unicode_ci NOT NULL default
'',
- `roscms_sec_log_referrer` varchar(255) collate utf8_unicode_ci NOT NULL default
'',
- `roscms_sec_log_text` text collate utf8_unicode_ci NOT NULL,
- `roscms_sec_log_date` date NOT NULL default '0000-00-00',
- `roscms_sec_log_time` time NOT NULL default '00:00:00',
- `roscms_sec_log_visible` int(11) NOT NULL default '1',
- PRIMARY KEY (`roscms_sec_log_id`)
-) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci COMMENT='RosCMS
Security Log';
-
--- --------------------------------------------------------
-
---
--- Tabellenstruktur für Tabelle `subsys_mappings`
+INSERT INTO `languages` VALUES ('en', 'English', 'English', 10);
+INSERT INTO `languages` VALUES ('de', 'German', 'Deutsch', 8);
+
+
+-- --------------------------------------------------------
+
+--
+-- Tabellenstruktur für Tabelle `subsys_mappings`
--
CREATE TABLE `subsys_mappings` (
@@ -343,7 +400,7 @@
-- --------------------------------------------------------
--
--- Tabellenstruktur für Tabelle `user_sessions`
+-- Tabellenstruktur für Tabelle `user_sessions`
--
CREATE TABLE `user_sessions` (
@@ -359,7 +416,7 @@
-- --------------------------------------------------------
--
--- Tabellenstruktur für Tabelle `usergroup_members`
+-- Tabellenstruktur für Tabelle `usergroup_members`
--
CREATE TABLE `usergroup_members` (
@@ -370,23 +427,33 @@
-- --------------------------------------------------------
--
--- Tabellenstruktur für Tabelle `usergroups`
+-- Tabellenstruktur für Tabelle `usergroups`
--
CREATE TABLE `usergroups` (
`usrgroup_name_id` varchar(10) collate utf8_unicode_ci NOT NULL default '',
`usrgroup_name` varchar(100) collate utf8_unicode_ci NOT NULL default '',
`usrgroup_intern_id` varchar(25) collate utf8_unicode_ci NOT NULL default '',
+ `usrgroup_seclev` tinyint(4) NOT NULL default '0',
`usrgroup_securitylevel` tinyint(4) NOT NULL default '0',
`usrgroup_description` varchar(255) collate utf8_unicode_ci NOT NULL default
'',
PRIMARY KEY (`usrgroup_name_id`),
UNIQUE KEY `usrgroup_name` (`usrgroup_name`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
--- --------------------------------------------------------
-
---
--- Tabellenstruktur für Tabelle `users`
+INSERT INTO `usergroups` VALUES ('ros_admin', 'Administrator',
'roscms_usrgrp_admin', 3, 70, 'Administrator-Group');
+INSERT INTO `usergroups` VALUES ('user', 'User',
'roscms_usrgrp_user', 0, 0, 'Normal Visitors');
+INSERT INTO `usergroups` VALUES ('developer', 'Developer',
'roscms_usrgrp_dev', 2, 50, 'Developer');
+INSERT INTO `usergroups` VALUES ('moderator', 'Moderator',
'roscms_usrgrp_team', 2, 20, 'Website Moderators');
+INSERT INTO `usergroups` VALUES ('translator', 'Translator',
'roscms_usrgrp_trans', 1, 10, 'Translators');
+INSERT INTO `usergroups` VALUES ('ros_sadmin', 'Super-Administrator',
'roscms_usrgrp_sadmin', 3, 100, 'Super-Administrator-Group');
+INSERT INTO `usergroups` VALUES ('transmaint', 'Tranlation Maintainer',
'roscms_usrgrp_trans', 2, 15, 'Translation Maintainer');
+
+
+-- --------------------------------------------------------
+
+--
+-- Tabellenstruktur für Tabelle `users`
--
CREATE TABLE `users` (
@@ -416,3 +483,4 @@
UNIQUE KEY `user_name` (`user_name`),
UNIQUE KEY `user_email` (`user_email`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci COMMENT='RosCMS User
Table';
+