From b2de3c32ee635788f2f34c98d529fdc167ca6a51 Mon Sep 17 00:00:00 2001 From: rvelices Date: Fri, 1 Dec 2006 01:46:32 +0000 Subject: - sessions are always started (even for visitors) - thumbnail order saved in the session instead of cookie git-svn-id: http://piwigo.org/svn/trunk@1623 68402e56-0260-453c-a942-63ccdbb3a9ee --- include/section_init.inc.php | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'include/section_init.inc.php') diff --git a/include/section_init.inc.php b/include/section_init.inc.php index 7e3f87cfe..416d98849 100644 --- a/include/section_init.inc.php +++ b/include/section_init.inc.php @@ -297,15 +297,13 @@ while (isset($tokens[$i])) // By default, it is the same as the $user['nb_image_page'] $page['nb_image_page'] = $user['nb_image_page']; -if (isset($_COOKIE['pwg_image_order']) - and is_numeric($_COOKIE['pwg_image_order']) - and $_COOKIE['pwg_image_order'] > 0) +if (pwg_get_session_var('image_order',0) > 0) { $orders = get_category_preferred_image_orders(); $conf['order_by'] = str_replace( 'ORDER BY ', - 'ORDER BY '.$orders[ $_COOKIE['pwg_image_order'] ][1].',', + 'ORDER BY '.$orders[ pwg_get_session_var('image_order',0) ][1].',', $conf['order_by'] ); $page['super_order_by'] = true; -- cgit v1.2.3