foreach ($ids as $id) {
db_query($link, "DELETE FROM ttrss_feeds WHERE id = '$id'");
- $icons_dir = get_pref($link, 'ICONS_DIR');
+ $icons_dir = ICONS_DIR;
if (file_exists($icons_dir . "/$id.ico")) {
unlink($icons_dir . "/$id.ico");
print "<tr class=\"$class\" id=\"FEEDR-$feed_id\">";
- $icon_file = get_pref($link, 'ICONS_DIR') . "/$feed_id.ico";
+ $icon_file = ICONS_DIR . "/$feed_id.ico";
if (file_exists($icon_file) && filesize($icon_file) > 0) {
$feed_icon = "<img width=\"16\" height=\"16\"
- src=\"" . get_pref($link, 'ICONS_URL') . "/$feed_id.ico\">";
+ src=\"" . ICONS_URL . "/$feed_id.ico\">";
} else {
$feed_icon = " ";
}
define(WEB_DEMO_MODE, false);
+ define(ICONS_DIR, "icons");
+ define(ICONS_URL, "icons");
define(USE_HTTP_AUTH, false);
// use HTTP Basic authentication
$feed_url = preg_replace("/\/.*$/", "", $feed_url);
$icon_url = "http://$feed_url/favicon.ico";
- $icon_file = get_pref($link, 'ICONS_DIR') . "/$feed.ico";
+ $icon_file = ICONS_DIR . "/$feed.ico";
if (!file_exists($icon_file)) {
feed_id integer not null,
updated datetime not null,
title text not null,
- guid varchar(255) not null unique,
+ guid varchar(255) not null,
link text not null,
content text not null,
content_hash varchar(250) not null,
foreign key (section_id) references ttrss_prefs_sections(id)) TYPE=InnoDB;
insert into ttrss_prefs (pref_name,type_id,def_value,short_desc,section_id) values('ENABLE_FEED_ICONS', 1, 'true', 'Enable icons in feedlist',2);
-insert into ttrss_prefs (pref_name,type_id,def_value,short_desc,section_id) values('ICONS_DIR', 2, 'icons', 'Local directory for feed icons',1);
-insert into ttrss_prefs (pref_name,type_id,def_value,short_desc,section_id) values('ICONS_URL', 2, 'icons', 'Local URL for icons',1);
insert into ttrss_prefs (pref_name,type_id,def_value,short_desc,section_id) values('PURGE_OLD_DAYS', 3, '60', 'Purge old posts after this number of days (0 - disables)',1);
insert into ttrss_prefs (pref_name,type_id,def_value,short_desc,section_id) values('UPDATE_POST_ON_CHECKSUM_CHANGE', 1, 'true', 'Update post on checksum change',1);
insert into ttrss_prefs (pref_name,type_id,def_value,short_desc,section_id) values('ENABLE_PREFS_CATCHUP_UNCATCHUP', 1, 'false', 'Enable catchup/uncatchup buttons in feed editor',2);
def_value text not null);
insert into ttrss_prefs (pref_name,type_id,def_value,short_desc,section_id) values('ENABLE_FEED_ICONS', 1, 'true', 'Enable icons in feedlist',2);
-insert into ttrss_prefs (pref_name,type_id,def_value,short_desc,section_id) values('ICONS_DIR', 2, 'icons', 'Local directory for feed icons',1);
-insert into ttrss_prefs (pref_name,type_id,def_value,short_desc,section_id) values('ICONS_URL', 2, 'icons', 'Local URL for icons',1);
insert into ttrss_prefs (pref_name,type_id,def_value,short_desc,section_id) values('PURGE_OLD_DAYS', 3, '60', 'Purge old posts after this number of days (0 - disables)',1);
insert into ttrss_prefs (pref_name,type_id,def_value,short_desc,section_id) values('UPDATE_POST_ON_CHECKSUM_CHANGE', 1, 'true', 'Update post on checksum change',1);
insert into ttrss_prefs (pref_name,type_id,def_value,short_desc,section_id) values('ENABLE_PREFS_CATCHUP_UNCATCHUP', 1, 'false', 'Enable catchup/uncatchup buttons in feed editor',2);