forked from mirror/_s
_s: Resolve merge conflicts from master branch.
This also retains `$all_the_cool_cats` for some flavor. It has been around since the initial fork of Toolbox and makes people smile: https://twitter.com/TheFrosty/status/449581069231071232
This commit is contained in:
parent
87ca7b66ad
commit
7d24be9c97
|
@ -99,19 +99,23 @@ endif;
|
||||||
* Returns true if a blog has more than 1 category.
|
* Returns true if a blog has more than 1 category.
|
||||||
*/
|
*/
|
||||||
function _s_categorized_blog() {
|
function _s_categorized_blog() {
|
||||||
if ( false === ( $categories = get_transient( '_s_categories' ) ) ) {
|
if ( false === ( $all_the_cool_cats = get_transient( '_s_categories' ) ) ) {
|
||||||
// Create an array of all the categories that are attached to posts.
|
// Create an array of all the categories that are attached to posts.
|
||||||
$categories = get_categories( array(
|
$all_the_cool_cats = get_categories( array(
|
||||||
|
'fields' => 'ids',
|
||||||
'hide_empty' => 1,
|
'hide_empty' => 1,
|
||||||
|
|
||||||
|
// We only need to know if there is more than one category.
|
||||||
|
'number' => 2,
|
||||||
) );
|
) );
|
||||||
|
|
||||||
// Count the number of categories that are attached to the posts.
|
// Count the number of categories that are attached to the posts.
|
||||||
$categories = count( $categories );
|
$all_the_cool_cats = count( $all_the_cool_cats );
|
||||||
|
|
||||||
set_transient( '_s_categories', $categories );
|
set_transient( '_s_categories', $all_the_cool_cats );
|
||||||
}
|
}
|
||||||
|
|
||||||
if ( '1' != $categories ) {
|
if ( $all_the_cool_cats > 1 ) {
|
||||||
// This blog has more than 1 category so _s_categorized_blog should return true.
|
// This blog has more than 1 category so _s_categorized_blog should return true.
|
||||||
return true;
|
return true;
|
||||||
} else {
|
} else {
|
||||||
|
|
|
@ -1,14 +1,14 @@
|
||||||
# Copyright (C) 2013 Automattic
|
# Copyright (C) 2014 Automattic
|
||||||
# This file is distributed under the GNU General Public License v2 or later.
|
# This file is distributed under the GNU General Public License v2 or later.
|
||||||
msgid ""
|
msgid ""
|
||||||
msgstr ""
|
msgstr ""
|
||||||
"Project-Id-Version: _s 1.0-wpcom\n"
|
"Project-Id-Version: _s 1.0-wpcom\n"
|
||||||
"Report-Msgid-Bugs-To: http://wordpress.org/tags/_s\n"
|
"Report-Msgid-Bugs-To: http://wordpress.org/tags/_s\n"
|
||||||
"POT-Creation-Date: 2013-12-19 02:31:31+00:00\n"
|
"POT-Creation-Date: 2014-03-30 17:37:52+00:00\n"
|
||||||
"MIME-Version: 1.0\n"
|
"MIME-Version: 1.0\n"
|
||||||
"Content-Type: text/plain; charset=UTF-8\n"
|
"Content-Type: text/plain; charset=UTF-8\n"
|
||||||
"Content-Transfer-Encoding: 8bit\n"
|
"Content-Transfer-Encoding: 8bit\n"
|
||||||
"PO-Revision-Date: 2013-MO-DA HO:MI+ZONE\n"
|
"PO-Revision-Date: 2014-MO-DA HO:MI+ZONE\n"
|
||||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||||
|
|
||||||
|
@ -31,92 +31,92 @@ msgstr ""
|
||||||
msgid "Try looking in the monthly archives. %1$s"
|
msgid "Try looking in the monthly archives. %1$s"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: archive.php:31
|
#: archive.php:27
|
||||||
msgid "Author: %s"
|
msgid "Author: %s"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: archive.php:39
|
#: archive.php:30
|
||||||
msgid "Day: %s"
|
msgid "Day: %s"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: archive.php:42
|
#: archive.php:33
|
||||||
msgid "Month: %s"
|
msgid "Month: %s"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: archive.php:42
|
#: archive.php:33
|
||||||
msgctxt "monthly archives date format"
|
msgctxt "monthly archives date format"
|
||||||
msgid "F Y"
|
msgid "F Y"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: archive.php:45
|
#: archive.php:36
|
||||||
msgid "Year: %s"
|
msgid "Year: %s"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: archive.php:45
|
#: archive.php:36
|
||||||
msgctxt "yearly archives date format"
|
msgctxt "yearly archives date format"
|
||||||
msgid "Y"
|
msgid "Y"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: archive.php:48
|
#: archive.php:39
|
||||||
msgid "Asides"
|
msgid "Asides"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: archive.php:51
|
#: archive.php:42
|
||||||
msgid "Galleries"
|
msgid "Galleries"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: archive.php:54
|
#: archive.php:45
|
||||||
msgid "Images"
|
msgid "Images"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: archive.php:57
|
#: archive.php:48
|
||||||
msgid "Videos"
|
msgid "Videos"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: archive.php:60
|
#: archive.php:51
|
||||||
msgid "Quotes"
|
msgid "Quotes"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: archive.php:63
|
#: archive.php:54
|
||||||
msgid "Links"
|
msgid "Links"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: archive.php:66
|
#: archive.php:57
|
||||||
msgid "Statuses"
|
msgid "Statuses"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: archive.php:69
|
#: archive.php:60
|
||||||
msgid "Audios"
|
msgid "Audios"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: archive.php:72
|
#: archive.php:63
|
||||||
msgid "Chats"
|
msgid "Chats"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: archive.php:75 sidebar.php:17
|
#: archive.php:66 sidebar.php:16
|
||||||
msgid "Archives"
|
msgid "Archives"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: comments.php:30
|
#: comments.php:28
|
||||||
msgctxt "comments title"
|
msgctxt "comments title"
|
||||||
msgid "One thought on “%2$s”"
|
msgid "One thought on “%2$s”"
|
||||||
msgid_plural "%1$s thoughts on “%2$s”"
|
msgid_plural "%1$s thoughts on “%2$s”"
|
||||||
msgstr[0] ""
|
msgstr[0] ""
|
||||||
msgstr[1] ""
|
msgstr[1] ""
|
||||||
|
|
||||||
#: comments.php:37 comments.php:57
|
#: comments.php:35 comments.php:52
|
||||||
msgid "Comment navigation"
|
msgid "Comment navigation"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: comments.php:38 comments.php:58
|
#: comments.php:36 comments.php:53
|
||||||
msgid "← Older Comments"
|
msgid "← Older Comments"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: comments.php:39 comments.php:59
|
#: comments.php:37 comments.php:54
|
||||||
msgid "Newer Comments →"
|
msgid "Newer Comments →"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: comments.php:69
|
#: comments.php:64
|
||||||
msgid "Comments are closed."
|
msgid "Comments are closed."
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
|
@ -146,7 +146,6 @@ msgid "Pages:"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: content-page.php:23 content-single.php:60 content.php:61
|
#: content-page.php:23 content-single.php:60 content.php:61
|
||||||
#: inc/template-tags.php:81 inc/template-tags.php:100
|
|
||||||
msgid "Edit"
|
msgid "Edit"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
|
@ -201,11 +200,15 @@ msgstr ""
|
||||||
msgid "% Comments"
|
msgid "% Comments"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: footer.php:16
|
#: footer.php:15
|
||||||
|
msgid "http://wordpress.org/"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#: footer.php:15
|
||||||
msgid "Proudly powered by %s"
|
msgid "Proudly powered by %s"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: footer.php:18
|
#: footer.php:17
|
||||||
msgid "Theme: %1$s by %2$s."
|
msgid "Theme: %1$s by %2$s."
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
|
@ -213,7 +216,7 @@ msgstr ""
|
||||||
msgid "Primary Menu"
|
msgid "Primary Menu"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: functions.php:65
|
#: functions.php:73
|
||||||
msgid "Sidebar"
|
msgid "Sidebar"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
|
@ -255,24 +258,7 @@ msgctxt "Next post link"
|
||||||
msgid "%title <span class=\"meta-nav\">→</span>"
|
msgid "%title <span class=\"meta-nav\">→</span>"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: inc/template-tags.php:81
|
#: inc/template-tags.php:85
|
||||||
msgid "Pingback:"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#: inc/template-tags.php:91
|
|
||||||
msgid "%s <span class=\"says\">says:</span>"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#: inc/template-tags.php:97
|
|
||||||
msgctxt "1: date, 2: time"
|
|
||||||
msgid "%1$s at %2$s"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#: inc/template-tags.php:104
|
|
||||||
msgid "Your comment is awaiting moderation."
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#: inc/template-tags.php:145
|
|
||||||
msgid ""
|
msgid ""
|
||||||
"<span class=\"posted-on\">Posted on %1$s</span><span class=\"byline\"> by "
|
"<span class=\"posted-on\">Posted on %1$s</span><span class=\"byline\"> by "
|
||||||
"%2$s</span>"
|
"%2$s</span>"
|
||||||
|
@ -282,22 +268,7 @@ msgstr ""
|
||||||
msgid "Search Results for: %s"
|
msgid "Search Results for: %s"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
#: searchform.php:10
|
#: sidebar.php:23
|
||||||
msgctxt "label"
|
|
||||||
msgid "Search for:"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#: searchform.php:11
|
|
||||||
msgctxt "placeholder"
|
|
||||||
msgid "Search …"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#: searchform.php:13
|
|
||||||
msgctxt "submit button"
|
|
||||||
msgid "Search"
|
|
||||||
msgstr ""
|
|
||||||
|
|
||||||
#: sidebar.php:24
|
|
||||||
msgid "Meta"
|
msgid "Meta"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
|
|
||||||
|
|
Reference in New Issue