Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Various fixes #833

Merged
merged 9 commits into from
Feb 4, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions .htaccess
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,7 @@ RewriteRule (.*) public/$1 [L]

# deny requests for config files
<FilesMatch ".(ini)$">
Order allow,deny
Deny from all
Require all denied
</FilesMatch>

# Disable ETags
Expand Down
4 changes: 2 additions & 2 deletions _docs/website/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -92,12 +92,12 @@ <h2>Requirements</h2>
<div class="documentation-entry">
<p>selfoss is not a hosted service. It has to be installed on your own webserver. This webserver must fulfill the following requirements (which are available from most providers)</p>
<ul>
<li>PHP 5.3 or higher with the php-gd extension enabled</li>
<li>PHP 5.3 or higher with the php-gd and php-http extensions enabled</li>
<li>MySQL 5.5.3 or higher, PostgreSQL, or Sqlite</li>
<li>Apache Webserver (ngnix and lighttpd also possible)</li>
</ul>

<p>Ensure that you have mod_rewrite and mod_headers enabled.</p>
<p>Ensure that you have mod_authz_core, mod_rewrite and mod_headers enabled.</p>

<p>selfoss supports all modern browsers, including Mozilla Firefox, Safari, Google Chrome, Opera and Internet Explorer. selfoss also supports mobile browsers on iPad, iPhone, Android and other devices.</p>
</div>
Expand Down
3 changes: 1 addition & 2 deletions controllers/Items.php
Original file line number Diff line number Diff line change
Expand Up @@ -158,9 +158,8 @@ public function stats() {
}

if( array_key_exists('tags', $_GET) && $_GET['tags'] == 'true' ) {
$tagsDao = new \daos\Tags();
$tagsController = new \controllers\Tags();
$stats['tagshtml'] = $tagsController->renderTags($tagsDao->getWithUnread());
$stats['tagshtml'] = $tagsController->renderTags($tags);
}
if( array_key_exists('sources', $_GET) && $_GET['sources'] == 'true' ) {
$sourcesDao = new \daos\Sources();
Expand Down
32 changes: 14 additions & 18 deletions daos/pgsql/Database.php
Original file line number Diff line number Diff line change
Expand Up @@ -169,12 +169,10 @@ public function __construct() {
');
}
if(strnatcmp($version, "5") < 0){
\F3::get('db')->exec('
ALTER TABLE items ADD author TEXT;
');
\F3::get('db')->exec('
INSERT INTO version (version) VALUES (5);
');
\F3::get('db')->exec(array(
'ALTER TABLE items ADD author TEXT;',
'INSERT INTO version (version) VALUES (5);'
));
}
if(strnatcmp($version, "6") < 0){
\F3::get('db')->exec(array(
Expand All @@ -186,19 +184,17 @@ public function __construct() {
// in /daos/sqlite/Database.php which
// set the database version to "7" for initial installs.
if(strnatcmp($version, "8") < 0){
\F3::get('db')->exec(array(
'ALTER TABLE sources ADD lastentry INT;',
'INSERT INTO version (version) VALUES (8);'
));
\F3::get('db')->exec(array(
'ALTER TABLE sources ADD lastentry INT;',
'INSERT INTO version (version) VALUES (8);'
));
}
if(strnatcmp($version, "9") < 0) {
\F3::get('db')->exec(array(
'ALTER TABLE items ADD shared BOOLEAN;',
'INSERT INTO version (version) VALUES (9);'
));
}
if(strnatcmp($version, "9") < 0) {
\F3::get('db')->exec('
ALTER TABLE items ADD shared BOOLEAN;
');
\F3::get('db')->exec('
INSERT INTO version (version) VALUES (9);
');
}
}

// just initialize once
Expand Down
3 changes: 1 addition & 2 deletions helpers/Authentication.php
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,7 @@ public function __construct() {
$cookie_path = '/'.$_SERVER['SERVER_NAME'].preg_replace('/\/[^\/]+$/','',$_SERVER['PHP_SELF']).'/';
$cookie_domain = $_SERVER['HTTP_X_FORWARDED_SERVER'];
} else {
// cookie path is script dir.
$cookie_path = dirname($_SERVER['REQUEST_URI'])==='/'?'/':dirname($_SERVER['REQUEST_URI']).'/';
$cookie_path = \F3::get('BASE').'/';
$cookie_domain = $_SERVER['SERVER_NAME'];
}
session_set_cookie_params($cookie_expire, $cookie_path, $cookie_domain,
Expand Down
3 changes: 2 additions & 1 deletion public/lang/fr.ini
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
lang_markread=Marquer lu
lang_filter=Filtres
lang_filter=Filtre
lang_newest=Récents
lang_unread=Non lus
lang_starred=Favoris
Expand Down Expand Up @@ -49,3 +49,4 @@ lang_login_username=Identifiant
lang_login_password=Mot de passe
lang_no_title=Sans titre
lang_error=Une erreur est survenue
lang_streamerror=Erreur lors du chargement de la liste, essayer à nouveau ?