From 1c6fb0bb3dec575739de90304c69e5477ef929fe Mon Sep 17 00:00:00 2001 From: real_nowhereman Date: Mon, 14 Apr 2008 07:46:47 +0000 Subject: [PATCH] fixing some date/linking minor problems --- fp-includes/core/core.theme.php | 7 ++++--- fp-plugins/calendar/plugin.calendar.php | 6 ++++-- fp-plugins/prettyurls/plugin.prettyurls.php | 2 +- 3 files changed, 9 insertions(+), 6 deletions(-) diff --git a/fp-includes/core/core.theme.php b/fp-includes/core/core.theme.php index 8d47498..11b840f 100644 --- a/fp-includes/core/core.theme.php +++ b/fp-includes/core/core.theme.php @@ -489,12 +489,13 @@ function get_day_link($year, $month, $day) { return wp_specialchars( apply_filters( - 'month_link', - BLOG_BASEURL . '?y:'. str_pad($year, 2, '0', STR_PAD_LEFT) + 'day_link', + BLOG_BASEURL . '?x=y:'. str_pad($year, 2, '0', STR_PAD_LEFT) . ';m:' . str_pad($month, 2, '0', STR_PAD_LEFT) . ';d:' . str_pad($day, 2, '0', STR_PAD_LEFT), $year, - $month) + $month, + $day) ); } diff --git a/fp-plugins/calendar/plugin.calendar.php b/fp-plugins/calendar/plugin.calendar.php index 9b8778a..cddf429 100755 --- a/fp-plugins/calendar/plugin.calendar.php +++ b/fp-plugins/calendar/plugin.calendar.php @@ -63,9 +63,11 @@ function generate_calendar($year, $month, $days = array(), $day_name_length = 3, } function plugin_calendar_widget() { + + global $fp_params; - $y = isset($_GET['y'])? $_GET['y'] : date('y'); - $m = isset($_GET['m'])? $_GET['m'] : date('m'); + $y = isset($fp_params['y'])? $fp_params['y'] : date('y'); + $m = isset($fp_params['m'])? $fp_params['m'] : date('m'); global $fpdb; diff --git a/fp-plugins/prettyurls/plugin.prettyurls.php b/fp-plugins/prettyurls/plugin.prettyurls.php index d8bf36d..2e80efc 100644 --- a/fp-plugins/prettyurls/plugin.prettyurls.php +++ b/fp-plugins/prettyurls/plugin.prettyurls.php @@ -125,7 +125,7 @@ class Plugin_PrettyURLs { } function daylink($str, $y, $m, $d) { - return $this->daylink($str, $y, $m) . "$d/"; + return $this->monthlink($str, $y, $m) . "$d/"; }