X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=index.php;h=55b12adc9384859c472b4135292ff12beec50415;hb=15170b516429341ae8e1a9ad2111be5ef90bf6aa;hp=b9576de8f989764ff7e9b57a5b1d0a32e972c77f;hpb=894a3c4bf38d8dcadb6941049b9167e5101805bd;p=github%2Fshaarli%2FShaarli.git diff --git a/index.php b/index.php index b9576de8..55b12adc 100644 --- a/index.php +++ b/index.php @@ -2,7 +2,7 @@ /** * Shaarli v0.7.0 - Shaare your links... * - * The personal, minimalist, super-fast, no-database Delicious clone. + * The personal, minimalist, super-fast, database free, bookmarking service. * * Friendly fork by the Shaarli community: * - https://github.com/shaarli/Shaarli @@ -1159,6 +1159,7 @@ function renderPage($conf, $pluginManager) $PAGE->assign('timezone_form', $timezone_form); $PAGE->assign('timezone_js',$timezone_js); $PAGE->assign('private_links_default', $conf->get('privacy.default_private_links', false)); + $PAGE->assign('session_protection_disabled', $conf->get('security.session_protection_disabled', false)); $PAGE->assign('enable_rss_permalinks', $conf->get('feed.rss_permalinks', false)); $PAGE->assign('enable_update_check', $conf->get('updates.check_updates', true)); $PAGE->assign('hide_public_links', $conf->get('privacy.hide_public_links', false)); @@ -1675,10 +1676,7 @@ function buildLinkList($PAGE,$LINKSDB, $conf, $pluginManager) $keys[] = $key; } - // If there is only a single link, we change on-the-fly the title of the page. - if (count($linksToDisplay) == 1) { - $conf->set('pagetitle', $linksToDisplay[$keys[0]]['title'] .' - '. $conf->get('general.title')); - } + // Select articles according to paging. $pagecount = ceil(count($keys) / $_SESSION['LINKS_PER_PAGE']); @@ -1740,9 +1738,10 @@ function buildLinkList($PAGE,$LINKSDB, $conf, $pluginManager) 'links' => $linkDisp, 'tags' => $LINKSDB->allTags(), ); - // FIXME! temporary fix - see #399. - if ($conf->exists('pagetitle') && count($linkDisp) == 1) { - $data['pagetitle'] = $conf->get('pagetitle'); + + // If there is only a single link, we change on-the-fly the title of the page. + if (count($linksToDisplay) == 1) { + $data['pagetitle'] = $linksToDisplay[$keys[0]]['title'] .' - '. $conf->get('general.title'); } $pluginManager->executeHooks('render_linklist', $data, array('loggedin' => isLoggedIn()));