From d5a91de7b6f72460c8e5814f9dd33aa5dbc24259 Mon Sep 17 00:00:00 2001 From: Alex King Date: Tue, 12 Nov 2013 15:00:05 -0700 Subject: [PATCH] update changelog, fix copyright year output in admin --- CHANGELOG.txt | 9 +++++---- utility.php | 4 ++-- 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 6417946..c12dc2c 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -2,10 +2,11 @@ ## 3.7 -- Add support for "sticky" posts (sticky.php, single-sticky.php, feed-sticky.php) in the post context -- Set default context to archive instead of home -- Properly load type-* templates in General context -- Requires WordPress 3.6 (for get_post() returning global $post) +- (feature) Add support for "sticky" posts (sticky.php, single-sticky.php, feed-sticky.php) in the post context +- (change) Set default context to archive instead of home +- (change) Requires WordPress 3.6 (for get_post() returning global $post) +- (fix) Properly load type-* templates in General context +- (fix) Output %Y as expected in admin settings for copyright field ## 3.4 diff --git a/utility.php b/utility.php index 11acd2a..61c4d9f 100644 --- a/utility.php +++ b/utility.php @@ -59,7 +59,7 @@ function cfct_banner($str = '') { * @return mixed Value of the option * **/ -function cfct_get_option($name) { +function cfct_get_option($name, $admin = true) { $defaults = array( cfct_option_name('login_link_enabled') => 'yes', cfct_option_name('copyright') => sprintf(__('Copyright © %s  ·  %s', 'carrington'), date('Y'), get_bloginfo('name')), @@ -85,7 +85,7 @@ function cfct_get_option($name) { $value = $defaults[$basename]; } } - if ($name == cfct_option_name('copyright')) { + if (!$admin && $name == cfct_option_name('copyright')) { $value = str_replace('%Y', date('Y'), $value); }