diff options
author | plegall <plg@piwigo.org> | 2006-02-23 16:53:11 +0000 |
---|---|---|
committer | plegall <plg@piwigo.org> | 2006-02-23 16:53:11 +0000 |
commit | 9a7a232cef393a829e7e5088ceb5d145c2f942ed (patch) | |
tree | 685ec57e3114110a3bcf9db49258cb3aa75b7c98 /include/category_default.inc.php | |
parent | 347d2e34b3972ec1d0022b831dd5a1fe13adbaa5 (diff) |
modification: DAY() MySQL function replaced by DAYOFMONTH() to improve
backward compatibility (this function was added in MySQL 4.1)
bug fixed: with chronology mode, PWG displays thumbnails on main page if
even if no category (which will soon be called "section") is set. This was
producing warnings on category.php from include/category_default.inc.php.
refactoring: on include/calendar_base.class.php and
include/functions_calendar.inc.php. Unix file format, coding guidelines,
etc. While trying to understand the code, I've made some presentation
modification to clarify variable names and so on.
git-svn-id: http://piwigo.org/svn/trunk@1053 68402e56-0260-453c-a942-63ccdbb3a9ee
Diffstat (limited to 'include/category_default.inc.php')
-rw-r--r-- | include/category_default.inc.php | 29 |
1 files changed, 16 insertions, 13 deletions
diff --git a/include/category_default.inc.php b/include/category_default.inc.php index 558e3d389..5c31e4a18 100644 --- a/include/category_default.inc.php +++ b/include/category_default.inc.php @@ -79,22 +79,25 @@ foreach ($pictures as $row) { $thumbnail_title .= ' : '.$row['filesize'].' KB'; } + // url link on picture.php page - $url_link = PHPWG_ROOT_PATH.'picture.php?'; - if ( isset($page['cat']) ) - { - $url_link .= 'cat='.$page['cat'].'&'; - } - $url_link.= 'image_id='.$row['id']; - if ($page['cat'] == 'search') - { - $url_link.= '&search='.$_GET['search']; - } - else if ($page['cat'] == 'list') + $url_link = PHPWG_ROOT_PATH.'picture.php?image_id='.$row['id']; + + if (isset($page['cat'])) { - $url_link.= '&list='.$_GET['list']; + $url_link.= 'cat='.$page['cat'].'&'; + + if ($page['cat'] == 'search') + { + $url_link.= '&search='.$_GET['search']; + } + else if ($page['cat'] == 'list') + { + $url_link.= '&list='.$_GET['list']; + } } - if ( isset($_GET['calendar']) ) + + if (isset($_GET['calendar'])) { $url_link.= '&calendar='.$_GET['calendar']; } |