summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Dolgov <[email protected]>2007-05-04 04:15:58 +0100
committerAndrew Dolgov <[email protected]>2007-05-04 04:15:58 +0100
commit87b9fb65321ec077a5d062f571c8384136c0fdc4 (patch)
tree6f175179f69c199e724d2a25ce2a27d57a72fa4b
parentd3687e7a9e2c807d1113522a4e83682fe803c4f2 (diff)
add _PREFS_ACTIVE_TAB hidden option, tweak update.php, move SCHEMA_VERSION definition to sanity_check.php
-rw-r--r--backend.php2
-rw-r--r--sanity_check.php1
-rw-r--r--schema/ttrss_schema_mysql.sql4
-rw-r--r--schema/ttrss_schema_pgsql.sql4
-rw-r--r--update.php5
-rw-r--r--utility.css24
6 files changed, 33 insertions, 7 deletions
diff --git a/backend.php b/backend.php
index 1b318906e..a71b649e4 100644
--- a/backend.php
+++ b/backend.php
@@ -12,8 +12,6 @@
error_reporting(DEFAULT_ERROR_LEVEL); */
- define('SCHEMA_VERSION', 16);
-
require_once "sanity_check.php";
require_once "config.php";
diff --git a/sanity_check.php b/sanity_check.php
index 721c7140f..adb7ab878 100644
--- a/sanity_check.php
+++ b/sanity_check.php
@@ -2,6 +2,7 @@
require_once "functions.php";
define('EXPECTED_CONFIG_VERSION', 7);
+ define('SCHEMA_VERSION', 17);
if (!file_exists("config.php")) {
print __("<b>Fatal Error</b>: You forgot to copy
diff --git a/schema/ttrss_schema_mysql.sql b/schema/ttrss_schema_mysql.sql
index 92ab10302..c7e5677c6 100644
--- a/schema/ttrss_schema_mysql.sql
+++ b/schema/ttrss_schema_mysql.sql
@@ -189,7 +189,7 @@ create table ttrss_tags (id integer primary key auto_increment,
create table ttrss_version (schema_version int not null) TYPE=InnoDB;
-insert into ttrss_version values (16);
+insert into ttrss_version values (17);
create table ttrss_prefs_types (id integer not null primary key,
type_name varchar(100) not null) TYPE=InnoDB;
@@ -272,6 +272,8 @@ insert into ttrss_prefs (pref_name,type_id,def_value,short_desc,section_id) valu
insert into ttrss_prefs (pref_name,type_id,def_value,short_desc,section_id) values('_DEFAULT_VIEW_LIMIT', 3, '30', '', 1);
+insert into ttrss_prefs (pref_name,type_id,def_value,short_desc,section_id) values('_PREFS_ACTIVE_TAB', 3, '', '', 1);
+
create table ttrss_user_prefs (
owner_uid integer not null,
pref_name varchar(250),
diff --git a/schema/ttrss_schema_pgsql.sql b/schema/ttrss_schema_pgsql.sql
index 6e89455ab..35dc31e4f 100644
--- a/schema/ttrss_schema_pgsql.sql
+++ b/schema/ttrss_schema_pgsql.sql
@@ -173,7 +173,7 @@ create index ttrss_tags_owner_uid_index on ttrss_tags(owner_uid);
create table ttrss_version (schema_version int not null);
-insert into ttrss_version values (16);
+insert into ttrss_version values (17);
create table ttrss_prefs_types (id integer not null primary key,
type_name varchar(100) not null);
@@ -252,6 +252,8 @@ insert into ttrss_prefs (pref_name,type_id,def_value,short_desc,section_id) valu
insert into ttrss_prefs (pref_name,type_id,def_value,short_desc,section_id) values('_DEFAULT_VIEW_LIMIT', 3, '30', '', 1);
+insert into ttrss_prefs (pref_name,type_id,def_value,short_desc,section_id) values('_PREFS_ACTIVE_TAB', 3, '', '', 1);
+
create table ttrss_user_prefs (
owner_uid integer not null references ttrss_users(id) ON DELETE CASCADE,
pref_name varchar(250) not null references ttrss_prefs(pref_name) ON DELETE CASCADE,
diff --git a/update.php b/update.php
index 665ec9495..e3a25f47c 100644
--- a/update.php
+++ b/update.php
@@ -24,8 +24,7 @@
render_login_form($link);
exit;
}
-
- define('SCHEMA_VERSION', 16);
+
?>
@@ -94,7 +93,7 @@ function confirmOP() {
}
if (!$op) {
- print "<p class='warning'>".__("<b>Warning:</b> Please backup your database before proceeding.")."</p>";
+ print_warning("Please backup your database before proceeding.");
print "<p>" . T_sprintf("Your Tiny Tiny RSS database needs update to the latest version (<b>%d</b> to <b>%d</b>).", $version, $latest_version) . "</p>";
diff --git a/utility.css b/utility.css
index 9bdb77c21..f51182a7a 100644
--- a/utility.css
+++ b/utility.css
@@ -28,3 +28,27 @@ a:hover {
color : black;
}
+div.notice {
+ background : #ffffff;
+ border : 1px solid #88b0f0;
+ width : 50%;
+ padding : 5px;
+ margin : 0px 0px 5px 0px;
+ font-size : 9pt;
+}
+
+div.warning {
+ background : #fff7d5;
+ border : 1px solid #d7c47a;
+ font-size : 9pt;
+ width : 50%;
+ padding : 5px;
+ margin : 0px 0px 5px 0px;
+}
+
+
+div.warning img, div.notice img {
+ vertical-align : middle;
+ padding : 5px;
+}
+