From f558a62c7768f506d92e973ddf418aa157adac49 Mon Sep 17 00:00:00 2001 From: lucha <lucha@paranoici.org> Date: Wed, 19 Feb 2014 11:16:07 +0100 Subject: [PATCH] Carrington Blog 2.3.1 --- wp-content/themes/carrington-blog/README.txt | 133 +++ .../themes/carrington-blog/assets/load.php | 186 ---- .../carrington-blog/attachment/README.txt | 42 + .../attachment/attachment-default.php | 6 +- .../carrington-core/CHANGELOG.txt | 34 +- .../carrington-blog/carrington-core/admin.php | 511 ++++------ .../carrington-core/ajax-load.php | 81 +- .../carrington-core/attachment.php | 24 +- .../carrington-core/carrington.php | 60 +- .../carrington-core/compatibility.php | 208 ++++- .../carrington-core/css/colorpicker.css | 161 ++++ .../images/colorpicker/blank.gif | Bin 0 -> 49 bytes .../colorpicker/colorpicker_background.png | Bin 0 -> 1897 bytes .../images/colorpicker/colorpicker_hex.png | Bin 0 -> 532 bytes .../images/colorpicker/colorpicker_hsb_b.png | Bin 0 -> 970 bytes .../images/colorpicker/colorpicker_hsb_h.png | Bin 0 -> 1012 bytes .../images/colorpicker/colorpicker_hsb_s.png | Bin 0 -> 1171 bytes .../images/colorpicker/colorpicker_indic.gif | Bin 0 -> 86 bytes .../colorpicker/colorpicker_overlay.png | Bin 0 -> 10355 bytes .../images/colorpicker/colorpicker_rgb_b.png | Bin 0 -> 970 bytes .../images/colorpicker/colorpicker_rgb_g.png | Bin 0 -> 1069 bytes .../images/colorpicker/colorpicker_rgb_r.png | Bin 0 -> 1066 bytes .../images/colorpicker/colorpicker_select.gif | Bin 0 -> 78 bytes .../images/colorpicker/colorpicker_submit.png | Bin 0 -> 984 bytes .../images/colorpicker/custom_background.png | Bin 0 -> 1916 bytes .../images/colorpicker/custom_hex.png | Bin 0 -> 562 bytes .../images/colorpicker/custom_hsb_b.png | Bin 0 -> 1097 bytes .../images/colorpicker/custom_hsb_h.png | Bin 0 -> 970 bytes .../images/colorpicker/custom_hsb_s.png | Bin 0 -> 1168 bytes .../images/colorpicker/custom_indic.gif | Bin 0 -> 86 bytes .../images/colorpicker/custom_rgb_b.png | Bin 0 -> 1008 bytes .../images/colorpicker/custom_rgb_g.png | Bin 0 -> 1069 bytes .../images/colorpicker/custom_rgb_r.png | Bin 0 -> 1018 bytes .../images/colorpicker/custom_submit.png | Bin 0 -> 997 bytes .../images/colorpicker/select.png | Bin 0 -> 506 bytes .../images/colorpicker/select2.png | Bin 0 -> 518 bytes .../images/colorpicker/slider.png | Bin 0 -> 315 bytes .../carrington-core/js/colorpicker.js | 490 ++++++++++ .../carrington-core/lightbox/LICENSE.txt | 30 + .../carrington-core/lightbox/css/thickbox.css | 157 ++++ .../carrington-core/lightbox/img/blank.gif | Bin 0 -> 43 bytes .../lightbox/img/loadingAnimation.gif | Bin 0 -> 5886 bytes .../lightbox/img/macFFBgHack.png | Bin 0 -> 207 bytes .../carrington-core/lightbox/thickbox.js | 332 +++++++ .../carrington-core/templates.php | 136 +-- .../carrington-core/utility.php | 877 ++---------------- .../themes/carrington-blog/comment/README.txt | 38 + .../carrington-blog/comments/README.txt | 44 + .../comments/comments-default.php | 2 +- .../themes/carrington-blog/content/README.txt | 43 + .../content/content-default.php | 6 +- .../themes/carrington-blog/content/page.php | 6 +- .../themes/carrington-blog/css/README.txt | 8 + .../{assets => }/css/attachment-light.css | 0 .../{assets => }/css/attachment.css | 0 .../{assets => }/css/carrington-blog.css | 21 +- .../carrington-blog/{assets => }/css/css.php | 0 wp-content/themes/carrington-blog/css/ie.css | 45 + wp-content/themes/carrington-blog/css/ie6.css | 36 + .../themes/carrington-blog/css/iepngfix.htc | 187 ++++ wp-content/themes/carrington-blog/css/img.css | 147 +++ .../{assets => }/css/typography.css | 0 .../themes/carrington-blog/error/README.txt | 15 + .../themes/carrington-blog/excerpt/README.txt | 45 + .../excerpt/excerpt-default.php | 2 +- .../themes/carrington-blog/excerpt/search.php | 2 +- .../themes/carrington-blog/footer/README.txt | 42 + .../themes/carrington-blog/forms/README.txt | 18 + .../themes/carrington-blog/forms/comment.php | 98 ++ .../themes/carrington-blog/forms/search.php | 5 +- .../themes/carrington-blog/functions.php | 433 ++++----- .../carrington-blog/functions/README.txt | 5 + .../carrington-blog/functions/admin.php | 15 +- .../carrington-blog/functions/sidebars.php | 42 + .../themes/carrington-blog/header/README.txt | 42 + .../carrington-blog/header/header-default.php | 33 +- .../themes/carrington-blog/img/README.txt | 5 + .../{assets => }/img/arrow-bullet.gif | Bin .../attachment/150px-flourish-left-dark.png | Bin .../attachment/150px-flourish-left-light.png | Bin .../attachment/150px-flourish-right-dark.png | Bin .../attachment/150px-flourish-right-light.png | Bin .../{assets => }/img/author-comment.jpg | Bin .../{assets => }/img/comment-reply.gif | Bin .../{assets => }/img/comment-thread.gif | Bin .../{assets => }/img/comment.gif | Bin .../{assets => }/img/comments-divider.gif | Bin .../img/divider-ornament-wide-dark.png | Bin .../img/divider-ornament-wide.gif | Bin .../{assets => }/img/divider-ornament.gif | Bin .../{assets => }/img/dropdown-divider.gif | Bin .../img/footer/by-crowd-favorite-dark.png | Bin .../img/footer/by-crowd-favorite-light.png | Bin .../footer/divider-ornament-wide-light.png | Bin .../{assets => }/img/footer/gradient-dark.png | Bin .../img/footer/gradient-light.png | Bin .../img/grey-to-white-gradient.png | Bin .../{assets => }/img/header/gradient-dark.png | Bin .../img/header/gradient-light.png | Bin .../{assets => }/img/header/texture-dark.png | Bin .../{assets => }/img/header/texture-light.png | Bin .../{assets => }/img/lightbox/nextlabel.gif | Bin .../{assets => }/img/lightbox/prevlabel.gif | Bin .../{assets => }/img/ndash.gif | Bin .../{assets => }/img/rss-button.gif | Bin .../{assets => }/img/sidebar-background.gif | Bin .../{assets => }/img/spinner.gif | Bin .../img/sub-header-border-bottom.gif | Bin .../{assets => }/img/watermark-light.gif | Bin .../{assets => }/js/DD_belatedPNG.js | 0 .../themes/carrington-blog/js/README.txt | 5 + .../{assets => }/js/carrington.js | 0 .../{assets => }/js/iepngfix_tilebg.js | 346 +++---- .../themes/carrington-blog/loop/README.txt | 48 + .../themes/carrington-blog/misc/README.txt | 17 + .../themes/carrington-blog/pages/README.txt | 39 + .../themes/carrington-blog/plugins/README.txt | 9 + .../themes/carrington-blog/posts/README.txt | 50 + .../themes/carrington-blog/sidebar/README.txt | 42 + .../sidebar/sidebar-default.php | 2 +- .../themes/carrington-blog/single/README.txt | 44 + 121 files changed, 3300 insertions(+), 2155 deletions(-) create mode 100644 wp-content/themes/carrington-blog/README.txt delete mode 100644 wp-content/themes/carrington-blog/assets/load.php create mode 100644 wp-content/themes/carrington-blog/attachment/README.txt create mode 100644 wp-content/themes/carrington-blog/carrington-core/css/colorpicker.css create mode 100644 wp-content/themes/carrington-blog/carrington-core/images/colorpicker/blank.gif create mode 100644 wp-content/themes/carrington-blog/carrington-core/images/colorpicker/colorpicker_background.png create mode 100644 wp-content/themes/carrington-blog/carrington-core/images/colorpicker/colorpicker_hex.png create mode 100644 wp-content/themes/carrington-blog/carrington-core/images/colorpicker/colorpicker_hsb_b.png create mode 100644 wp-content/themes/carrington-blog/carrington-core/images/colorpicker/colorpicker_hsb_h.png create mode 100644 wp-content/themes/carrington-blog/carrington-core/images/colorpicker/colorpicker_hsb_s.png create mode 100644 wp-content/themes/carrington-blog/carrington-core/images/colorpicker/colorpicker_indic.gif create mode 100644 wp-content/themes/carrington-blog/carrington-core/images/colorpicker/colorpicker_overlay.png create mode 100644 wp-content/themes/carrington-blog/carrington-core/images/colorpicker/colorpicker_rgb_b.png create mode 100644 wp-content/themes/carrington-blog/carrington-core/images/colorpicker/colorpicker_rgb_g.png create mode 100644 wp-content/themes/carrington-blog/carrington-core/images/colorpicker/colorpicker_rgb_r.png create mode 100644 wp-content/themes/carrington-blog/carrington-core/images/colorpicker/colorpicker_select.gif create mode 100644 wp-content/themes/carrington-blog/carrington-core/images/colorpicker/colorpicker_submit.png create mode 100644 wp-content/themes/carrington-blog/carrington-core/images/colorpicker/custom_background.png create mode 100644 wp-content/themes/carrington-blog/carrington-core/images/colorpicker/custom_hex.png create mode 100644 wp-content/themes/carrington-blog/carrington-core/images/colorpicker/custom_hsb_b.png create mode 100644 wp-content/themes/carrington-blog/carrington-core/images/colorpicker/custom_hsb_h.png create mode 100644 wp-content/themes/carrington-blog/carrington-core/images/colorpicker/custom_hsb_s.png create mode 100644 wp-content/themes/carrington-blog/carrington-core/images/colorpicker/custom_indic.gif create mode 100644 wp-content/themes/carrington-blog/carrington-core/images/colorpicker/custom_rgb_b.png create mode 100644 wp-content/themes/carrington-blog/carrington-core/images/colorpicker/custom_rgb_g.png create mode 100644 wp-content/themes/carrington-blog/carrington-core/images/colorpicker/custom_rgb_r.png create mode 100644 wp-content/themes/carrington-blog/carrington-core/images/colorpicker/custom_submit.png create mode 100644 wp-content/themes/carrington-blog/carrington-core/images/colorpicker/select.png create mode 100644 wp-content/themes/carrington-blog/carrington-core/images/colorpicker/select2.png create mode 100644 wp-content/themes/carrington-blog/carrington-core/images/colorpicker/slider.png create mode 100644 wp-content/themes/carrington-blog/carrington-core/js/colorpicker.js create mode 100644 wp-content/themes/carrington-blog/carrington-core/lightbox/LICENSE.txt create mode 100644 wp-content/themes/carrington-blog/carrington-core/lightbox/css/thickbox.css create mode 100644 wp-content/themes/carrington-blog/carrington-core/lightbox/img/blank.gif create mode 100644 wp-content/themes/carrington-blog/carrington-core/lightbox/img/loadingAnimation.gif create mode 100644 wp-content/themes/carrington-blog/carrington-core/lightbox/img/macFFBgHack.png create mode 100644 wp-content/themes/carrington-blog/carrington-core/lightbox/thickbox.js create mode 100644 wp-content/themes/carrington-blog/comment/README.txt create mode 100644 wp-content/themes/carrington-blog/comments/README.txt create mode 100644 wp-content/themes/carrington-blog/content/README.txt create mode 100644 wp-content/themes/carrington-blog/css/README.txt rename wp-content/themes/carrington-blog/{assets => }/css/attachment-light.css (100%) rename wp-content/themes/carrington-blog/{assets => }/css/attachment.css (100%) rename wp-content/themes/carrington-blog/{assets => }/css/carrington-blog.css (97%) rename wp-content/themes/carrington-blog/{assets => }/css/css.php (100%) create mode 100644 wp-content/themes/carrington-blog/css/ie.css create mode 100644 wp-content/themes/carrington-blog/css/ie6.css create mode 100644 wp-content/themes/carrington-blog/css/iepngfix.htc create mode 100644 wp-content/themes/carrington-blog/css/img.css rename wp-content/themes/carrington-blog/{assets => }/css/typography.css (100%) create mode 100644 wp-content/themes/carrington-blog/error/README.txt create mode 100644 wp-content/themes/carrington-blog/excerpt/README.txt create mode 100644 wp-content/themes/carrington-blog/footer/README.txt create mode 100644 wp-content/themes/carrington-blog/forms/README.txt create mode 100644 wp-content/themes/carrington-blog/forms/comment.php create mode 100644 wp-content/themes/carrington-blog/functions/README.txt create mode 100644 wp-content/themes/carrington-blog/functions/sidebars.php create mode 100644 wp-content/themes/carrington-blog/header/README.txt create mode 100644 wp-content/themes/carrington-blog/img/README.txt rename wp-content/themes/carrington-blog/{assets => }/img/arrow-bullet.gif (100%) rename wp-content/themes/carrington-blog/{assets => }/img/attachment/150px-flourish-left-dark.png (100%) rename wp-content/themes/carrington-blog/{assets => }/img/attachment/150px-flourish-left-light.png (100%) rename wp-content/themes/carrington-blog/{assets => }/img/attachment/150px-flourish-right-dark.png (100%) rename wp-content/themes/carrington-blog/{assets => }/img/attachment/150px-flourish-right-light.png (100%) rename wp-content/themes/carrington-blog/{assets => }/img/author-comment.jpg (100%) rename wp-content/themes/carrington-blog/{assets => }/img/comment-reply.gif (100%) rename wp-content/themes/carrington-blog/{assets => }/img/comment-thread.gif (100%) rename wp-content/themes/carrington-blog/{assets => }/img/comment.gif (100%) rename wp-content/themes/carrington-blog/{assets => }/img/comments-divider.gif (100%) rename wp-content/themes/carrington-blog/{assets => }/img/divider-ornament-wide-dark.png (100%) rename wp-content/themes/carrington-blog/{assets => }/img/divider-ornament-wide.gif (100%) rename wp-content/themes/carrington-blog/{assets => }/img/divider-ornament.gif (100%) rename wp-content/themes/carrington-blog/{assets => }/img/dropdown-divider.gif (100%) rename wp-content/themes/carrington-blog/{assets => }/img/footer/by-crowd-favorite-dark.png (100%) rename wp-content/themes/carrington-blog/{assets => }/img/footer/by-crowd-favorite-light.png (100%) rename wp-content/themes/carrington-blog/{assets => }/img/footer/divider-ornament-wide-light.png (100%) rename wp-content/themes/carrington-blog/{assets => }/img/footer/gradient-dark.png (100%) rename wp-content/themes/carrington-blog/{assets => }/img/footer/gradient-light.png (100%) rename wp-content/themes/carrington-blog/{assets => }/img/grey-to-white-gradient.png (100%) rename wp-content/themes/carrington-blog/{assets => }/img/header/gradient-dark.png (100%) rename wp-content/themes/carrington-blog/{assets => }/img/header/gradient-light.png (100%) rename wp-content/themes/carrington-blog/{assets => }/img/header/texture-dark.png (100%) rename wp-content/themes/carrington-blog/{assets => }/img/header/texture-light.png (100%) rename wp-content/themes/carrington-blog/{assets => }/img/lightbox/nextlabel.gif (100%) rename wp-content/themes/carrington-blog/{assets => }/img/lightbox/prevlabel.gif (100%) rename wp-content/themes/carrington-blog/{assets => }/img/ndash.gif (100%) rename wp-content/themes/carrington-blog/{assets => }/img/rss-button.gif (100%) rename wp-content/themes/carrington-blog/{assets => }/img/sidebar-background.gif (100%) rename wp-content/themes/carrington-blog/{assets => }/img/spinner.gif (100%) rename wp-content/themes/carrington-blog/{assets => }/img/sub-header-border-bottom.gif (100%) rename wp-content/themes/carrington-blog/{assets => }/img/watermark-light.gif (100%) rename wp-content/themes/carrington-blog/{assets => }/js/DD_belatedPNG.js (100%) create mode 100644 wp-content/themes/carrington-blog/js/README.txt rename wp-content/themes/carrington-blog/{assets => }/js/carrington.js (100%) rename wp-content/themes/carrington-blog/{assets => }/js/iepngfix_tilebg.js (95%) mode change 100755 => 100644 create mode 100644 wp-content/themes/carrington-blog/loop/README.txt create mode 100644 wp-content/themes/carrington-blog/misc/README.txt create mode 100644 wp-content/themes/carrington-blog/pages/README.txt create mode 100644 wp-content/themes/carrington-blog/plugins/README.txt create mode 100644 wp-content/themes/carrington-blog/posts/README.txt create mode 100644 wp-content/themes/carrington-blog/sidebar/README.txt create mode 100644 wp-content/themes/carrington-blog/single/README.txt diff --git a/wp-content/themes/carrington-blog/README.txt b/wp-content/themes/carrington-blog/README.txt new file mode 100644 index 000000000..4b09ccd85 --- /dev/null +++ b/wp-content/themes/carrington-blog/README.txt @@ -0,0 +1,133 @@ +# Carrington CMS Theme Framework for WordPress +http://carringtontheme.com + +by Crowd Favorite +http://crowdfavorite.com + +Released under the GPL license +http://www.opensource.org/licenses/gpl-license.php + +--- + +## Online Developer Resources + +Please see the latest online developer resources for Carrington here: + +http://carringtontheme.com/developers/ + + +## What is Carrington? + +1. A collection of elegant, high-end WordPress themes for end-users. +2. A designer and developer friendly CMS theme framework for WordPress. +3. A set of best practices for theme organization. + + +## Basic Framework Concept + +Carrington is a CMS theme framework that virtually eliminates the need for custom conditional code in themes. Instead, template naming conventions along with the Carrington engine replace the need for this conditional code. + +Theme functionality is broken up into thoughtfully crafted abstractions to enable customizations at different levels (the loop, the post/page content, comments, etc.) and the Carrington engine chooses which template to be used for each segment of the theme. + +The abstractions and supported template types are designed to easily handle most of the customization scenarios we commonly see without the need to write custom code to use them. + + +## Context and Templates + +WordPress provides a number of functions to help you determine what type of view a theme is showing. These include: + +- `is_home()` +- `is_single()` +- `is_page()` +- `is_archive()` +- `in_category()` +- etc. + +Carrington abstracts these to deduce a "context" that is used when selecting a template. There are three context types used by the Carrington framework: + +1. Comment (dirs: comment) +2. Post (dirs: content, excerpt) +3. General (dirs: attachment, comments, footer, header, loop, posts, sidebar, single) + +Each directory implements one of these contexts for selecting the appropriate template to use. Templates are used in page views based on how they match the given context(s) for the overall page and the specific pieces of content being displayed. + +Read about the options available in each directory in the README file for that directory. + +Note: "default.php" is a supported default file name for all directories, however we have found in real world usage that {dirname}-default.php is a preferable naming system. When you have a half-dozen "default.php" files open in your favorite text editor, telling them apart in the file list can be more difficult than it should be. + + +## Theme Organization + +WordPress themes generally have a file structure similar to this: + +- 404.php +- archive.php +- archives.php +- [...] +- sidebar.php +- single.php +- style.css + +While this organization works well in many instances, it doesn't well support the concept of atomic elements that are combined to create a theme. For example, a representation of just a post's content, or just a comment, is not represented here. + +Carrington respects the supported WordPress file naming conventions (for example `get_header()` will still work), but eschews them in favor of an organizational structure that better suits the abstraction and customization commonly needed for a WordPress theme. + +Template files are layered into each other using the following basic approach: + +1. top level templates that include +2. common elements like a header, footer and sidebar along with a +3. loop that includes +4. atomic post/page content or excerpt templates and, where appropriate, a +5. comments area template that includes +6. atomic template for comments and a +7. template for the comment form + + +## Actions and Filters + +The Carrington core is a theme framework, not a parent/child theme system. It includes a core set of functions that enable the override template hierarchy. These functions include actions and filters where appropriate so that their functionality can be customized and overridden as needed. These actions and filters use the same hook and filter system used in the WordPress core. + + +### Filters + +- `cfct_context` - allows you to apply filters to the return value of the `cfct_context()` function; the function that checks to see what posts file, loop file, etc. to show. +- `cfct_filename` - filter the output of the `cfct_filename()` function. +- `cfct_general_match_order` - set the order in which general templates are chosen (make it check for a cat-general template ahead of a cat-news template, etc.). +- `cfct_choose_general_template` - filter the output of the `cfct_choose_general_template()` function (the selected general template). +- `cfct_single_match_order` - set the order in which single and content templates are chosen (make it check for author templates ahead of meta template, etc.). +- `cfct_choose_single_template` - filter the output of the `cfct_choose_single_template()` function (the selected single template). +- `cfct_choose_content_template` - filter the output of the `cfct_choose_content_template()` function (the selected content template). +- `cfct_comment_match_order` - set the order in which content templates are chosen (make it check for role templates ahead of user templates, etc.). +- `cfct_choose_comment_template` - filter the output of the `cfct_choose_comment_template()` function (the selected comment template). +- `cfct_meta_templates` - filter the return value of the `cfct_meta_templates()` function (change the list of files returned). +- `cfct_cat_templates` - filter the return value of the `cfct_cat_templates()` function (change the list of files returned). +- `cfct_tag_templates` - filter the return value of the `cfct_tag_templates()` function (change the list of files returned). +- `cfct_author_templates` - filter the return value of the `cfct_author_templates()` function (change the list of files returned). +- `cfct_role_templates` - filter the return value of the `cfct_role_templates()` function (change the list of files returned). +- `cfct_parent_templates` - filter the return value of the `cfct_role_templates()` function (change the list of files returned). +- `cfct_single_templates` - filter the return value of the `cfct_parent_templates()` function (change the list of files returned). +- `cfct_comment_templates` - filter the return value of the `cfct_single_templates()` function (change the list of files returned). +`cfct_post_gallery_columns` - set the number of columns to show in the gallery. +`gallery_style` - retained from the WP function code copied in and altered for gallery display. +`cfct_option_defaults` - allows you to set defaults (alter/add/etc.) for Carrington options. +`cfct_files_{path}` - allows you to define the available files for a path. + + +### Actions + +- `cfct_settings_form` - allows you to add your own fields to the Carrington Settings form (left for compatibility` - recommend using _top and _bottom as needed instead of this). +- `cfct_settings_form_top` - allows you to add your own fields at the top of the Carrington Settings form. +- `cfct_settings_form_bottom` - allows you to add your own fields at the bottom of the Carrington Settings form. +- `cfct_settings_form_after` - allows you to add your content after the Carrington Settings form. Useful if you want to add a second form to the page, or some other content. +- `cfct_update_settings` - allows you to take action when the Carrington settings are being saved (perhaps to also save fields you've added in the `cfct_settings_form` action). + + +## Plugins + +Any .php files in the *plugins/* directory will be automatically loaded by Carrington. This is a great way to bundle in custom functions or to hook into Carrington's actions or filters and be able to distribute everything as a single theme package. + +--- + +## Tips + +There is very minor extra processing associated with the file system and context checks that Carrington requires. This overhead is virtually unnoticeable, however the use of a caching plugin is recommended as a general best practice. diff --git a/wp-content/themes/carrington-blog/assets/load.php b/wp-content/themes/carrington-blog/assets/load.php deleted file mode 100644 index 2296d8d55..000000000 --- a/wp-content/themes/carrington-blog/assets/load.php +++ /dev/null @@ -1,186 +0,0 @@ -<?php -$url = trailingslashit(get_template_directory_uri()); -define('CFCT_ASSETS_URL', $url.'assets/'); - -wp_enqueue_style( - 'carrington', - CFCT_ASSETS_URL.'css/css.php', - array(), - CFCT_VER -); - -wp_enqueue_script('jquery'); - -wp_enqueue_script( - 'carrington', - CFCT_ASSETS_URL.'js/carrington.js', - array('jquery'), - CFCT_VER -); - -if (cfct_get_option('cfct_ajax_load') == 'yes') { - cfct_ajax_load(); -} -if (cfct_get_option('cfct_lightbox') != 'no') { - wp_enqueue_script( - 'cfct_thickbox', - $url.'carrington-core/lightbox/thickbox.js', - array('jquery'), - CFCT_VER - ); - - wp_enqueue_style( - 'cfct_thickbox', - $url.'carrington-core/lightbox/css/thickbox.css', - array(), - CFCT_VER - ); -} - -/* Additional stuff to put in wp_head */ - -function cfct_blog_head() { - cfct_get_option('cfct_ajax_load') == 'no' ? $ajax_load = 'false' : $ajax_load = 'true'; - - echo ' -<script type="text/javascript"> -var CFCT_URL = "'.home_url().'"; -var CFCT_AJAX_LOAD = '.$ajax_load.'; -</script> - '; - - if (cfct_get_option('cfct_lightbox') != 'no') { - echo ' -<script type="text/javascript"> -tb_pathToImage = "' . get_template_directory_uri() . '/carrington-core/lightbox/img/loadingAnimation.gif"; -jQuery(function($) { - $("a.thickbox").each(function() { - var url = $(this).attr("rel"); - var post_id = $(this).parents("div.post, div.page").attr("id"); - $(this).attr("href", url).attr("rel", post_id); - }); -}); -</script>'; - } -// preview - if (isset($_GET['cfct_action']) && $_GET['cfct_action'] == 'custom_color_preview' && current_user_can('manage_options')) { - cfct_blog_custom_colors('preview'); - } - else if (cfct_get_option('cfct_custom_colors') == 'yes') { - cfct_blog_custom_colors(); - } - if (cfct_get_option('cfct_custom_header_image') == 'yes') { - $header_image = cfct_get_option('cfct_header_image'); - if ($header_image != 0 && $img = wp_get_attachment_image_src($header_image, 'large')) { -?> -<style type="text/css"> -#header .wrapper { - background-image: url(<?php echo $img[0]; ?>); - background-repeat: no-repeat; - min-height: <?php echo $img[2]; ?>px; -} -</style> -<?php - } - else { -?> -<style type="text/css"> -#header .wrapper { - background-image: url(); -} -</style> -<?php - } - } -} -add_action('wp_head', 'cfct_blog_head'); - -function cfct_blog_custom_colors($type = 'option') { - $colors = cfct_get_custom_colors($type); - if (get_option('cfct_header_image_type') == 'light') { - $header_img_type = 'light'; - $header_grad_type = 'dark'; - } - else { - $header_img_type = 'dark'; - $header_grad_type = 'light'; - } - get_option('cfct_footer_image_type') == 'light' ? $footer_img_type = 'light' : $footer_img_type = 'dark'; -?> -<style type="text/css"> -#header { - background-color: #<?php echo $colors['cfct_header_background_color']; ?>; - color: #<?php echo $colors['cfct_header_text_color']; ?>; -} -#header a, -#header a:visited { - color: #<?php echo $colors['cfct_header_link_color']; ?>; -} -#sub-header, -.nav ul{ - background-color: #<?php echo $colors['cfct_header_nav_background_color']; ?>; - color: #<?php echo $colors['cfct_header_nav_text_color']; ?>; -} -#sub-header a, -#sub-header a:visited, -.nav li li a, -.nav li li a:visited { - color: #<?php echo $colors['cfct_header_nav_link_color']; ?> !important; -} -h1, -h1 a, -h1 a:hover, -h1 a:visited { - color: #<?php echo $colors['cfct_page_title_color']; ?>; -} -h2, -h2 a, -h2 a:hover, -h2 a:visited { - color: #<?php echo $colors['cfct_page_subtitle_color']; ?>; -} -a, -a:hover, -a:visited { - color: #<?php echo $colors['cfct_link_color']; ?>; -} -.hentry .edit, -.hentry .edit a, -.hentry .edit a:visited, -.hentry .edit a:hover, -.comment-reply-link, -.comment-reply-link:visited, -.comment-reply-link:hover { - background-color: #<?php echo $colors['cfct_link_color']; ?>; -} -#footer { - background-color: #<?php echo $colors['cfct_footer_background_color']; ?>; - color: #<?php echo $colors['cfct_footer_text_color']; ?>; -} -#footer a, -#footer a:visited { - color: #<?php echo $colors['cfct_footer_link_color']; ?>; -} -#footer p#developer-link a, -#footer p#developer-link a:visited { - background-image: url(<?php echo CFCT_ASSETS_URL; ?>img/footer/by-crowd-favorite-<?php echo $footer_img_type; ?>.png); -} -<?php - if (cfct_get_option('cfct_css_background_images') != 'no') { -?> -#header { - background-image: url(<?php echo CFCT_ASSETS_URL; ?>img/header/gradient-<?php echo $header_grad_type; ?>.png); -} -#header .wrapper { - background-image: url(<?php echo CFCT_ASSETS_URL; ?>img/header/texture-<?php echo $header_img_type; ?>.png); -} -#footer { - background-image: url(<?php echo CFCT_ASSETS_URL; ?>img/footer/gradient-<?php echo $footer_img_type; ?>.png); -} -<?php - } -?> -</style> -<?php -} -?> \ No newline at end of file diff --git a/wp-content/themes/carrington-blog/attachment/README.txt b/wp-content/themes/carrington-blog/attachment/README.txt new file mode 100644 index 000000000..588aeecaa --- /dev/null +++ b/wp-content/themes/carrington-blog/attachment/README.txt @@ -0,0 +1,42 @@ +## image/ + +This directory holds templates for images/attachments. + + +## General Context + +When choosing a template to use in the General Context, the Carrington engine looks at the type of request is being fulfilled. It will identify the request as the home page, a category archive, and individual post, etc. + +There is additional checking done for single post requests. All options in the Content Context are supported here with a 'single-' prefix added to the file. See specifics below. + +A "default" template is required, and will be used when there are no other templates that match a given comment. This could be because no other templates have been created, or because the comment in question doesn't match the templates that are available. + +By default, conditions are checked in this order: + +1. author +2. role +3. category +4. tag +5. single +6. default (home, search, archive, 404, etc.) + +This can be altered using the `cfct_general_match_order` hook. + + +### Supported Templates (General Context) + +- *{dirname}-default.php* (or default.php) - Used when there are no other templates that match for a given page/post. +- *archive.php* - Used for date archives or if there are no specific category, author or tag templates. +- *author.php* - Used for author archive lists. +- *author-{username}.php* - Used when the post/page is authored by a specific user. For example, a template with a file name of _author-jsmith.php_ would be used for a post/page by user _jsmith_. Any WordPress username can take the place of {username} in the file name. +- *role-{rolename}.php - Used when the post author has a particular role. This might be the role of _contributor_, _author_, _editor_, etc. and use a file of _role-contributor.php_, _role_author.php_, etc. where the role name takes the place of the {rolename} in the file name. +- *category.php* - Used for category archive lists. +- *cat-{slug}.php* - Used fr displaying a given category. The category is matched by the "slug" - for example a post in category "General" (with a category slug of "general") could use a template of _cat-general.php_. +- *home.php* - Used when on the home page. +- *page.php* - Used for pages that do not match any other contextual templates. +- *search.php* - Used when displaying search results. +- *single.php* - Used for single post pages. +- *single-{content context filenames}.php* - Used for single post pages. +- *tag.php* - Used for tag archive lists. +- *tag-{slug}.php* - Used for displaying a given tag. The tag is matched by the "slug" - for example a post in tag "News" (with a tag slug of "news") could use a template of _tag-news.php_. + diff --git a/wp-content/themes/carrington-blog/attachment/attachment-default.php b/wp-content/themes/carrington-blog/attachment/attachment-default.php index c90571957..edcb054f4 100644 --- a/wp-content/themes/carrington-blog/attachment/attachment-default.php +++ b/wp-content/themes/carrington-blog/attachment/attachment-default.php @@ -28,13 +28,13 @@ global $post; <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" <?php language_attributes(); ?>> <head profile="http://gmpg.org/xfn/11"> - <title><?php wp_title( '-', true, 'right' ); echo esc_html( get_bloginfo('name') ); ?></title> + <title><?php wp_title( '-', true, 'right' ); echo wp_specialchars( get_bloginfo('name'), 1 ); ?></title> <meta http-equiv="content-type" content="<?php bloginfo('html_type'); ?>; charset=<?php bloginfo('charset'); ?>" /> <link href="<?php bloginfo('url') ?>" rel="home" /> - <link rel="alternate" type="application/rss+xml" href="<?php bloginfo('rss2_url') ?>" title="<?php esc_attr(printf( __( '%s latest posts', 'carrington' ), get_bloginfo('name')) ) ?>" /> - <link rel="alternate" type="application/rss+xml" href="<?php bloginfo('comments_rss2_url') ?>" title="<?php esc_attr(printf( __( '%s latest comments', 'carrington' ), get_bloginfo('name')) ) ?>" /> + <link rel="alternate" type="application/rss+xml" href="<?php bloginfo('rss2_url') ?>" title="<?php printf( __( '%s latest posts', 'carrington' ), wp_specialchars( get_bloginfo('name'), 1 ) ) ?>" /> + <link rel="alternate" type="application/rss+xml" href="<?php bloginfo('comments_rss2_url') ?>" title="<?php printf( __( '%s latest comments', 'carrington' ), wp_specialchars( get_bloginfo('name'), 1 ) ) ?>" /> <link rel="pingback" href="<?php bloginfo('pingback_url') ?>" /> <?php wp_get_archives('type=monthly&format=link'); ?> diff --git a/wp-content/themes/carrington-blog/carrington-core/CHANGELOG.txt b/wp-content/themes/carrington-blog/carrington-core/CHANGELOG.txt index a4a8947ac..2d059f448 100644 --- a/wp-content/themes/carrington-blog/carrington-core/CHANGELOG.txt +++ b/wp-content/themes/carrington-blog/carrington-core/CHANGELOG.txt @@ -1,36 +1,4 @@ -# Carrington Core Changelog - -## 3.4 - -- Remove Thickbox code (if your theme needs this, please include it in the theme). -- Remove color picker code (if your theme needs this, please include it in the theme). -- Remove archive/category posts per page default override (can be re-enabled by theme). -- Bring in expected globals in templates. Can be disabled via filter (`cfct_template_file_globals`) if desired. - -## 3.3.1 - -- Update header code option name to match that used in wp_head filter - -## 3.3 - -- Implemented support for feed-{post context} templates in content/ and excerpt/ dirs -- Refactor options display -- Add utility function to return template instead of echoing -- Converted Carrington Settings pages to utilize the WordPress Settings API -- Remove compatibility functions, no longer supporting versions of WordPress that old -- Misc. changes to support new WP APIs and best practices - -## 3.1 - -- Updated some variable names -- Support for custom taxonomies within the general context -- Implemented checked and selected functions for options -- E_NOTICE clean -- Added PHP doc blocks -- Support for post formats in the single context -- Added support for custom post type archive pages in general context -- Relies on features in WordPress 3.1 - +# Carrington Core Framework Changelog ## 3.0.1 diff --git a/wp-content/themes/carrington-blog/carrington-core/admin.php b/wp-content/themes/carrington-blog/carrington-core/admin.php index 5eb683f51..4b8f75e6c 100644 --- a/wp-content/themes/carrington-blog/carrington-core/admin.php +++ b/wp-content/themes/carrington-blog/carrington-core/admin.php @@ -1,9 +1,9 @@ <?php -// This file is part of the Carrington Core Platform for WordPress -// http://crowdfavorite.com/wordpress/carrington-core/ +// This file is part of the Carrington Theme Framework for WordPress +// http://carringtontheme.com // -// Copyright (c) 2008-2012 Crowd Favorite, Ltd. All rights reserved. +// Copyright (c) 2008-2010 Crowd Favorite, Ltd. All rights reserved. // http://crowdfavorite.com // // Released under the GPL license @@ -19,313 +19,77 @@ if (__FILE__ == $_SERVER['SCRIPT_FILENAME']) { die(); } // - add admin page for config settings -function cfct_option_css() { - -} - -/** - * Add a menu option under the admin themes menu - * -**/ function cfct_admin_menu() { - add_theme_page( + if (!current_user_can('manage_options')) { + return; + } + add_submenu_page( + 'themes.php', apply_filters('cfct_admin_settings_title', __('Carrington Theme Settings', 'carrington')), apply_filters('cfct_admin_settings_menu', __('Theme Settings', 'carrington')), - 'edit_theme_options', + 0, 'carrington-settings', 'cfct_settings_form' ); } add_action('admin_menu', 'cfct_admin_menu'); -/** - * Add a menu option under the admin admin bar - * -**/ -function cfct_admin_bar() { - global $wp_admin_bar; - if (current_user_can('edit_theme_options')) { - $wp_admin_bar->add_menu(array( - 'id' => 'theme-settings', - 'title' => apply_filters('cfct_admin_settings_menu', __('Theme Settings', 'carrington')), - 'href' => admin_url('themes.php?page=carrington-settings'), - 'parent' => 'appearance' - )); - } -} -add_action('wp_before_admin_bar_render', 'cfct_admin_bar'); - -/** - * Deprecated in favor of WP Core Settings API -**/ function cfct_admin_request_handler() { - _deprecated_function(__FUNCTION__, '3.2'); -} - -/** - * Deprecated in favor of WP Core Settings API -**/ -function cfct_update_settings() { - _deprecated_function(__FUNCTION__, '3.2'); -} - -/** - * Register Theme Settings screen options using WP Settings API - */ -function cfct_register_options() { - global $cfct_hidden_fields; - $yn_options = array( - 'yes' => __('Yes', 'carrington'), - 'no' => __('No', 'carrington') - ); - $cfct_options = array( - 'cfct' => array( - 'label' => '', - //This is a callback, use cfct_options_blank to display nothing - 'description' => 'cfct_options_blank', - 'fields' => array( - 'about' => array( - 'type' => 'textarea', - 'label' => __('About text (shown in sidebar)', 'carrington'), - 'cols' => 60, - 'rows' => 5, - 'name' => 'about_text', - ), - 'header' => array( - 'type' => 'textarea', - 'label' => __('Header code (analytics, etc.)', 'carrington'), - 'name' => 'wp_head', - ), - 'footer' => array( - 'type' => 'textarea', - 'label' => __('Footer code (analytics, etc.)', 'carrington'), - 'name' => 'wp_footer', - ), - 'copyright' => array( - 'type' => 'text', - 'label' => __('Copyright / legal footer text', 'carrington'), - 'name' => 'copyright', - 'help' => '<br /><span class="cfct-help">'.__('(add %Y to output the current year)', 'carrington').'</span>', - 'class' => 'cfct-text-long', - ), - 'login' => array( - 'type' => 'radio', - 'label' => __('Show log in/out links in footer', 'carrington'), - 'name' => 'login_link_enabled', - 'options' => $yn_options, - ), - 'credit' => array( - 'type' => 'radio', - 'label' => __('Give credit in footer', 'carrington'), - 'name' => 'credit', - 'options' => $yn_options, - ), - /** - 'radio' => array( - 'type' => 'radio', - 'label' => __('Radio Buttons', 'carrington'), - 'name' => 'radio_test', - 'options' => array( - 'value_one' => 'Radio Bar', - 'value_two' => 'Radio Bar 2', - ), - ), - 'checkbox' => array( - 'type' => 'checkbox', - 'label' => __('Checkboxes', 'carrington'), - 'name' => 'checkbox_test', - 'options' => array( - 'value_one' => 'Check Bar', - 'value_two' => 'Check Bar 2', - ), - ), - */ - ), - ), - ); - $cfct_options = apply_filters('cfct_options', $cfct_options); - - foreach ($cfct_options as $section_name => $section) { - if (empty($section['description'])) { - $section['description'] = 'cfct_options_blank'; - } - add_settings_section($section_name, $section['label'], $section['description'], 'cfct'); - - foreach ($section['fields'] as $key => $option) { - - // Prefix the option name - $option['name'] = cfct_option_name($option['name']); - - // Support for serialized options - // First we want to match on the name of the option. (everything up to the first []). Only matchs on alpha-numeric, dashes and underscores - if (preg_match('/^([a-zA-Z0-9-_]+)\[[a-zA-Z0-9-_]+\]/', $option['name'], $basename_match)) { - $basename = $basename_match[1]; - register_setting('cfct', $basename, 'cfct_sanitize_options'); - $serialize_option = cfct_get_option($basename); - - // match on any subsequent [] with at least one character to determine the value of the option. Only matchs on alpha-numeric, dashes and underscores. - if (preg_match_all('/\[([a-zA-Z0-9-_]+)\]/', $option['name'], $key_matches)) { - $value = $serialize_option; - foreach ($key_matches[1] as $key_match) { - if (is_array($value) && array_key_exists($key_match, $value)) { - $value = $value[$key_match]; - } - } - $option['value'] = $value; - } - } - else { - register_setting('cfct', $option['name'], 'cfct_sanitize_options'); - $option['value'] = cfct_get_option($option['name']); - } - - $option['label_for'] = $section_name.'_'.$key; - if ($option['type'] != 'hidden') { - add_settings_field($key, $option['label'], 'cfct_options_input', 'cfct', $section_name, $option); - } - else { - $cfct_hidden_fields[] = $option; - } + if (isset($_POST['cf_action'])) { + switch ($_POST['cf_action']) { + case 'cfct_update_settings': + call_user_func($_POST['cf_action']); + wp_redirect(trailingslashit(get_bloginfo('wpurl')).'wp-admin/themes.php?page=carrington-settings&updated=true'); } } - } -add_action('admin_init', 'cfct_register_options', 10); -/** - * Display hidden fields registered in `cfct_register_options()`. WP Forces padding when using `do_settings_sections`, so it cannot be truly hidden using that method. - */ -function cfct_hidden_fields() { - global $cfct_hidden_fields; - if (is_array($cfct_hidden_fields)) { - foreach ($cfct_hidden_fields as $field_options) { - echo cfct_options_input($field_options); - } +function cfct_update_settings() { + if (!current_user_can('manage_options')) { + return; } -} -add_action('cfct_settings_form', 'cfct_hidden_fields', 10); - -/** - * Empty callback, callback required by WP core function add_settings_section - */ -function cfct_options_blank() { - -} - -/** - * Prints an input field based on arguments passed. - * @param array $args Array of arguments used to generate the markup. - * 'type' => Type of input - * 'value' => Value of input - * 'name' => Name of input sent in post - * 'label_for' => ID attached to the input. Also used when generating the label in `add_settings_field` - * 'class' => CSS classes for the input - * 'cols' => Textarea specific - * 'rows' => Textarea specific - * 'options' => Radio button, Checkbox, Select specific. Used to define options - * 'help' => Help markup for the option. - * @return void - */ -function cfct_options_input($args) { - $type = $args['type']; - $value = $args['value']; - $name = $args['name']; - $id = empty($args['label_for']) ? $args['name'] : $args['label_for']; - $class = empty($args['class']) ? '' : ' class="'.esc_attr($args['class']).'"'; - $html = ''; + check_admin_referer('cfct_admin_settings'); - switch ($type) { - case 'text': - $html .= '<input id="'.esc_attr($id).'" name="'.esc_attr($name).'" type="text" value="'.esc_attr($value).'"'.$class.' />'; - break; - case 'password': - $html .= '<input id="'.esc_attr($id).'" name="'.esc_attr($name).'" type="password" value="'.esc_attr($value).'"'.$class.' />'; - break; - case 'textarea': - empty($args['cols']) ? $cols = 60 : $cols = (int) $args['cols']; - empty($args['rows']) ? $rows = 5 : $rows = (int) $args['rows']; - $html .= '<textarea id="'.esc_attr($id).'" name="'.esc_attr($name).'" cols="'.$cols.'" rows="'.$rows.'"'.$class.'>'.esc_textarea($value).'</textarea>'; - break; - case 'select': - $html .= '<select id="'.esc_attr($id).'" name="'.esc_attr($name).'"'.$class.'>'; - $options = $args['options']; - foreach ($options as $opt_value => $opt_label) { - $html .= '<option value="'.esc_attr($opt_value).'"'.selected($opt_value, $value, false).'>'.esc_html($opt_label).'</option>'; - } - $html .= '</select>'; - break; - case 'radio': - $options = $args['options']; - if (is_array($options)) { - $html .= '<ul>'; - foreach ($options as $opt_value => $opt_label) { - $html .= ' - <li> - <label for="'.esc_attr($name.'-'.$opt_value).'"> - <input type="radio" name="'.esc_attr($name).'" value="'.esc_attr($opt_value).'" id="'.esc_attr($name.'-'.$opt_value).'"'.checked($opt_value, $value, false).' /> - '.esc_html($opt_label).' - </label> - </li>'; - } - $html .= '</ul>'; - } - break; - case 'checkbox': - $options = $args['options']; - if (is_array($options)) { - $html .= '<ul>'; - foreach ($options as $opt_value => $opt_label) { - $html .= ' - <li> - <label for="'.esc_attr($name.'-'.$opt_value).'"> - <input type="checkbox" name="'.esc_attr($name.'['.$opt_value.']').'" value="'.esc_attr($opt_value).'" id="'.esc_attr($name.'-'.$opt_value).'"'.checked($opt_value, $value[$opt['id']], false).' /> - '.esc_html($opt_label).' - </label> - </li>'; - } - $html .= '</ul>'; - } - break; - case 'hidden': - $html .= '<input id="'.esc_attr($id).'" type="hidden" name="'.esc_attr($name).'" value="'.esc_attr($value).'" class="'.esc_attr($class).'" />'; - break; - default: - $html .= apply_filters('cfct_option_'.$type, $html, $args); - break; - } - if (!empty($args['help'])) { - $html .= $args['help']; + global $cfct_options; + foreach ($cfct_options as $option) { + if (isset($_POST[$option])) { + update_option($option, stripslashes($_POST[$option])); + } } - - print($html); -} -/** - * Sanitizes options - * @todo Better handling coming in WP 3.3, targetable option names. For now, add a filter to 'sanitize_option_{$option_name}' for additional processing - */ -function cfct_sanitize_options($new_value) { - return stripslashes_deep($new_value); + do_action('cfct_update_settings'); } -/** - * Display a settings for for Carrington Framework - * -**/ function cfct_settings_form() { - settings_errors(); + if (isset($_GET['updated'])) { + print(' +<div id="message" class="updated fade"> + <p>'.__('Settings updated.', 'carrington').'</p> +</div> + '); + } print(' <div class="wrap"> - '.get_screen_icon().'<h2>'.apply_filters('cfct_admin_settings_form_title', __('Carrington Theme Settings', 'carrington')).'</h2> - <form action="'.admin_url('options.php').'" method="post"> + <h2>'.apply_filters('cfct_admin_settings_form_title', __('Carrington Theme Settings', 'carrington')).'</h2> + <form action="options.php" method="post"> '); do_action('cfct_settings_form_top'); - do_settings_sections('cfct'); + print(' + <table class="form-table"> + <tbody>' +// .cfct_options_home_column('1') +// .cfct_options_home_column('2') +// .cfct_options_home_column('3') + .cfct_options_misc() + .'</tbody> + </table> + '); do_action('cfct_settings_form_bottom'); do_action('cfct_settings_form'); - settings_fields('cfct'); print(' <p class="submit" style="padding-left: 230px;"> - <input type="submit" name="submit_button" class="button-primary" value="'.__('Save', 'carrington').'" /> + '.wp_nonce_field('cfct_admin_settings', '_wpnonce', true, false).' + <input type="hidden" name="cf_action" value="cfct_update_settings" /> + <input type="submit" name="submit_button" class="button-primary" value="'.__('Save Changes', 'carrington').'" /> </p> </form> </div> @@ -333,19 +97,100 @@ function cfct_settings_form() { do_action('cfct_settings_form_after'); } -/** - * Deprecated in favor of WP Core Settings API -**/ +function cfct_options_home_column($key) { + $categories = get_categories('hide_empty=0'); + $cat_options = ''; + foreach ($categories as $category) { + if ($category->term_id == get_option('cfct_home_col_'.$key.'_cat')) { + $selected = 'selected="selected"'; + } + else { + $selected = ''; + } + $cat_options .= "\n\t<option value='$category->term_id' $selected>$category->name</option>"; + } + $show_options = ''; + $show_option = cfct_get_option('cfct_home_column_'.$key.'_content'); + if ($show_option == 'latest') { + $latest_selected = 'selected="selected"'; + $list_selected = ''; + } + else { + $latest_selected = ''; + $list_selected = 'selected="selected"'; + } + $html = ' + <tr valign="top"> + <th scope="row"><b>'.sprintf(__('Home Column %s', 'carrington'), $key).'</b></td> + <td> + <fieldset> + <p> + <label for="cfct_home_column_'.$key.'_cat">'.__('Category:', 'carrington').'</label> + <select name="cfct_home_column_'.$key.'_cat" id="cfct_home_column_'.$key.'_cat">'.$cat_options.'</select> + </p> + <p> + <label for="cfct_home_column_'.$key.'_content">'.__('Show:', 'carrington').'</label> + <select name="cfct_home_column_'.$key.'_content" id="cfct_home_column_'.$key.'_content" class="home_column_select"> + <option value="latest" '.$latest_selected.'>'.__('Latest Post Preview', 'carrington').'</option> + <option value="list" '.$list_selected.'>'.__('List of Recent Post Titles', 'carrington').'</option> + </select> + </p> + <p id="cfct_latest_limit_'.$key.'_option" class="hidden"> + <label for="cfct_latest_limit_'.$key.'">'.__('Length of preview, in characters (250 recommended):', 'carrington').'</label> + <input type="text" name="cfct_latest_limit_'.$key.'" id="cfct_latest_limit_'.$key.'" value="'.cfct_get_option('cfct_latest_limit_'.$key).'" /> + </p> + <p id="cfct_list_limit_'.$key.'_option" class="hidden"> + <label for="cfct_list_limit_'.$key.'">'.__('Number of titles to show in list (5 recommended):', 'carrington').'</label> + <input type="text" name="cfct_list_limit_'.$key.'" id="cfct_list_limit_'.$key.'" value="'.cfct_get_option('cfct_list_limit_'.$key).'" /> + </p> + </fieldset> + </td> + </tr> + '; + return $html; +} + function cfct_options_misc() { - _deprecated_function(__FUNCTION__, '3.2'); + $options = array( + 'yes' => __('Yes', 'carrington'), + 'no' => __('No', 'carrington') + ); + $credit_options = ''; + foreach ($options as $k => $v) { + if ($k == get_option('cfct_credit')) { + $credit_selected = 'selected="selected"'; + } + else { + $credit_selected = ''; + } + $credit_options .= "\n\t<option value='$k' $credit_selected>$v</option>"; + } + $html = ' + <tr valign="top"> + <th scope="row">'.sprintf(__('Misc.', 'carrington'), $key).'</td> + <td> + <fieldset> + <p> + <label for="cfct_about_text">'.__('About text (shown in sidebar):', 'carrington').'</label> + <br /> + <textarea name="cfct_about_text" id="cfct_about_text" cols="40" rows="8">'.htmlspecialchars(get_option('cfct_about_text')).'</textarea> + </p> + <p> + <label for="cfct_wp_footer">'.__('Footer code (for analytics, etc.):', 'carrington').'</label> + <br /> + <textarea name="cfct_wp_footer" id="cfct_wp_footer" cols="40" rows="5">'.htmlspecialchars(get_option('cfct_wp_footer')).'</textarea> + </p> + <p> + <label for="cfct_credit">'.__('Give <a href="http://crowdfavorite.com">Crowd Favorite</a> credit in footer:', 'carrington').'</label> + <select name="cfct_credit" id="cfct_credit">'.$credit_options.'</select> + </p> + </fieldset> + </td> + </tr> + '; + return $html; } -/** - * Display a form for image header customization - * - * @return string Markup displaying the form - * -**/ function cfct_header_image_form() { global $wpdb; @@ -357,28 +202,33 @@ function cfct_header_image_form() { ORDER BY post_date_gmt DESC LIMIT 50 "); - $upload_url = admin_url('media-new.php'); - $header_image = cfct_get_option('header_image'); - if (empty($header_image)) { - $header_image = 0; - } - + $upload_url = trailingslashit(get_bloginfo('wpurl')).'wp-admin/media-new.php'; + $checked_attr = ' checked="checked"'; $output = ' <ul style="width: '.((count($images) + 1) * 152).'px"> <li style="background: #666;"> <label for="cfct_header_image_0"> - <input type="radio" name="'.esc_attr(cfct_option_name('header_image')).'" value="0" id="'.esc_attr(cfct_option_name('header_image_0')).'" '.checked($header_image, 0, false).'/>'.__('No Image', 'carrington-core').' + <input type="radio" name="cfct_header_image" value="0" id="cfct_header_image_0" '.$default_checked.'/>'.__('No Image', 'carrington-core').' </label> </li> '; if (count($images)) { + $header_image = get_option('cfct_header_image'); + if (empty($header_image)) { + $header_image = 0; + $default_checked = $checked_attr; + } + else { + $default_checked = ''; + } foreach ($images as $image) { - $id = cfct_option_name('header_image_'.$image->ID); + $id = 'cfct_header_image_'.$image->ID; $thumbnail = wp_get_attachment_image_src($image->ID); + $header_image == $image->ID ? $checked = $checked_attr : $checked = ''; $output .= ' <li style="background-image: url('.$thumbnail[0].')"> <label for="'.$id.'"> - <input type="radio" name="'.esc_attr(cfct_option_name('header_image')).'" value="'.$image->ID.'" id="'.$id.'"'.checked($header_image, $image->ID, false).' />'.esc_html($image->post_title).' + <input type="radio" name="cfct_header_image" value="'.$image->ID.'" id="'.$id.'"'.$checked.' />'.wp_specialchars($image->post_title).' </label> </li>'; } @@ -387,38 +237,24 @@ function cfct_header_image_form() { return '<p>'.sprintf(__('Header Image — <a href="%s">Upload Images</a>', 'carrington-core'), $upload_url).'</p><div class="cfct_header_image_carousel">'.$output.'</div>'; } -/** - * Add assets to the admin side for our control panel - */ -function cfct_admin_enqueue() { - if (!empty($_GET['page']) && $_GET['page'] == 'carrington-settings') { - $core_url = get_template_directory_uri().'/carrington-core/'; - - wp_enqueue_script( - 'jquery-colorpicker', - $core_url.'js/colorpicker.js', - array('jquery'), - '1.0' - ); - - wp_enqueue_style( - 'jquery-colorpicker', - $core_url.'css/colorpicker.css', - array(), - '1.0', - 'screen' - ); - - add_action('admin_head', 'cfct_admin_css', 7); - //add_action('admin_head', 'cfct_admin_js', 8); +if (is_admin()) { + wp_enqueue_script('jquery-colorpicker', get_bloginfo('template_directory').'/carrington-core/js/colorpicker.js', array('jquery'), '1.0'); +// removing until we drop 2.5 compatibility +// wp_enqueue_style('jquery-colorpicker', get_bloginfo('template_directory').'/carrington-core/css/colorpicker.css'); +} + +function cfct_admin_head() { +// see enqueued style above, we'll activate that in the future + if ($_GET['page'] == 'carrington-settings') { + echo ' +<link rel="stylesheet" type="text/css" media="screen" href="'.get_bloginfo('template_directory').'/carrington-core/css/colorpicker.css" /> + '; + cfct_admin_css(); } +// cfct_admin_js(); } -add_action('admin_enqueue_scripts', 'cfct_admin_enqueue'); +add_action('admin_head', 'cfct_admin_head'); -/** - * Admin CSS - * -**/ function cfct_admin_css() { ?> <style type="text/css"> @@ -456,24 +292,10 @@ div.cfct_header_image_carousel li label { div.cfct_header_image_carousel li label input { margin: 0 5px; } - -.cfct-text-long { - width: 383px; -} - -.cfct-help { - color: #777777; - font-size: 11px; -} - </style> <?php } -/** - * Admin JS - * -**/ function cfct_admin_js() { ?> <script type="text/javascript"> @@ -508,3 +330,4 @@ function cfct_home_columns(elem, slide) { <?php } +?> \ No newline at end of file diff --git a/wp-content/themes/carrington-blog/carrington-core/ajax-load.php b/wp-content/themes/carrington-blog/carrington-core/ajax-load.php index 6172c85b9..670ccbbf7 100644 --- a/wp-content/themes/carrington-blog/carrington-core/ajax-load.php +++ b/wp-content/themes/carrington-blog/carrington-core/ajax-load.php @@ -1,9 +1,9 @@ <?php -// This file is part of the Carrington Core Platform for WordPress -// http://crowdfavorite.com/wordpress/carrington-core/ +// This file is part of the Carrington Theme Framework for WordPress +// http://carringtontheme.com // -// Copyright (c) 2008-2012 Crowd Favorite, Ltd. All rights reserved. +// Copyright (c) 2008-2010 Crowd Favorite, Ltd. All rights reserved. // http://crowdfavorite.com // // Released under the GPL license @@ -17,12 +17,6 @@ if (__FILE__ == $_SERVER['SCRIPT_FILENAME']) { die(); } -/** - * Add markup to a post for AJAX display of post content - * - * @return The markup for a close link - * -**/ function cfct_ajax_post_content($post_id) { global $post, $posts, $wp_query, $wp; $post = get_post($post_id); @@ -35,7 +29,7 @@ function cfct_ajax_post_content($post_id) { // If the post is private, make sure the user is allowed to see it before we show it. if ($post->post_status == 'private') { $user = wp_get_current_user(); - if (!$user->ID || !($user->ID == $post->post_author || current_user_can('editor') || current_user_can('administrator'))) { + if (!$user->ID || $user->ID != $post->post_author) { die(); } } @@ -49,10 +43,6 @@ function cfct_ajax_post_content($post_id) { echo apply_filters('cfct_ajax_post_content_close', '<div class="close" id="post_close_'.$post_id.'"><a href="#">'.__('Close', 'carrington').'</a></div>', $post_id); } -/** - * Function used in AJAX to display comments for a given post - * -**/ function cfct_ajax_post_comments($post_id) { global $post, $posts, $wp_query, $wp; $wp_query->is_single = true; @@ -67,10 +57,6 @@ function cfct_ajax_post_comments($post_id) { comments_template(); } -/** - * Request handler for AJAX (see js/carrington.js) - * -**/ function cfct_ajax_load() { if (isset($_GET['cfct_action'])) { switch ($_GET['cfct_action']) { @@ -80,83 +66,41 @@ function cfct_ajax_load() { $post_id = intval($_GET['id']); } else if (isset($_GET['url'])) { - $post_id = url_to_postid($_GET['url']); + $post_id = url_to_post_id($_GET['url']); } if ($post_id) { - $action = 'cfct_ajax_'.sanitize_key($_GET['cfct_action']); - if (function_exists($action)) { - call_user_func($action, $post_id); - die(); - } + call_user_func('cfct_ajax_'.$_GET['cfct_action'], $post_id); + die(); } } } } -/** - * Add attribute to comments link for AJAX loading of comments - * - * @param string $attrs String of preexisting attributes - * @return string $attrs Atrributes for the comments link - * -**/ -function cfct_ajax_comment_link($attrs) { +function cfct_ajax_comment_link() { global $post; - if (strpos($attrs, 'rev="') !== false) { - $attrs = str_replace('rev="', 'rev="post-'.$post->ID.' ', $attrs); - } - else if (strpos($attrs, "rev='") !== false) { - $attrs = str_replace("rev='", "rev='post-".$post->ID.' ', $attrs); - } - else { - $attrs .= ' rev="post-'.$post->ID.'" '; - } - return $attrs; + echo ' rev="post-'.$post->ID.'" '; } add_filter('comments_popup_link_attributes', 'cfct_ajax_comment_link'); -/** - * Returns the number of posts to display on an archive page - * - * @return int The number of posts to display on an archive page -**/ function cfct_posts_per_archive_page_setting() { - $count = cfct_get_option('posts_per_archive_page'); + $count = get_option('cfct_posts_per_archive_page'); intval($count) > 0 ? $count = $count : $count = 25; return $count; } -/** - * Add a self-removing filter to handle category pages (except in admin) - * -**/ +// add a self-removing filter to handle category pages function cfct_add_posts_per_archive_page() { add_filter('pre_get_posts', 'cfct_posts_per_archive_page'); add_filter('pre_get_posts', 'cfct_posts_per_category_page'); } -// disabled by default - enable in your theme if you want this functionality -// if (!is_admin()) { -// add_filter('parse_request', 'cfct_add_posts_per_archive_page'); -// } +add_filter('parse_request', 'cfct_add_posts_per_archive_page'); -/** - * Set the posts per archive page number - * - * @return array Filtered array with a set posts per archive page value - * -**/ function cfct_posts_per_archive_page($query) { remove_filter('pre_get_posts', 'cfct_posts_per_archive_page'); $query->set('posts_per_archive_page', cfct_posts_per_archive_page_setting()); return $query; } -/** - * Set the posts per category page number - * - * @return array Filtered array with a set posts per category page value - * -**/ function cfct_posts_per_category_page($query) { remove_filter('pre_get_posts', 'cfct_posts_per_category_page'); if (is_category()) { @@ -165,3 +109,4 @@ function cfct_posts_per_category_page($query) { return $query; } +?> \ No newline at end of file diff --git a/wp-content/themes/carrington-blog/carrington-core/attachment.php b/wp-content/themes/carrington-blog/carrington-core/attachment.php index 73fe88d55..f275f9f39 100644 --- a/wp-content/themes/carrington-blog/carrington-core/attachment.php +++ b/wp-content/themes/carrington-blog/carrington-core/attachment.php @@ -1,9 +1,9 @@ <?php -// This file is part of the Carrington Core Platform for WordPress -// http://crowdfavorite.com/wordpress/carrington-core/ +// This file is part of the Carrington Theme Framework for WordPress +// http://carringtontheme.com // -// Copyright (c) 2008-2012 Crowd Favorite, Ltd. All rights reserved. +// Copyright (c) 2008-2010 Crowd Favorite, Ltd. All rights reserved. // http://crowdfavorite.com // // Released under the GPL license @@ -15,16 +15,9 @@ // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. // ********************************************************************** -/** - * Get the link of an adjacent image - * - * @param bool $prev Whether or not there is a previous image - * @return string URL of an adjacent image - * -**/ function cfct_get_adjacent_image_link($prev = true) { global $post; - + $post = get_post($post); $attachments = array_values(get_children( array('post_parent' => $post->post_parent, 'post_status' => 'inherit', 'post_type' => 'attachment', 'post_mime_type' => 'image', 'order' => 'ASC', 'orderby' => 'menu_order ID') )); foreach ( $attachments as $k => $attachment ) @@ -37,14 +30,6 @@ function cfct_get_adjacent_image_link($prev = true) { return wp_get_attachment_link($attachments[$k]->ID, 'thumbnail', true); } -/** - * Create a gallery from post attachements. Overrides WordPress default shortcode post gallery code. - * - * @param $unused not used, required by filter hook - * @param array $attr List of attributes that are populated by post gallery shortcode - * @return string Markup to display a gallery - * -**/ function cfct_post_gallery($unused, $attr) { global $post; @@ -138,3 +123,4 @@ function cfct_post_gallery($unused, $attr) { } add_filter('post_gallery', 'cfct_post_gallery', 10, 2); +?> \ No newline at end of file diff --git a/wp-content/themes/carrington-blog/carrington-core/carrington.php b/wp-content/themes/carrington-blog/carrington-core/carrington.php index 20bf91b74..f122a3500 100644 --- a/wp-content/themes/carrington-blog/carrington-core/carrington.php +++ b/wp-content/themes/carrington-blog/carrington-core/carrington.php @@ -1,9 +1,9 @@ <?php -// This file is part of the Carrington Core Platform for WordPress -// http://crowdfavorite.com/wordpress/carrington-core/ +// This file is part of the Carrington Theme Framework for WordPress +// http://carringtontheme.com // -// Copyright (c) 2008-2012 Crowd Favorite, Ltd. All rights reserved. +// Copyright (c) 2008-2010 Crowd Favorite, Ltd. All rights reserved. // http://crowdfavorite.com // // Released under the GPL license @@ -17,10 +17,10 @@ if (__FILE__ == $_SERVER['SCRIPT_FILENAME']) { die(); } -// ini_set('display_errors', '1'); -// ini_set('error_reporting', E_ALL); +// ini_set('display_errors', '1'); +// ini_set('error_reporting', E_ALL); -define('CFCT_CORE_VERSION', '3.4'); +define('CFCT_CORE_VERSION', '3.0.1'); // Path to Carrington Core parent directory (usually the theme). if (!defined('CFCT_PATH')) { @@ -29,6 +29,10 @@ if (!defined('CFCT_PATH')) { load_theme_textdomain('carrington'); +$cfct_options[] = 'cfct_about_text'; +$cfct_options[] = 'cfct_credit'; +$cfct_options[] = 'cfct_wp_footer'; + include_once(CFCT_PATH.'carrington-core/admin.php'); include_once(CFCT_PATH.'carrington-core/templates.php'); include_once(CFCT_PATH.'carrington-core/utility.php'); @@ -38,44 +42,21 @@ include_once(CFCT_PATH.'carrington-core/compatibility.php'); cfct_load_plugins(); -/** - * Loads AJAX request handler - * -**/ function cfct_init() { cfct_admin_request_handler(); - if (cfct_get_option('ajax_load') == 'yes') { + if (cfct_get_option('cfct_ajax_load') == 'yes') { cfct_ajax_load(); } } -//add_action('init', 'cfct_init'); - -/** - * Loads header code from Carrington Options - * -**/ -function cfct_wp_head() { - echo cfct_get_option('wp_head'); -} -add_action('wp_head', 'cfct_wp_head'); +add_action('init', 'cfct_init'); -/** - * Loads footer code from Carrington Options - * -**/ function cfct_wp_footer() { - echo cfct_get_option('wp_footer'); + echo get_option('cfct_wp_footer'); } add_action('wp_footer', 'cfct_wp_footer'); -/** - * Loads about text from Carrington options for display in the sidebar - * - * @return string Markup for the about text - * -**/ function cfct_about_text() { - $about_text = cfct_get_option('about_text'); + $about_text = get_option('cfct_about_text'); if (!empty($about_text)) { $about_text = cfct_basic_content_formatting($about_text); } @@ -92,10 +73,8 @@ function cfct_about_text() { $about_text = get_the_excerpt().sprintf(__('<a class="more" href="%s">more →</a>', 'carrington'), get_permalink()); } $wp_query->query_vars['page'] = $page; - if (!empty($orig_post)) { - $post = $orig_post; - setup_postdata($post); - } + $post = $orig_post; + setup_postdata($post); } if (function_exists('st_add_widget')) { add_filter('the_excerpt', 'st_add_widget'); @@ -103,12 +82,6 @@ function cfct_about_text() { return $about_text; } -/** - * Gets custom colors to be used with a themes - * - * @return string Custom color - * -**/ function cfct_get_custom_colors($type = 'option') { global $cfct_color_options; $colors = array(); @@ -130,3 +103,4 @@ if (!defined('CFCT_DEBUG')) { define('CFCT_DEBUG', false); } +?> \ No newline at end of file diff --git a/wp-content/themes/carrington-blog/carrington-core/compatibility.php b/wp-content/themes/carrington-blog/carrington-core/compatibility.php index e13b066da..1d86f3c79 100644 --- a/wp-content/themes/carrington-blog/carrington-core/compatibility.php +++ b/wp-content/themes/carrington-blog/carrington-core/compatibility.php @@ -1,9 +1,9 @@ <?php -// This file is part of the Carrington Core Platform for WordPress -// http://crowdfavorite.com/wordpress/carrington-core/ +// This file is part of the Carrington Theme Framework for WordPress +// http://carringtontheme.com // -// Copyright (c) 2008-2012 Crowd Favorite, Ltd. All rights reserved. +// Copyright (c) 2008-2010 Crowd Favorite, Ltd. All rights reserved. // http://crowdfavorite.com // // Released under the GPL license @@ -17,26 +17,18 @@ /** * Outputs hidden fields for comment form with unique IDs, based on post ID, making it safe for AJAX pull. - * */ function cfct_comment_id_fields() { global $id; - $replytoid = isset($_GET['replytocom']) ? (int) $_GET['replytocom'] : 0; - - echo cfct_get_comment_id_fields($id, $replytoid); -} -function cfct_get_comment_id_fields($id, $replytoid) { - $out = "<input type='hidden' name='comment_post_ID' value='$id' id='comment_post_ID_p$id' />\n"; - $out .= "<input type='hidden' name='comment_parent' id='comment_parent_p$id' value='$replytoid' />\n"; - - return $out; + $replytoid = isset($_GET['replytocom']) ? (int) $_GET['replytocom'] : 0; + echo "<input type='hidden' name='comment_post_ID' value='$id' id='comment_post_ID_p$id' />\n"; + echo "<input type='hidden' name='comment_parent' id='comment_parent_p$id' value='$replytoid' />\n"; } /** * Filter the comment reply link to add a unique unique ID, based on post ID, making it safe for AJAX pull. - * - **/ + */ function cfct_get_cancel_comment_reply_link($reply_link, $link, $text) { global $post; @@ -51,6 +43,191 @@ function cfct_get_cancel_comment_reply_link($reply_link, $link, $text) { return $reply_link; } + + + +// ITEMS BELOW THIS LINE ARE DEPRECATED AND WILL BE REMOVED IN A FUTURE RELEASE + + +// Functions here without the cfct_ prefix are taken from WordPress 2.7 (GPL) + +if (!function_exists('is_sticky')) { + function is_sticky() { + return false; + } +} + +/** + * Displays classes for post div + * + * @param string|array $class One or more classes to add to the class list. + * @param int $post_id An optional post ID. + */ + +if (!function_exists('post_class')) { + function post_class( $class = '', $post_id = null ) { + // Separates classes with a single space, collates classes for post DIV + echo 'class="' . join( ' ', get_post_class( $class, $post_id ) ) . '"'; + } +} + +/** + * Retrieve the classes for the post div as an array. + * + * The class names are add are many. If the post is a sticky, then the 'sticky' + * class name. The class 'hentry' is always added to each post. For each + * category, the class will be added with 'category-' with category slug is + * added. The tags are the same way as the categories with 'tag-' before the tag + * slug. All classes are passed through the filter, 'post_class' with the list + * of classes, followed by $class parameter value, with the post ID as the last + * parameter. + * + * @param string|array $class One or more classes to add to the class list. + * @param int $post_id An optional post ID. + * @return array Array of classes. + */ +if (!function_exists('get_post_class')) { + function get_post_class( $class = '', $post_id = null ) { + $post = get_post($post_id); + + $classes = array(); + + $classes[] = $post->post_type; + + // sticky for Sticky Posts + if ( is_sticky($post->ID) && is_home()) + $classes[] = 'sticky'; + + // hentry for hAtom compliace + $classes[] = 'hentry'; + + // Categories + foreach ( (array) get_the_category($post->ID) as $cat ) { + if ( empty($cat->slug ) ) + continue; + $classes[] = 'category-' . $cat->slug; + } + + // Tags + foreach ( (array) get_the_tags($post->ID) as $tag ) { + if ( empty($tag->slug ) ) + continue; + $classes[] = 'tag-' . $tag->slug; + } + + if ( !empty($class) ) { + if ( !is_array( $class ) ) + $class = preg_split('#\s+#', $class); + $classes = array_merge($classes, $class); + } + + return apply_filters('post_class', $classes, $class, $post_id); + } +} + +/** + * Display "sticky" CSS class, if a post is sticky. + * + * @param int $post_id An optional post ID. + */ +if (!function_exists('sticky_class')) { + function sticky_class( $post_id = null ) { + if ( !is_sticky($post_id) ) + return; + + echo " sticky"; + } +} + +/** + * Generates semantic classes for each comment element + * + * @param string|array $class One or more classes to add to the class list + * @param int $comment_id An optional comment ID + * @param int $post_id An optional post ID + * @param bool $echo Whether comment_class should echo or return + */ +if (!function_exists('comment_class')) { + function comment_class( $class = '', $comment_id = null, $post_id = null, $echo = true ) { + // Separates classes with a single space, collates classes for comment DIV + $class = 'class="' . join( ' ', get_comment_class( $class, $comment_id, $post_id ) ) . '"'; + if ( $echo) + echo $class; + else + return $class; + } +} + +/** + * Returns the classes for the comment div as an array + * + * @param string|array $class One or more classes to add to the class list + * @param int $comment_id An optional comment ID + * @param int $post_id An optional post ID + * @return array Array of classes + */ +if (!function_exists('get_comment_class')) { + function get_comment_class( $class = '', $comment_id = null, $post_id = null ) { + global $comment_alt, $comment_depth, $comment_thread_alt; + + $comment = get_comment($comment_id); + + $classes = array(); + + // Get the comment type (comment, trackback), + $classes[] = ( empty( $comment->comment_type ) ) ? 'comment' : $comment->comment_type; + + // If the comment author has an id (registered), then print the log in name + if ( $comment->user_id > 0 && $user = get_userdata($comment->user_id) ) { + // For all registered users, 'byuser' + $classes[] = 'byuser comment-author-' . $user->user_nicename; + // For comment authors who are the author of the post + if ( $post = get_post($post_id) ) { + if ( $comment->user_id === $post->post_author ) + $classes[] = 'bypostauthor'; + } + } + + if ( empty($comment_alt) ) + $comment_alt = 0; + if ( empty($comment_depth) ) + $comment_depth = 1; + if ( empty($comment_thread_alt) ) + $comment_thread_alt = 0; + + if ( $comment_alt % 2 ) { + $classes[] = 'odd'; + $classes[] = 'alt'; + } else { + $classes[] = 'even'; + } + + $comment_alt++; + + // Alt for top-level comments + if ( 1 == $comment_depth ) { + if ( $comment_thread_alt % 2 ) { + $classes[] = 'thread-odd'; + $classes[] = 'thread-alt'; + } else { + $classes[] = 'thread-even'; + } + $comment_thread_alt++; + } + + $classes[] = "depth-$comment_depth"; + + if ( !empty($class) ) { + if ( !is_array( $class ) ) + $class = preg_split('#\s+#', $class); + $classes = array_merge($classes, $class); + } + + return apply_filters('comment_class', $classes, $class, $comment_id, $post_id); + } +} + + // For meeting wordpress.org requirements /* @@ -62,3 +239,4 @@ wp_head(); wp_footer(); */ +?> \ No newline at end of file diff --git a/wp-content/themes/carrington-blog/carrington-core/css/colorpicker.css b/wp-content/themes/carrington-blog/carrington-core/css/colorpicker.css new file mode 100644 index 000000000..2116e27b9 --- /dev/null +++ b/wp-content/themes/carrington-blog/carrington-core/css/colorpicker.css @@ -0,0 +1,161 @@ +.colorpicker { + width: 356px; + height: 176px; + overflow: hidden; + position: absolute; + background: url(../images/colorpicker/colorpicker_background.png); + font-family: Arial, Helvetica, sans-serif; + display: none; +} +.colorpicker_color { + width: 150px; + height: 150px; + left: 14px; + top: 13px; + position: absolute; + background: #f00; + overflow: hidden; + cursor: crosshair; +} +.colorpicker_color div { + position: absolute; + top: 0; + left: 0; + width: 150px; + height: 150px; + background: url(../images/colorpicker/colorpicker_overlay.png); +} +.colorpicker_color div div { + position: absolute; + top: 0; + left: 0; + width: 11px; + height: 11px; + overflow: hidden; + background: url(../images/colorpicker/colorpicker_select.gif); + margin: -5px 0 0 -5px; +} +.colorpicker_hue { + position: absolute; + top: 13px; + left: 171px; + width: 35px; + height: 150px; + cursor: n-resize; +} +.colorpicker_hue div { + position: absolute; + width: 35px; + height: 9px; + overflow: hidden; + background: url(../images/colorpicker/colorpicker_indic.gif) left top; + margin: -4px 0 0 0; + left: 0px; +} +.colorpicker_new_color { + position: absolute; + width: 60px; + height: 30px; + left: 213px; + top: 13px; + background: #f00; +} +.colorpicker_current_color { + position: absolute; + width: 60px; + height: 30px; + left: 283px; + top: 13px; + background: #f00; +} +.colorpicker input { + background-color: transparent; + border: 1px solid transparent; + position: absolute; + font-size: 10px; + font-family: Arial, Helvetica, sans-serif; + color: #898989; + top: 4px; + right: 11px; + text-align: right; + margin: 0; + padding: 0; + height: 11px; +} +.colorpicker_hex { + position: absolute; + width: 72px; + height: 22px; + background: url(../images/colorpicker/colorpicker_hex.png) top; + left: 212px; + top: 142px; +} +.colorpicker_hex input { + right: 6px; +} +.colorpicker_field { + height: 22px; + width: 62px; + background-position: top; + position: absolute; +} +.colorpicker_field span { + position: absolute; + width: 12px; + height: 22px; + overflow: hidden; + top: 0; + right: 0; + cursor: n-resize; +} +.colorpicker_rgb_r { + background-image: url(../images/colorpicker/colorpicker_rgb_r.png); + top: 52px; + left: 212px; +} +.colorpicker_rgb_g { + background-image: url(../images/colorpicker/colorpicker_rgb_g.png); + top: 82px; + left: 212px; +} +.colorpicker_rgb_b { + background-image: url(../images/colorpicker/colorpicker_rgb_b.png); + top: 112px; + left: 212px; +} +.colorpicker_hsb_h { + background-image: url(../images/colorpicker/colorpicker_hsb_h.png); + top: 52px; + left: 282px; +} +.colorpicker_hsb_s { + background-image: url(../images/colorpicker/colorpicker_hsb_s.png); + top: 82px; + left: 282px; +} +.colorpicker_hsb_b { + background-image: url(../images/colorpicker/colorpicker_hsb_b.png); + top: 112px; + left: 282px; +} +.colorpicker_submit { + position: absolute; + width: 22px; + height: 22px; + background: url(../images/colorpicker/colorpicker_submit.png) top; + left: 322px; + top: 142px; + overflow: hidden; +} +.colorpicker_focus { + background-position: center; +} +.colorpicker_hex.colorpicker_focus { + background-position: bottom; +} +.colorpicker_submit.colorpicker_focus { + background-position: bottom; +} +.colorpicker_slider { + background-position: bottom; +} diff --git a/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/blank.gif b/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/blank.gif new file mode 100644 index 0000000000000000000000000000000000000000..75b945d2553848b8b6f41fe5e24599c0687b8472 GIT binary patch literal 49 zcmZ?wbhEHbWMp7unE0RJ|Ns9C3=9Vj9AIEzQ2fcl$iTqFpu@nxzyOkGU}6ekWUvMR DQN9XW literal 0 HcmV?d00001 diff --git a/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/colorpicker_background.png b/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/colorpicker_background.png new file mode 100644 index 0000000000000000000000000000000000000000..8401572f1939a1a24c1963513573b0194ad36ee0 GIT binary patch literal 1897 zcmeAS@N?(olHy`uVBq!ia0y~yU`%0PVA#OH#=yW}aad$60|SF(iEBhjaDG}zd16s2 zgJVj5QmTSyZen_BP-<dIW#P$G8wLh;Zci7-kcwMx?)qm(hf5uJSe$xv?a~#cD-=69 z*OoJH?q7I!Yk=2+*G`&KeljqBj$})_8M@z9bF*~Xg1h}1Z=Fsmy;NH2De8G-;@WwS zCmNSK{r7x+!tSvhzl@N}y2pF={VFU{jW_Q;sx&8a*0ZfYPWSF8dt9Z-uz}P6ah1sR z?Hdo?x6Lo$D&qO5@b4dg;oc-ahUc%^ckJuZl`Egd-(h&*XhrJH2Nz=FmRWQcny>4B zT&2IxwwUQgM|)wd*!AUwXM>xAyMr6PN7ujbH_yNKr=Y&xJ|{n4TJiv!jI8Y2yZh_^ zFJ|YLTe4bYzK;Aof5&^de|K7M&%4XjFK^GsFK=gJ+Q56`_HFK!TMbW?M>*c}E!}tN zSMlz<dEq^bW*VkuTfepPew^BOk>QHt1V$D~21m9P0p(Yj%gV|Q9X#l`!%AX?+)-P} z{=*q2T$^v^JWY<Tf81-(@jP|%$M4IfIeQ*IFL?j%?t`6y&$83>_WzBEvpkV>Mr~=a z_T1#d4-1}3#P6@$d*b<p*I)hWV@*%(zyAE#`r5N+o^GFi`flmJNl#Ae?+f7X+Fe_* z<J#o%4K~m6|NjYpu`O@L)>W04TkQ9LefGKk`Ob;|O^v7X#%*elTKZpX{<~xIWZK_( zx=pY?`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pr;1gu$A4?8Q^eT|nswlr9BRR-ADG zMe1Rlb!v})v<fPn2sjopK`=!C3_+pKB3Y*h&Rq&80*p@RODi|={8R&_NZCu~ZBO<X zTt`XGZPPjxlur~a?CbA$-hP|+^5VQ3QETc?Z+pD#^Pk6#Umfd=<l0v^JMO5h$f(M3 zu{s`R+IKu=cbRU@hi}%dcI_Xf<}=T!p5VSX(89vPqSq)#>DWt|=&N_18a7wNnVtQ0 zT~@67XlBp*bssGc>}0Pro89`bAfqVc>CMgQ4`;96Z^rR&eQ6Ja!vscw6b47O2jWe4 z>JC4B^W@2sFH^G^%#=;b?B*}OZ<l5JXU*=K2V0*q*Y7WXfA9Cp++2p7bD!SM{hwj` zMPqN`XSbO87`qQaG4-9V?>;DEJFsj?zWQIAb^DKfE%|w4|LiYrKbB?YEsxzI$r#g7 znDcRZ`tAqoFEOVv75p=dGqafUZo>H^b3fJnIIr3h-uyd`F~^JR{o@_`dU^NNe|yl+ c#KYio_Py8p$<LY?7#J8lUHx3vIVCg!0I6>^umAu6 literal 0 HcmV?d00001 diff --git a/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/colorpicker_hex.png b/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/colorpicker_hex.png new file mode 100644 index 0000000000000000000000000000000000000000..4e532d7c65393fe56d7463e1da3faa591f03de84 GIT binary patch literal 532 zcmeAS@N?(olHy`uVBq!ia0y~yVDMmIV9?=UVqjqKe3co)z`(#+;1OBOz`!jG!i)^F z=14FwFeoH@1o<*BROvD>G)!e+_;H<qp(BWaq0p6q;Z+&~gC#oygW^wS_0}*32F6*Q zE{-7;x8BUyn0?4W<k)@{_Oug8j*paNnWQ#(s=u64@77)4f8odVJ0Wwr9t7O!+946c z|0d~Wfx`9fpo<Ria^HRBPqN<Y|32wXZQLZ4K#|7jQ-YMb7X7U|&$H(8OAdy8@0;hc zG$?RXG;u2CRZMy?d*zf>j64U*b}x0l`ueNSgxv>D^v-8|^t$}bnzYR`Q+)(kjI%#~ z4ga`?VNIC!<%sf?C)fBg{IHT)Bf8#oVegbrB^RTvaXDutEa!?&e8K!<U51ey^NG(k z=ZkY!o#rSzv&NU9;dyM-t@qz`ouk+~7y^!JJu5EeTRKI5vM2M7HS$}^*Cki|Su*7o zg9khFC*I$8H+nCgv211PEVC}r4KGVpt)K7XykpOPcf-?0rwtf)7gZk<cvE4s>8-@q z&l3IyOGVBbJYRVC-7!Ps4Y843c{2O;r=K}6ug!USkg4FCZD*7hZ*Tk)vHmq@@jWqa ztB~`HCwi}p@p5(fx+H`pHS9%@*7Tsi>eo$=i%ky-lyjXPRLB6ap?GuRZNpd34d*57 j-c+L^_Trk*vp+lxmh-RfJN!OOiUAbeu6{1-oD!M<(lq4X literal 0 HcmV?d00001 diff --git a/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/colorpicker_hsb_b.png b/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/colorpicker_hsb_b.png new file mode 100644 index 0000000000000000000000000000000000000000..dfac595d017e279ff670df2c816e02d922660d9f GIT binary patch literal 970 zcmeAS@N?(olHy`uVBq!ia0y~yV6bCgU~uAKVqjosaQ?KCfq{Xuz$3Dlfq`2Xgc%uT z&5>YWU{FZ*2=ZlMsM2L%Xqd{t@Z&lILq`w;L!m1J!>cp~21|AZ2F0Ju>aAf649o$Z zE{-7;x8BTh^p<v%Xxo1`XYHd|8x|dF4$QhX<IA=R!-@|9JojGRZEj*!T)|r3s^GC= z=L`M~^#^9Nh-k`Pn$*0Z^O=CSzFU9ZrlTpFZF};}Z_ePo=9zx$?+1gtv>ELW=bk;| zJR`y2#AlleVXIaZ*_^+B_ikXjorT2-MuyXy91;r|9(=6GaD8s^j#atvy+CMa;X>vE zU%#5Fy>n1_;PKV{MaAa}e7kI4zkdBX?f0KQe}4Sf@%crc^@g9)ZX!oRv`VY1Z{NNx z-F=kju!XH{?u%pzwy+ZIP_@YuRaPdJ@iEk8&8mI!@L}S@fQrL~wY9Ye6F$5?c<{i1 zhOLKhzsp<mLM_y6y7QNb1vjj$*%`J*owX~ftJ@c&SH1V%%a<=*lmfM;|DIiXI9%;& zibl!I^NY(ek{0P195DDcagj#WtYe#U{QdjSKNn_Mm}%aVI#W-C%k+Fz@S+r>nP<~% zb$%BnD$4cO`!BcV{x@5zys%N~;mMP`&N49cti6!_Z{fm=7Xuvy7#0+ih8pu!%g^cl z7oqWp=Wt9+TvU3!nL&1T_EfLd=RYS-oH%*%<oyM48v<OF1Q|G@x4jHb$a&G};uJV# z-8#Lt#CPxCr$&DJS>uzw`JRF7qH?$M&p$5>I{Bx(re=@y=hYVk|IW<4wI<kl`DzCR z2c=!fFL(L9SarEDZn<b|XlT^>tACpe-h2;kuM5^GI$Za^->1#$i>7B$FGH-`gWA8H zkFI*3dukB3djH(HiI3)Wy2UDg=$B-?bM+R7&7%EhI3BFK=Jr7Ft|`+x!Ghj~Y?c`1 z53}47)TEYvii!;oxz6#Y-R;4$2${p08$ZOZUb$x~Q^WPws#iFCJTJBH+$km-<nI1N ziqU<!=Q_a*?zuk70V_i?Oquxk`L{?lZVQ|1qx@h-so35`DK8OM*T73Jx9FVS7?D#} zcJ1DB<`-$Xxw$XDx^59P2(L{~XJ^>9eY?52`AY+)s;ym8^Uclny?M9jTbt_1CsK{8 zR9}Crxbts9jB-G2)YrXxZLdVc#x6a~@#3o1uislXH7R`m{{3vbi!@`l*|h1?851%y zPl`z>^)^UKgmiaz^ZK7KWva5(@O4|TcCvD#+k?9|B-~2gG#371QxV_$Y{#o7QjOE> g8FjO7t!HHL-}2?IQO5Qw3=9kmp00i_>zopr0LRh4RsaA1 literal 0 HcmV?d00001 diff --git a/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/colorpicker_hsb_h.png b/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/colorpicker_hsb_h.png new file mode 100644 index 0000000000000000000000000000000000000000..3977ed9f21e3186eefd37b198a7cc3f8de6c69cb GIT binary patch literal 1012 zcmeAS@N?(olHy`uVBq!ia0y~yV6bCgU~uAKVq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`QkvfO%Ww%TpM)vS$KEH>$L<CGVC<z3a=Ai5<&XV+r;RjYE1dl}x%ayu~XbN&VI zr9uo-yi}#F_PRM#|Ks_Vn*RLt_WT`tH}5^$AowEU-RtP+=yP+wNHKnX{P^KR#k`!n zyj$-LP6#d&6mSg`aa}FA;i-VG#GcxFHx5j2cXxm0x2m^ctJ$^d*BKLXbI%4Egh(;o zzW(a!)zI5=RlN<*zW$sar~F}+xjR?yf%cV}O)rjcAA9}LU4Pd*%hz9|7!SWF-mr32 bJsZO&D_bF#nFY2C3=9mOu6{1-oD!M<Az#;$ literal 0 HcmV?d00001 diff --git a/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/colorpicker_hsb_s.png b/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/colorpicker_hsb_s.png new file mode 100644 index 0000000000000000000000000000000000000000..a2a699736c24b34c60afac8cea399b2c4afcf9a1 GIT binary patch literal 1171 zcmeAS@N?(olHy`uVBq!ia0y~yV6bCgU~uAKVqjosaQ?KCfq{Xuz$3Dlfq`2Xgc%uT z&5>YWU{FZ*2=ZlMsM2L%Xqd{t@Z&lILq`w;L!m1J!>cp~21|AZ2F0Ju>aAf63@nnK zE{-7;x8BTh^thcMay&k(B(y2lc*#}W$y>9-%U^aWocOTi?Gn+0i`ltlIhy!dZmvGw zr14^pM#UEmIkOyxvMbk`z8KuR6*VQ3KbSx3<eRL?W$hW$)l^^J*{65&mwNkzef{6n zYk%(Bb6@;S+Gar(#wg*#1{RJ2%a<>owfWwqOHIrTe#@D8x!4<a?Xp@Mb-eJ8m~x=K zBG2IkoA?;q-Q7ECf<>0Tc(r}a;<fEwYrM1fZroUyk<p=Y(noEwk6QD=gs*G0?HZq^ zOYFa2Us>sSc}v`Sc?pS(tgNW$XyKzGT&zp3wXR!qamDSoVyVX&A5^O;OQjjjeD>_w zp@$m|CY*R$l$)E&&d$D8tlQvOUtIr{s*6{jNA#56e^|n``7y(U^Uqxm3w0j3a^=do zbLZY2@Bdg)Q(L<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al 0 HcmV?d00001 diff --git a/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/colorpicker_indic.gif b/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/colorpicker_indic.gif new file mode 100644 index 0000000000000000000000000000000000000000..f9fa95e2825eadd2d779ad270a71eddb94f94748 GIT binary patch literal 86 zcmZ?wbhEHbRA%60n8?6jX=xc99sU3Re+C8y#h)yU3=B*RIt&a93?O+1CUu{dm8a*5 p9Vpz=mC>*z#`S0JT+y^y7G{bSek+6P-f?H&^tm2zPm-0v8UO&78!`X@ literal 0 HcmV?d00001 diff --git a/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/colorpicker_overlay.png b/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/colorpicker_overlay.png new file mode 100644 index 0000000000000000000000000000000000000000..561cdd9c59a498b499cbfd1295dc4d2037e235ff GIT binary patch literal 10355 zcmeAS@N?(olHy`uVBq!ia0y~yV3-EN9Bd2>3^t5~j~EyjI14-?iy0WWg+Z8+Vb&Z8 z1_lO&WRD<U28JqK28M>I3=BW6Gca@nF)$RmGBCVKV_>jkXJAnL$*kTQ#=xNd)6>N< zq~g|_+S7ecJSHuXQh&bXfZR9#-`2nRUs){ATd*Pa?$pSc5BV?Kiu9_Abgf#s)BP(` zGpB;UJ3p(thc!Y3MMI6v%Kz&d|GuC0&A|A6{qKL$w(q|EK5zYd<@cYD>W-V0>%R@R zomcU${*&RRzl+}Mf4_ZvQTIn4``dS){&>H>T;}n|sP}j8?)`r6_vfE)zW=_vzxMaF z|DUGs|DwP5`~T#$|Jm#Z-psEQ^S_egprmld@5<(?KU3d#G=G0(DAch0ID^0kiN_x| zeXlGl?EQP^FX!){H`s0;|NMO4+OPL+_swD3|F6R4*XN&Ge*b+ZFE9V?@9*;8zrL>i z`{(odf0zC3Z^r-s75@8Db^V(KRW*k^Ki_QFQ+z4TX5mBqn5Fq|KR?>&XTLw+$awR% z|Fd>)e_&}}X4Cd-_xt>J_sRr%ulLuMJ;<@1aV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p-content/themes/carrington-blog/carrington-core/images/colorpicker/colorpicker_rgb_b.png b/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/colorpicker_rgb_b.png new file mode 100644 index 0000000000000000000000000000000000000000..dfac595d017e279ff670df2c816e02d922660d9f GIT binary patch literal 970 zcmeAS@N?(olHy`uVBq!ia0y~yV6bCgU~uAKVqjosaQ?KCfq{Xuz$3Dlfq`2Xgc%uT z&5>YWU{FZ*2=ZlMsM2L%Xqd{t@Z&lILq`w;L!m1J!>cp~21|AZ2F0Ju>aAf649o$Z zE{-7;x8BTh^p<v%Xxo1`XYHd|8x|dF4$QhX<IA=R!-@|9JojGRZEj*!T)|r3s^GC= z=L`M~^#^9Nh-k`Pn$*0Z^O=CSzFU9ZrlTpFZF};}Z_ePo=9zx$?+1gtv>ELW=bk;| zJR`y2#AlleVXIaZ*_^+B_ikXjorT2-MuyXy91;r|9(=6GaD8s^j#atvy+CMa;X>vE zU%#5Fy>n1_;PKV{MaAa}e7kI4zkdBX?f0KQe}4Sf@%crc^@g9)ZX!oRv`VY1Z{NNx z-F=kju!XH{?u%pzwy+ZIP_@YuRaPdJ@iEk8&8mI!@L}S@fQrL~wY9Ye6F$5?c<{i1 zhOLKhzsp<mLM_y6y7QNb1vjj$*%`J*owX~ftJ@c&SH1V%%a<=*lmfM;|DIiXI9%;& zibl!I^NY(ek{0P195DDcagj#WtYe#U{QdjSKNn_Mm}%aVI#W-C%k+Fz@S+r>nP<~% zb$%BnD$4cO`!BcV{x@5zys%N~;mMP`&N49cti6!_Z{fm=7Xuvy7#0+ih8pu!%g^cl z7oqWp=Wt9+TvU3!nL&1T_EfLd=RYS-oH%*%<oyM48v<OF1Q|G@x4jHb$a&G};uJV# z-8#Lt#CPxCr$&DJS>uzw`JRF7qH?$M&p$5>I{Bx(re=@y=hYVk|IW<4wI<kl`DzCR z2c=!fFL(L9SarEDZn<b|XlT^>tACpe-h2;kuM5^GI$Za^->1#$i>7B$FGH-`gWA8H zkFI*3dukB3djH(HiI3)Wy2UDg=$B-?bM+R7&7%EhI3BFK=Jr7Ft|`+x!Ghj~Y?c`1 z53}47)TEYvii!;oxz6#Y-R;4$2${p08$ZOZUb$x~Q^WPws#iFCJTJBH+$km-<nI1N ziqU<!=Q_a*?zuk70V_i?Oquxk`L{?lZVQ|1qx@h-so35`DK8OM*T73Jx9FVS7?D#} zcJ1DB<`-$Xxw$XDx^59P2(L{~XJ^>9eY?52`AY+)s;ym8^Uclny?M9jTbt_1CsK{8 zR9}Crxbts9jB-G2)YrXxZLdVc#x6a~@#3o1uislXH7R`m{{3vbi!@`l*|h1?851%y zPl`z>^)^UKgmiaz^ZK7KWva5(@O4|TcCvD#+k?9|B-~2gG#371QxV_$Y{#o7QjOE> g8FjO7t!HHL-}2?IQO5Qw3=9kmp00i_>zopr0LRh4RsaA1 literal 0 HcmV?d00001 diff --git a/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/colorpicker_rgb_g.png b/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/colorpicker_rgb_g.png new file mode 100644 index 0000000000000000000000000000000000000000..72b32760a5c40b7ab834d176ac588750a06f13f2 GIT binary patch literal 1069 zcmeAS@N?(olHy`uVBq!ia0y~yV6bCgU~uAKVqjosaQ?KCfq{Xuz$3Dlfq`2Xgc%uT z&5>YWU{FZ*2=ZlMsM2L%Xqd{t@Z&lILq`w;L!m1J!>cp~21|AZ2F0Ju>aAf649uH7 zT^vIyZoQd#-v5z<$np4v8*;V>uHce$+3XcycCoEO>Dc9CyUUYRCb}dqlCJ;5tJfLG z7bo(ceZ5>s|7!NliZM4XO;{lqGVR35jaqBpExe>VC18>D8<W%C{3$a|{{HmCZ~6P+ zq=bZqWtj%i98C_FOky=eeAM@@Ufs>Y(0!CijYo)KP1x$lrIS^Dc1>MT-l4#;VhQts zr%zRt?#8XZ9&mN`lEq)0l`myi)mBtgq@)~q{#ms9sE=B4LBWNTmu=P;7Trl))s%YE zLnTOS>bGy-`uh5g9Y4N&`SR7z7ED`rcB+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 diff --git a/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/colorpicker_rgb_r.png b/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/colorpicker_rgb_r.png new file mode 100644 index 0000000000000000000000000000000000000000..4855fe03f8ea8d88b4f8ae625c7958eea65208ac GIT binary patch literal 1066 zcmeAS@N?(olHy`uVBq!ia0y~yV6bCgU~uAKVqjosaQ?KCfq{Xuz$3Dlfq`2Xgc%uT z&5>YWU{FZ*2=ZlMsM2L%Xqd{t@Z&lILq`w;L!m1J!>cp~21|AZ2F0Ju>aAf649pum zT^vIyZoQf5=q>Fia{T_WRN-WfZP^iu%N9ypzv0a@Z^?0`AA(wPB0L;jVvZl4MV>gg zW!{!Y%LR0J8TCVhRs@>l`iMwxN$L=5xtmk6d1HI;>0Ptc9A}nHduG_4_>A{+`m?j| z_S_ekJ9n<xY~G$Und1}9X6w#AE9JNA@IwX011Uz0jJ+%k%a*Av_EPu!B&ZxXU!d=C zfG2yy<;%e?yJGdiLqq*1^_j_KO<dRib>&LUrFtArCQ^6r-(SD^%PRE?D)osb&puX| znVVm~cJ12r>%}``6a)&a=1R$5xpcMo?c296)72Rj^f`V_{8;hl&!0cnZ{EC~@#XO= zt-}T%o0(T%U1c#tS8T~8(NKFKPKJ)7Nw#t8tIC8Jx{fZYTXOtyp@mG^=AGNOZ(q7J zH9Ncec_nw!&aB{&(#<(WQzyO73BTSP!QOPCf6kmaQ?#c~pZ@vt=aVUy-j+@O>XN!@ zXT&t!dY{v$X3m^>^X^?)8JRh=XK%j!c3mG|_sy8|$*Wd)$;h1&%`e~nZHAE5<lk{S zV(k6>>~eF?oI7VV_uM8s4e`AxMIFK{g)@9srJGOP<`z6fSGnW-!veF}wbmw6_V3hu z+-#EY&fDLgpP^!J+}AfP=b!K1yZ35OQlyzs=LHkp`k<)jXxBiW<(G4FbG!Im13msP zs|w9ptkE^)yVK=~UQ07(ZHv$;y8iX+R*kN()mtNUuDx9sW~#<H|9rTHNWh;J^E0M~ zPW<$x-@15`%HP|e^?OQm-o194daiIz;N@4(&(GUx-1Bfre2P(u_2HWCqde++&%e(X zU`!Tl3}4l4&-Htrhl0=Q{W<x{m;UbBzu%EX%7sB(so|EEaO0#eY=RjAjckGkW^qjM zH+5Qg;o?O>-^(nHPd@)Vdek*gq;g(<Uf#Oo74`wDtJlv{m2BepV|wuN5<d~wK#`^U zGbN1H+IcRQc6ng0!X!Sk=k`;hq^R5zYeX2{lvyuxS#bV+y|F>SK}8|H$KEWfjC^Z4 z9egi+RAE}AAvKjFr0(j0SsYikys8jtT(z-JUvNUmwhbE;Y`0AMvPU7K%ZH_}zdza9 z`n|K_yyuc_KWj^ueq7oACBcA$;b205vTVGP!d?63y|d^2+ptCD`ts0;J^F$gE0SuH zlAP{$=nDqO$xoj?{pqP6KXw>)G=ylJP&F`9>yC+x43yfa#>DCwbn3+m4Thec9u3_H zVaBuBUq5`<u#7ccNg=fQ-|^`jS4xVHOyJm4vRly0UC!WX-IQY!;@0eX^+Tv}_inDa emX1G+8J12dS|&B+(HaH@1_n=8KbLh*2~7Zbf8UG% literal 0 HcmV?d00001 diff --git a/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/colorpicker_select.gif b/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/colorpicker_select.gif new file mode 100644 index 0000000000000000000000000000000000000000..599f7f13a6854d198f501588948ffcf97bf9f365 GIT binary patch literal 78 zcmZ?wbhEHb<YwSzn8?Jyz`*by3>X*~6o0ZXGB7YP=zv5)@(fJ!Q<^iRAIM2WupM!m bel+sU&Dy!`4Kq~>qDpK6rfIk_GFSruQg;_i literal 0 HcmV?d00001 diff --git a/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/colorpicker_submit.png b/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/colorpicker_submit.png new file mode 100644 index 0000000000000000000000000000000000000000..7f4c0825f53cc4faba8fc9e043502276765da1f5 GIT binary patch literal 984 zcmeAS@N?(olHy`uVBq!ia0y~yU=U+qV9?=UVq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qy**VWB&ThT(<DFvhu6G!#uI^vC-0!g@0dN4QI2LEPT7^`$OKm!iT|U z%Mz|WVB2stM&;?U=Uz`|e-h7*dHrzJuP;X;|CqDAS3G7|!T<5pga7Ky{L$WbgFepu zfB0Qc>OuRz%NB^ApP*6nZ^gbJzuc>T2J)R=waY%jzQ==C?@h|5`P-ZG<!vmtn`V5d x$p{oX`q8kNUpX$T`MT`$oRubhb^m1;`ZoX0V6|?Z#lXP8;OXk;vd$@?2>=_T$>#t7 literal 0 HcmV?d00001 diff --git a/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/custom_background.png b/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/custom_background.png new file mode 100644 index 0000000000000000000000000000000000000000..cf55ffdd68ed42f2d70bd7ec2010cee86c110816 GIT binary patch literal 1916 zcmeAS@N?(olHy`uVBq!ia0y~yU`%0PVA#OH#=yW}aad$60|NtRfk$L90|U1(2s1Lw znj^u$z@U)q5#-CjP^HVj&@h#O;m36bhK?WxhC){chF56}43_K+42nOQ)my_D7}%LS zT^vIyZoRpCK3}F>_V~l^YpxfTEiV&N^=i%*Ea32%sGxqNQ`u>%z;`arkMbY37d$`G zD$Sm^;+5uJmpeh6E4f;nE@_0Ul)8QQu3BuhMM-a4$G;8fW<NL8%4PD)Rpz|jyjj22 z)Oz09OP5T}9#sjSG{=9FAj7nWnUmB#<w8ThKKytrOYqTImHXbCQvDe8uhdN{U%kpo zLdUGb@WAPfTQdsUx-W|yH<VNRnL25{+RhX|2Jep+C+AQ4qj%EgWY}dB@pjK`(f7Zs zX6LuBcs&1o{e<-McBV!Rsusm*e=nKG@BY(0_wDIsmHn|f_vD^!HviDK_usw0?mG+W zjMvBQO2}gH{;>YI{L{U^`!{W_{rNR)!g>BlYqsxu|EH!-;~0bYmsd-<XP)Q(e5a|R zHo=4;RUn1Ik<DQOBbSNIOTNqg^Paui%YM^-#tgZ=w{NW}t}R!8yjlJK`M>-BK2H4h zZMXdN=i6Sz?A|52zPE0kaq-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BbH$@wZV^vcd@tqbZV4w(|X!*OOB?5#TU^zems!lmZ+lM1%6kyrw%(7tE6e<s(o| z0>#4L)!@vu#@6?m)gI&P8b(b#wlkxYpy?!LLTm>lQ8z<#3n=MSIX~e|cA4NfK`=$& zN!SEfFdEMhNYOZ?<9Rjl|1l1bA45P2pz#ax(ms%HA(+ERBrS=B!)Qw4w7mQ?p>7=t z&i0^~1Eo<&{;61b?Hb$6^ZdrOW@n;`e?@PT4Qu}Y$40~MMD*;^Z~SUIOMmyh+$a(~ z`)lWS%k4kC?EYlv=l^|pHtt_r@$B^#N*eYju9ue=eZSZIMt;Y>j;BX{{Can;^ZV~} z+vB|_y^*b%v+S^D_o`ny$Bx_cckzAt@y0Fh-j1{)k*8;V8JO>@zN+wJ|1%fK1_fq? z6AVo}2gF%_Zut5&$3P<Gyr>9+_vUhglLb4bsrX0DwwKj2i;2mp$o~Gyyzble{rl(t zPGj3(((SE%KQFf`$kex3^<?kSwqBL}exD{=%w^o5<L-IS=hJKzfAQP@f>b>(o7nqo z%5-DUKk677T5lJ}x_|bQ13nCKH9g|I|K3+eoBD2^`^0Nfap8UKhSbbSZ&WKoLa!cv e-1}dS;nbWrzU)EWml+rs7(8A5T-G@yGywoIiasF# literal 0 HcmV?d00001 diff --git a/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/custom_hex.png b/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/custom_hex.png new file mode 100644 index 0000000000000000000000000000000000000000..888f444495b3e08dbfa91181bf94d90bf48c85c8 GIT binary patch literal 562 zcmeAS@N?(olHy`uVBq!ia0y~yVDMmIV9?=UVqjqKe3co)z`(#+;1OBOz`!jG!i)^F z=14FwFeoH@1o<*BROvD>G)!e+_;H<qp(BWaq0p6q;Z+&~gC#oygW^wS_0}*32F4wp zE{-7;x8BS+@6F^Wa(w?fZqY^4TYQuRY*<)buOuo8SpBO1(%tfJM%RX4);4TT4-`2T zEm;)sCc%wsA%}Kua(iR0%=QUK58uv|d;g*A+r~ZopVPj-HUIJ<B)fc9!0Dum9XH>V z2peDSYBaqUrN(efVv4bF!{eIF4f4trM#&dXFx*)F_(yd>R^2qd(63KJSprvyx(YPM zSO2>AuTiAKPx#E*vkV7*)%vq<*tSW5?NV%(+O;&M8MEe0FxpmLY_q{AvOLgh^IJJn zgY8bY-$^p?D69PZ`O>f<Xk&nuScSnHw}RtGZuRUBKHVRx$#JQCjeSYNwz8rm`KXz1 zBL8*R^>7?IXfvtecjQbReug{u!cR2wzPpkCY|;gHsjZ@))!S?C@-i_R-|3Poy+39C zQU}2eg2#<7CG`Ac<ZeIwM2+8UnJo9c)6T3LB1{%7oALSHuNCIAx*Ao53pd}(h<fea z)i`zCyDeT{>kn}FshsY9$!Kt2>*}*(TC%IUPiL<U%ADGDYK?{1)UE}cqFGbDR);M4 zw_xuv-L*liD@C_@i8??m`xmmRB&+YvlZBzH6q;3qKYFcQH*dygTZZyQuOn1+?yhD4 NB?ebNmvv4FO#nWu?>ztj literal 0 HcmV?d00001 diff --git a/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/custom_hsb_b.png b/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/custom_hsb_b.png new file mode 100644 index 0000000000000000000000000000000000000000..2f99dae8e6ef73e91a5d6283d2a732b6372d5e27 GIT binary patch literal 1097 zcmeAS@N?(olHy`uVBq!ia0y~yV6bCgU~uAKVqjosaQ?KCfq{Xuz$3Dlfq`2Xgc%uT z&5>YWU{FZ*2=ZlMsM2L%Xqd{t@Z&lILq`w;L!m1J!>cp~21|AZ2F0Ju>aAf649w>} zT^vIyZoQdR?IGeQbG&}Lb$QjixO$BrIyKYgEmN_3;i@F!$?`Y+ub`uXOXCV#1&u|= z<%1#@xXut24H0-E-zXx{CFsHB_R~W5`?}3nghkI+|G0DeZU5HXy}R@B&%2dBZ2Os9 z_Rie+{_Nl9-n>coH~nxoseA{6^Cf}qpxHV`vlx`W23n<*?|787xX?qraoVjTyc!2Q zUjGnbVrWY&@Ca{wk|(L@E5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c>X{1g4NX8rGE)9t+)K~|0(XLsdvHvBhVAt?B8KRd$}kBwcAgTB9GU|?YIboFyt I=akR{03r+jMF0Q* literal 0 HcmV?d00001 diff --git a/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/custom_hsb_h.png b/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/custom_hsb_h.png new file mode 100644 index 0000000000000000000000000000000000000000..a217e9218e6a512b507a35e8a6141f0e56193439 GIT binary patch literal 970 zcmeAS@N?(olHy`uVBq!ia0y~yV6bCgU~uAKVqjosaQ?KCfq{Xuz$3Dlfq`2Xgc%uT z&5>YWU{FZ*2=ZlMsM2L%Xqd{t@Z&lILq`w;L!m1J!>cp~21|AZ2F0Ju>aAf649o$Z zE{-7;x8BT%^$>BCIq-kCarL{mPa8EelxEHmE1xz=L6F7qf^+{~7rU=2EsZTVn*;P! z6<xk1I67TqcM*KzEMUjtr1(RD<K<7+doNw*O`j)UStWn(ULJpOZgutbSlPAPn}4Uv zr9Df_ujBcDbLL+|<M^7{3v(CfzBy{PNAlJ>4gIBjwjXLmnHy9*9TF251dblL=XAZg z{YH20&Wn#1&A7k+x{S>N;qQO0FP#%|%y-6|5FN=SnznoUZMf@}{`~Uw!G#Yq($45D zNZ0f%@tkIQ^!ZFZ-Ho63w3;w?b6Xb{)_2C*y5*OAjX8UKuGFEFLlHk0eNks^6klVb zm=byI(8F4@*JT!~csksYcP-Km;nibjn3GY|>tA_gb239hq}tz;jo;_zFv<6KGi=zn z?T`V_VFO9`S0blk-bv>FohTJFf6iS0o6BZ?-;q9TJJ*vfU2cbTPKy<sUey_V;i*q& z_1e8#FFq9z=48lty~jDs;hO!?sR7Tdo|Q~Eb!3aWtnKH+-Hi&K@8(9h_^6~*nxCu> z?)9&fis3W*eq@XJ)2A7K6r@AW{ypB3x&PL~HLK(J)=i!tr8lSiTBx{I;*~EuFUGd> z>#|>0z9{i?<*rpR)1E%K)z7r(|6w!U+}5jS3sh!(To#y6;(01vSJ3I#yk$ZAR{I^V zof}qCy|MS&`Bzh~^42SO$X2DgN`7N+QlH%))NW_=%B+_m_Qibl=OwDyYt~=A$T7$A z>Js7a7e36$Wbsi>5K&%Go?_1AS#p_UhT8!Xre%T#y$AlAFgYJi4v}iSHB0L<#~VlG zfXKjSUw>x)S(Day?#7KfMk@p*Bun}0e#}TcuygbB-fR|uLtE+|Y}{G0rm&accw~kt z)10Lp*IG6f%m`C%5SYDG;uc3j%alvSk2me=6!cmY{Zq*|u!kX2%gw>q?RlubTY0!P zLrM8orBI1m923?sG(>-&clXT>msi`X=LaXSSX?!G`?7lGz04TphI(1g>+82nICZyu z{g!-*$ZKLpIVx(s<L*zo#gTFBMMs~Y=J((CCxpJv*}bA9&3ne7_~W7Cjr)%0Gd?&t znXz<vVK2k<DwVJME0(`BTqhWC&)|zB;~#T#cV?-^oj>z`uCIEyUDIvLqUSa&z1b|A g;w@Pk|64MwEx9YZ`ua0T1_lNOPgg&ebxsLQ0M`<?lK=n! literal 0 HcmV?d00001 diff --git a/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/custom_hsb_s.png b/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/custom_hsb_s.png new file mode 100644 index 0000000000000000000000000000000000000000..7826b415077be23ed1b1bf05b2da62d4aa5b1c67 GIT binary patch literal 1168 zcmeAS@N?(olHy`uVBq!ia0y~yV6bCgU~uAKVqjosaQ?KCfq{Xuz$3Dlfq`2Xgc%uT z&5>YWU{FZ*2=ZlMsM2L%Xqd{t@Z&lILq`w;L!m1J!>cp~21|AZ2F0Ju>aAf63@l=v zE{-7;x8BUm^#~4>I6nVwwb|WSO;aKaduHlZZw~py%B!p~Wzzx<E_)V7{V575-<Vv# zeNyaw)%-Pa!lYK#pjwZ`8X`)HMiWBA#G=E@=d9kdd6(t)vV8fz-q+9eb`^cSbL;TW zg0gqU^ZuWkXZzf8f99Jq>*IwAiFR@9E>Sgic#agtBqc4H;w~UC^V08_zZ?t|^QM1# z(8wOd%jjSrF{MgIz{JIypM^<y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k~p2f8K z{QLQrj(x~K6!PwVpZasX`#lYkE<%hg88&)Rvp1Y*{=KbLtW%B2;|j->xShNV(_g*o z5I?EPbZesfq_4N`ZV)Z%JTSvuXr~K9@A6`m2^=@7_xWU9U;aI+_jHHWQulcuS1B@m gifunA@H?HsvR|Ed$D-^e1_lNOPgg&ebxsLQ0KnN3^Z)<= literal 0 HcmV?d00001 diff --git a/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/custom_indic.gif b/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/custom_indic.gif new file mode 100644 index 0000000000000000000000000000000000000000..222fb94cfd66bd2bd525891024289d8ee7adc321 GIT binary patch literal 86 zcmZ?wbhEHbRA%60n8?7e|H!!+3pf7%|DS<@LGdRGBLf2ygAM}&0|Q8&fl1w`W##F) qVh0MhbY(PbiE;gzJ6AMqmW7#Oh2P5Hx_8{!H+`-L+>>Nwum%9JoE@<M literal 0 HcmV?d00001 diff --git a/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/custom_rgb_b.png b/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/custom_rgb_b.png new file mode 100644 index 0000000000000000000000000000000000000000..80764e5d6dd8aac3c5ef87d83b45d29780af1fe9 GIT binary patch literal 1008 zcmeAS@N?(olHy`uVBq!ia0y~yV6bCgU~uAKVqjosaQ?KCfq{Xuz$3Dlfq`2Xgc%uT z&5>YWU{FZ*2=ZlMsM2L%Xqd{t@Z&lILq`w;L!m1J!>cp~21|AZ2F0Ju>aAf649sPo zE{-7;x8BUk_7HKDIq<wJ{i|G6ZNP`fih0xS#d<x`-0RVz)VU!4YC8v$BA3fsMn^$g zJCD>xvBa>D0LKaPOqvEF&J#p>J{3m2yBYebQ?C4;^WHtT-yXiT>0azQ*|p}*)@Ryp z?z}l${_y|()}MC=^VDzLX=~RIeNioI!R^Q1zMhBp?%F+VU|?uVWN2e$Vqj`~@V`~B zv@Ju}^wEp%Mu(F7>uyg_6a0Q-yJw(Q3A5W2Eu&w(ZE5>*O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og/carrington-core/images/colorpicker/custom_rgb_g.png b/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/custom_rgb_g.png new file mode 100644 index 0000000000000000000000000000000000000000..fc9778be1eb862a7ada05ae4a34726df0a2c73af GIT binary patch literal 1069 zcmeAS@N?(olHy`uVBq!ia0y~yV6bCgU~uAKVqjosaQ?KCfq{Xuz$3Dlfq`2Xgc%uT z&5>YWU{FZ*2=ZlMsM2L%Xqd{t@Z&lILq`w;L!m1J!>cp~21|AZ2F0Ju>aAf649uH7 zT^vIyZoQcq>k*tNaa{iV@j236OP)RZeq5w<mc|U1CKb^Zb4T+s;fTnE;+dH#oRJlZ zOEXtYnVIUy+8A`VM3A#lLD6&8vY$79eNZ+x|GsyQb*zlFjQMRR>vwx9;^uX~eOUSZ z&-Ztg=YQ|n|FfrW^%pkb1!hctmbTnWnAFOqs9u{F=giP>_#p!eJ0nBc?^E9<o%_ni z`C)q1w0$|-^WR)fUi?Jn<-C7ZuLDKvxsNSgwco4W-r}0Q!J1hzoOc9;q~}+t*iX;D zWXMnuFlF-BT8XzA`<*8(y1d*^?#}%0>z<#z+dkLNFvdIm`KePLWoP{u8s^`)o_VYL zdF;=2?p3GyGE3Q-Ps*rq=k2^JrpSLW<Eu~4)vU)MR*SR3y=)j#(wFhn%}Pl>&cJZE z=Ekzfn5avuzP~*iap6VUv#V^2Esbi@i=BNv0u($S_()t|eNIJ6YVIP9u0<=hJh3P% zJ5+kkf2$Znl2U3~cWFh*u7_!|Z}qLi*ZFjPJvB}CpUvL7wZYl$B};f1+>V8s-7YFw z@+Rr&(&*l=3<AQc)4h)PNL(+P>9W$ZaLYzlqf6Ik9PyV~9I(x{A}Ky{;*U<@M@nhW zO;<-BcQj1A;~j6h>&VOZ2hRDev0l4n$%b_szq$k#_Bds3o$;)$rqkQU+pi<;!izmY z23vmhD+ixDUwS?MzW<x(+MOkVtLF!u{TCH?Z|=l7>q2In5$nFXjdkfEk)G96=P$h! zRy+_tYw}#RZ=#F`ZagvPKJM@Q{nB-N-@7c5J!#Ds-z>ZQVN*$ava)HzV~g#}S0)#) zKKH#&HuNRqzo3xySGlF`o|z+M`7&`+LQ<OFUUh9z%a?m=otXq3ynh||z_R?*rKwze zoept+YVNysSN~#FQV?L=C&0L_y;^C*u2)Qg0v!zwEG$Y20*(JYS$0+bnyA9mb%Udk zBga`uK#hA|(AfnQYmYIUU3gi#(u<|)cU#=vy4PwCE;Ppc6JnH657_%4abAH=eJ6uw zSAZ(hk`v-rn*=9HuPt3K%qVj_K$VH5&p0f)wC(S-1BG$IjL-PzuNLoPcJNKTIQ8}S ziwaB@eHY8t?rYxH9~LfR<QFH*IBBbI_H4P`R@Yz3NGb`4%6SPhR%TqddFiu>pusGi z=qnQcG-q^8TKuJ3TGu}|kxjmn!STTs(=B$3uW#S8qoMHAEDnJ+ZVO(<sWX^tFW)%# zk1ErXTgofHUi4PyukUO)uH3obrQyf)a}(QL5|V!XP7A*~dwUv_d#F`gWmM@sA;#}> f+gz0X*)lBI%YXf#=F<=c1_lOCS3j3^P6<r_`y<{e literal 0 HcmV?d00001 diff --git a/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/custom_rgb_r.png b/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/custom_rgb_r.png new file mode 100644 index 0000000000000000000000000000000000000000..91b0cd4c520013444ae3a64c7e10b28060992557 GIT binary patch literal 1018 zcmeAS@N?(olHy`uVBq!ia0y~yV6bCgU~uAKVqjosaQ?KCfq{Xuz$3Dlfq`2Xgc%uT z&5>YWU{FZ*2=ZlMsM2L%Xqd{t@Z&lILq`w;L!m1J!>cp~21|AZ2F0Ju>aAf649pFl zE{-7;x8BT%^$>BCIq<wJ{r%<5SCsV)Uw^t{WB*9+OqYu=R}DwCPDhi=ghd_7@+{RS zYBu<2uMP0pu%Kx{i`*+k4lYM03yrOtKl$muwR!7v`S-UyZxhcazh~awckTAUzsCHV zcW<_~Z~On|%paD;_jS6x{TiZFPNx<Wo?PkU@631C%$S{#q0xasK|+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;Q-|FP1_lNOPgg&ebxsLQ07z!hy#N3J literal 0 HcmV?d00001 diff --git a/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/custom_submit.png b/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/custom_submit.png new file mode 100644 index 0000000000000000000000000000000000000000..cd202cd93b753b31926593e79eb3756cd58bd677 GIT binary patch literal 997 zcmeAS@N?(olHy`uVBq!ia0y~yU=U+qV9?=UVqjo+XMTS<0|NtRfk$L90|U1(2s1Lw znj^u$z@U)q5#-CjP^HVj&@h#O;m36bhK?WxhC){chF56}43_K+42nOQ)my_D7?`s? zT^vIyZoQduH~)5u$g%m?*Y7>j`S`|3w^_QbiQc<6Z4~|G$ok0p@~%Ut*mA@<7|ml2 z)*t4*e#dBnnwgboW{{)QiZ!~TH@(75?@sBjTbe0sy;4|xqpaSeS$dKl*%JkX-QS<x zc<=c|%jaKzPHc5q6>(|9b%ENrZ4sBOoDSMXuSwq?!7wc~QT`y40ng|8+dIyyr=_Ra zcn4p!E)3yQ@#mf5KmU#NoA<TbcHeFCIeYH&p6u_-S6|ORrG0-6C%52Aca7?RqWt{N zr@wOvKdnjJ^83<@*}L__wXR;%T6cej#mQR3KmRHX*DGvh4RyZveEr9NCsz7Rulam> z=4y%k7Dey$r6WC5{;pf!eqUNJ+cJQ&hh;naBK|6gtN@)8hxOy5{^jN9&3a*3_C=9< z^~DUe;_}D&@yq^P<}$JW!B@e5P}f0ZVe5m54k_oSZTGML>-OjOyT#{kG-pJ8$g37h zO*?g0GFEk3`~;Toj$tnv)ENSsq_%XdcsVDCMf{!4|FGxw8&r42r7{}uWIj6;yg%zv ztJWEzJ3_Cgs@yy*uXwM)uW~6%YkLucYFtP?pOw&VLG?{yMk|Ci7%gDZ5-8ZIasD}D z>hl$*IR~<2)05N14prTcRaKYa>AH~mLeYUakwNrC*u?b?YZW)Itf(sPV_{%kaB+jb zxUtE`9bXu>iuCB*Fuh<hK`CP4iA^UWJTi7njeAoyuUutYt1$Cl<~#kLJ}ukFdEM#; zj|Z0uX9~wP4Ks^7*UgT8So`mvc-iV%p*Jqx72SKFZpx1=y_wo;8<sgvauD)hKFu?& zYv-3oQ@f|v9^c((Iq6y?gN1!nThHU$=hy%Jbn4r~%X%*_2nMaz%-(rb{#}dE<oUHl zKh_qfm*3xB-tzcOxnfJesSQ)^MenGuuCiLEbGBGS^kGZhS2rhTeZF}wI<N8`Hqkx4 zG|v3Ql{Yp^uWVd0B~jv8e%S3zI+y=^4)nd8lY7L#=Ri$P+?FrjZk!OTz4!N#`Q}{{ z^+mqt2u^S{i`Up^^5f1tUA5)U=SeheW_Z<h(eFe5VW%fs<q{WMSNoBZ_-Oe??Oc|6 z7t#N|P09aRw(I^={~_%5p<QPdOa1q`6CZPLygm8y$B)_ji<5nu_DgZ{*8Xy{K3M+G z@AOIOvoDV&U5wEAm3TYo+ABBigYp+o?05OlpkwE;_8t5FdLD*jWm80-Em4}tz`(%Z M>FVdQ&MBb@0I@R7ivR!s literal 0 HcmV?d00001 diff --git a/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/select.png b/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/select.png new file mode 100644 index 0000000000000000000000000000000000000000..21213bfd51b088497f3a9e423170cd65532d873d GIT binary patch literal 506 zcmeAS@N?(olHy`uVBq!ia0y~yU{C>J4mJh`hKCF@W-u@?u%tWsIx;Y<KVi<=^^$>s zL9)a(q9iy!t)x7$D3!r6B|j-u!8128JvAsbF{QHbWU37V17nY;i(^Q|tv53cdL4EU zXe&2gS>+j|v}k(_%SMH`J<mIBDn3cte0?DN^xes3r5_Ak60@ExGBf-qoR+A0L#%MJ zSlNU8%bp4Q-tl=qo1S}{OE&0KZH=sBaz^-#UjGcXy$<iED2Uyx^^kn<ol~SMaZ$^> z13{X8Je<lq%nUi^Z}&X>#?kx&OVBjMeGA!NNc~b^OPaXDqM7f<!rKZQYKanD_rI^b zbfr}H)FzS8P{Avz%kPVrZ|J+M(Y5AqNp!PRNOzXhOT$n(NzRv*ape=ATV9NAJgC=U z(Z_my(y_G{*Vi60xYRc7Z=kA~j?4t+A_u+`jFt;>**ATCba`FX-xtyzDxQz3GIlp^ z(zz|8z`L1m%B$+sFvrOG<(EwU&X;?%dC}kQX>*NV%k&f{n`O^l_A<?Q)@%<m=B;A< z7k4IkyBtpr6#3=&+90GmhF{rs@xk6RZN-OkW;h+UoymLtg6M2sk?*(UcS+pnTc~lc zXnA<!w6!uqZuxU#HheiT%`(M3<+#xi@$c`oZyLmwH$Qc6U}PxQZFr`&=36EM0|SGn LtDnm{r-UW|{}|Rt literal 0 HcmV?d00001 diff --git a/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/select2.png b/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/select2.png new file mode 100644 index 0000000000000000000000000000000000000000..2cd2cabeb6777c724034d5b0e0efd664011f515c GIT binary patch literal 518 zcmeAS@N?(olHy`uVBq!ia0y~yU{C>J4mJh`hKCF@W-u@?a29w(7Bet#3xhBt!>l<H z3=9kk$sR$z3=CDe3=9oZ85n+CXJF_EVqhqAWng%f#=v07&cLAflUcnrjDdl%$J50z zq~g|_83(-%JBYZR_g=1bWr^<67wjBMSqmTUi+^%x>iq|&TH~+m)fS)H)Fkc5xiB-y z(f8Gk7c7esqK{-oooKyj({^U&%+uaQt#h_q(|sV2!La+rRcisJ^9~FON*#=ajeHLR zdz2DXlr|=FxgJWm_KrcL*jMt5Tmk17hT}#@)D2kl8q5z|j@s^$UCXoO?2^|S^S&K= zF;&HL?WK^_U2WU@pI>V`FjMn)pJBnWcNId>?Tj9irhHUkd-3cPFKb9KtLJ4&hPPqN z=hxmWEU-Ds?{p?=lKqbO+N6Xd$0D`_w(|yahA>TaPz~S=Vam0hu<1+8-Z!6<?>gAn z*iDtYmA9a7|9(pc$un93=XUw0Nlw|sYa+q(@3`}_@E7}gTx-*&9-Hyx-`OoeqMnx} z>jWOLFTA^Mjh6lFj7Kv(R4&JEewQY^_OQuoy#pHId`DY&)pu@q$Yl`~e4~JW&g>10 z56n)t`*HUrGbjn}Jn5Hs#KuI6M{T#&&u?AVcJa#0a7j6Cbfo>`d+rB^Z7%(mV$iQ_ WKe9a_MVNtsfx*+&&t;ucLK6Vh5Ytlt literal 0 HcmV?d00001 diff --git a/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/slider.png b/wp-content/themes/carrington-blog/carrington-core/images/colorpicker/slider.png new file mode 100644 index 0000000000000000000000000000000000000000..8b03da96ebd45d66729466d43f263854ce7a0c49 GIT binary patch literal 315 zcmeAS@N?(olHy`uVBq!ia0y~yU=U|uU}WK7VqjqKskJC$U|?WLcl32+U|4^`oVDvE z0|SF(iEBhjaDG}zd16s2gJVj5QmTSyZen_BP-<dIW#P$G8wLi3vz{)FAr-gY+_C0s zHsE2n5D>7sPu4<AW+C(UqzAL63M`f1+N1GKVC8w|MLcz0ZqXB07tRUNX?u8UP4w-! zO`YprU)x$K|I2Q2<h1pZE*XB(;A(YR7@#4-^;Cb#W&SCavY$S^UR!i}@6nwKs(~6J z5ZR~N8<UzK%37Tkz6pC}8NR~YYt84_u1PQ@Q!Y)7kaPf>1TyfO*2ZT)m-BVhO6$9L wLQN6zx_K&D=uB~scUg$H&VSKzMm7fR=t)LOw?D`;FfcH9y85}Sb4q9e03k_rc>n+a literal 0 HcmV?d00001 diff --git a/wp-content/themes/carrington-blog/carrington-core/js/colorpicker.js b/wp-content/themes/carrington-blog/carrington-core/js/colorpicker.js new file mode 100644 index 000000000..e9dbd2efa --- /dev/null +++ b/wp-content/themes/carrington-blog/carrington-core/js/colorpicker.js @@ -0,0 +1,490 @@ +/** + * + * Color picker + * Author: Stefan Petre www.eyecon.ro + * + */ +(function ($) { + var ColorPicker = function () { + var + ids = {}, + inAction, + charMin = 65, + visible, + tpl = '<div class="colorpicker"><div class="colorpicker_color"><div><div></div></div></div><div class="colorpicker_hue"><div></div></div><div class="colorpicker_new_color"></div><div class="colorpicker_current_color"></div><div class="colorpicker_hex"><input type="text" maxlength="6" size="6" /></div><div class="colorpicker_rgb_r colorpicker_field"><input type="text" maxlength="3" size="3" /><span></span></div><div class="colorpicker_rgb_g colorpicker_field"><input type="text" maxlength="3" size="3" /><span></span></div><div class="colorpicker_rgb_b colorpicker_field"><input type="text" maxlength="3" size="3" /><span></span></div><div class="colorpicker_hsb_h colorpicker_field"><input type="text" maxlength="3" size="3" /><span></span></div><div class="colorpicker_hsb_s colorpicker_field"><input type="text" maxlength="3" size="3" /><span></span></div><div class="colorpicker_hsb_b colorpicker_field"><input type="text" maxlength="3" size="3" /><span></span></div><div class="colorpicker_submit"></div></div>', + defaults = { + eventName: 'click', + onShow: function () {}, + onBeforeShow: function(){}, + onHide: function () {}, + onChange: function () {}, + onSubmit: function () {}, + color: 'ff0000', + livePreview: true, + flat: false + }, + fillRGBFields = function (hsb, cal) { + var rgb = HSBToRGB(hsb); + $(cal).data('colorpicker').fields + .eq(1).val(rgb.r).end() + .eq(2).val(rgb.g).end() + .eq(3).val(rgb.b).end(); + }, + fillHSBFields = function (hsb, cal) { + $(cal).data('colorpicker').fields + .eq(4).val(hsb.h).end() + .eq(5).val(hsb.s).end() + .eq(6).val(hsb.b).end(); + }, + fillHexFields = function (hsb, cal) { + $(cal).data('colorpicker').fields + .eq(0).val(HSBToHex(hsb)).end(); + }, + setSelector = function (hsb, cal) { + $(cal).data('colorpicker').selector.css('backgroundColor', '#' + HSBToHex({h: hsb.h, s: 100, b: 100})); + $(cal).data('colorpicker').selectorIndic.css({ + left: parseInt(150 * hsb.s/100, 10), + top: parseInt(150 * (100-hsb.b)/100, 10) + }); + }, + setHue = function (hsb, cal) { + $(cal).data('colorpicker').hue.css('top', parseInt(150 - 150 * hsb.h/360, 10)); + }, + setCurrentColor = function (hsb, cal) { + $(cal).data('colorpicker').currentColor.css('backgroundColor', '#' + HSBToHex(hsb)); + }, + setNewColor = function (hsb, cal) { + $(cal).data('colorpicker').newColor.css('backgroundColor', '#' + HSBToHex(hsb)); + }, + keyDown = function (ev) { + var pressedKey = ev.charCode || ev.keyCode || -1; + if ((pressedKey > charMin && pressedKey <= 90) || pressedKey == 32) { + return false; + } + var cal = $(this).parent().parent(); + if (cal.data('colorpicker').livePreview === true) { + change.apply(this); + } + }, + change = function (ev) { + var cal = $(this).parent().parent(), col; + if (this.parentNode.className.indexOf('_hex') > 0) { + cal.data('colorpicker').color = col = HexToHSB(fixHex(this.value)); + } else if (this.parentNode.className.indexOf('_hsb') > 0) { + cal.data('colorpicker').color = col = fixHSB({ + h: parseInt(cal.data('colorpicker').fields.eq(4).val(), 10), + s: parseInt(cal.data('colorpicker').fields.eq(5).val(), 10), + b: parseInt(cal.data('colorpicker').fields.eq(6).val(), 10) + }); + } else { + cal.data('colorpicker').color = col = RGBToHSB(fixRGB({ + r: parseInt(cal.data('colorpicker').fields.eq(1).val(), 10), + g: parseInt(cal.data('colorpicker').fields.eq(2).val(), 10), + b: parseInt(cal.data('colorpicker').fields.eq(3).val(), 10) + })); + } + if (ev) { + fillRGBFields(col, cal.get(0)); + fillHexFields(col, cal.get(0)); + fillHSBFields(col, cal.get(0)); + } + setSelector(col, cal.get(0)); + setHue(col, cal.get(0)); + setNewColor(col, cal.get(0)); + cal.data('colorpicker').onChange.apply(cal, [col, HSBToHex(col), HSBToRGB(col)]); + }, + blur = function (ev) { + var cal = $(this).parent().parent(); + cal.data('colorpicker').fields.parent().removeClass('colorpicker_focus') + }, + focus = function () { + charMin = this.parentNode.className.indexOf('_hex') > 0 ? 70 : 65; + $(this).parent().parent().data('colorpicker').fields.parent().removeClass('colorpicker_focus'); + $(this).parent().addClass('colorpicker_focus'); + }, + downIncrement = function (ev) { + var field = $(this).parent().find('input').focus(); + var current = { + el: $(this).parent().addClass('colorpicker_slider'), + max: this.parentNode.className.indexOf('_hsb_h') > 0 ? 360 : (this.parentNode.className.indexOf('_hsb') > 0 ? 100 : 255), + y: ev.pageY, + field: field, + val: parseInt(field.val(), 10), + preview: $(this).parent().parent().data('colorpicker').livePreview + }; + $(document).bind('mouseup', current, upIncrement); + $(document).bind('mousemove', current, moveIncrement); + }, + moveIncrement = function (ev) { + ev.data.field.val(Math.max(0, Math.min(ev.data.max, parseInt(ev.data.val + ev.pageY - ev.data.y, 10)))); + if (ev.data.preview) { + change.apply(ev.data.field.get(0), [true]); + } + return false; + }, + upIncrement = function (ev) { + change.apply(ev.data.field.get(0), [true]); + ev.data.el.removeClass('colorpicker_slider').find('input').focus(); + $(document).unbind('mouseup', upIncrement); + $(document).unbind('mousemove', moveIncrement); + return false; + }, + downHue = function (ev) { + var current = { + cal: $(this).parent(), + y: $(this).offset().top + }; + current.preview = current.cal.data('colorpicker').livePreview; + $(document).bind('mouseup', current, upHue); + $(document).bind('mousemove', current, moveHue); + }, + moveHue = function (ev) { + change.apply( + ev.data.cal.data('colorpicker') + .fields + .eq(4) + .val(parseInt(360*(150 - Math.max(0,Math.min(150,(ev.pageY - ev.data.y))))/150, 10)) + .get(0), + [ev.data.preview] + ); + return false; + }, + upHue = function (ev) { + fillRGBFields(ev.data.cal.data('colorpicker').color, ev.data.cal.get(0)); + fillHexFields(ev.data.cal.data('colorpicker').color, ev.data.cal.get(0)); + $(document).unbind('mouseup', upHue); + $(document).unbind('mousemove', moveHue); + return false; + }, + downSelector = function (ev) { + var current = { + cal: $(this).parent(), + pos: $(this).offset() + }; + current.preview = current.cal.data('colorpicker').livePreview; + $(document).bind('mouseup', current, upSelector); + $(document).bind('mousemove', current, moveSelector); + }, + moveSelector = function (ev) { + change.apply( + ev.data.cal.data('colorpicker') + .fields + .eq(6) + .val(parseInt(100*(150 - Math.max(0,Math.min(150,(ev.pageY - ev.data.pos.top))))/150, 10)) + .end() + .eq(5) + .val(parseInt(100*(Math.max(0,Math.min(150,(ev.pageX - ev.data.pos.left))))/150, 10)) + .get(0), + [ev.data.preview] + ); + return false; + }, + upSelector = function (ev) { + fillRGBFields(ev.data.cal.data('colorpicker').color, ev.data.cal.get(0)); + fillHexFields(ev.data.cal.data('colorpicker').color, ev.data.cal.get(0)); + $(document).unbind('mouseup', upSelector); + $(document).unbind('mousemove', moveSelector); + return false; + }, + enterSubmit = function (ev) { + $(this).addClass('colorpicker_focus'); + }, + leaveSubmit = function (ev) { + $(this).removeClass('colorpicker_focus'); + }, + clickSubmit = function (ev) { + var cal = $(this).parent(); + var col = cal.data('colorpicker').color; + cal.data('colorpicker').origColor = col; + setCurrentColor(col, cal.get(0)); + cal.data('colorpicker').onSubmit(col, HSBToHex(col), HSBToRGB(col)); + }, + show = function (ev) { + var cal = $('#' + $(this).data('colorpickerId')); + cal.data('colorpicker').onBeforeShow.apply(this, [cal.get(0)]); + var pos = $(this).offset(); + var viewPort = getViewport(); + var top = pos.top + this.offsetHeight; + var left = pos.left; + if (top + 176 > viewPort.t + viewPort.h) { + top -= this.offsetHeight + 176; + } + if (left + 356 > viewPort.l + viewPort.w) { + left -= 356; + } + cal.css({left: left + 'px', top: top + 'px'}); + if (cal.data('colorpicker').onShow.apply(this, [cal.get(0)]) != false) { + cal.show(); + } + $(document).bind('mousedown', {cal: cal}, hide); + return false; + }, + hide = function (ev) { + if (!isChildOf(ev.data.cal.get(0), ev.target, ev.data.cal.get(0))) { + if (ev.data.cal.data('colorpicker').onHide.apply(this, [ev.data.cal.get(0)]) != false) { + ev.data.cal.hide(); + } + $(document).unbind('mousedown', hide); + } + }, + isChildOf = function(parentEl, el, container) { + if (parentEl == el) { + return true; + } + if (parentEl.contains) { + return parentEl.contains(el); + } + if ( parentEl.compareDocumentPosition ) { + return !!(parentEl.compareDocumentPosition(el) & 16); + } + var prEl = el.parentNode; + while(prEl && prEl != container) { + if (prEl == parentEl) + return true; + prEl = prEl.parentNode; + } + return false; + }, + getViewport = function () { + var m = document.compatMode == 'CSS1Compat'; + return { + l : window.pageXOffset || (m ? document.documentElement.scrollLeft : document.body.scrollLeft), + t : window.pageYOffset || (m ? document.documentElement.scrollTop : document.body.scrollTop), + w : window.innerWidth || (m ? document.documentElement.clientWidth : document.body.clientWidth), + h : window.innerHeight || (m ? document.documentElement.clientHeight : document.body.clientHeight) + }; + }, + fixHSB = function (hsb) { + return { + h: Math.min(360, Math.max(0, hsb.h)), + s: Math.min(100, Math.max(0, hsb.s)), + b: Math.min(100, Math.max(0, hsb.b)) + }; + }, + fixRGB = function (rgb) { + return { + r: Math.min(255, Math.max(0, rgb.r)), + g: Math.min(255, Math.max(0, rgb.g)), + b: Math.min(255, Math.max(0, rgb.b)) + }; + }, + fixHex = function (hex) { + var len = 6 - hex.length; + if (len > 0) { + var o = []; + for (var i=0; i<len; i++) { + o.push('0'); + } + o.push(hex); + hex = o.join(''); + } + return hex; + }, + HexToRGB = function (hex) { + var hex = parseInt(((hex.indexOf('#') > -1) ? hex.substring(1) : hex), 16); + return {r: hex >> 16, g: (hex & 0x00FF00) >> 8, b: (hex & 0x0000FF)}; + }, + HexToHSB = function (hex) { + return RGBToHSB(HexToRGB(hex)); + }, + RGBToHSB = function (rgb) { + var hsb = {}; + hsb.b = Math.max(Math.max(rgb.r,rgb.g),rgb.b); + hsb.s = (hsb.b <= 0) ? 0 : Math.round(100*(hsb.b - Math.min(Math.min(rgb.r,rgb.g),rgb.b))/hsb.b); + hsb.b = Math.round((hsb.b /255)*100); + if((rgb.r==rgb.g) && (rgb.g==rgb.b)) hsb.h = 0; + else if(rgb.r>=rgb.g && rgb.g>=rgb.b) hsb.h = 60*(rgb.g-rgb.b)/(rgb.r-rgb.b); + else if(rgb.g>=rgb.r && rgb.r>=rgb.b) hsb.h = 60 + 60*(rgb.g-rgb.r)/(rgb.g-rgb.b); + else if(rgb.g>=rgb.b && rgb.b>=rgb.r) hsb.h = 120 + 60*(rgb.b-rgb.r)/(rgb.g-rgb.r); + else if(rgb.b>=rgb.g && rgb.g>=rgb.r) hsb.h = 180 + 60*(rgb.b-rgb.g)/(rgb.b-rgb.r); + else if(rgb.b>=rgb.r && rgb.r>=rgb.g) hsb.h = 240 + 60*(rgb.r-rgb.g)/(rgb.b-rgb.g); + else if(rgb.r>=rgb.b && rgb.b>=rgb.g) hsb.h = 300 + 60*(rgb.r-rgb.b)/(rgb.r-rgb.g); + else hsb.h = 0; + hsb.h = Math.round(hsb.h); + return hsb; + }, + HSBToRGB = function (hsb) { + var rgb = {}; + var h = Math.round(hsb.h); + var s = Math.round(hsb.s*255/100); + var v = Math.round(hsb.b*255/100); + if(s == 0) { + rgb.r = rgb.g = rgb.b = v; + } else { + var t1 = v; + var t2 = (255-s)*v/255; + var t3 = (t1-t2)*(h%60)/60; + if(h==360) h = 0; + if(h<60) {rgb.r=t1; rgb.b=t2; rgb.g=t2+t3} + else if(h<120) {rgb.g=t1; rgb.b=t2; rgb.r=t1-t3} + else if(h<180) {rgb.g=t1; rgb.r=t2; rgb.b=t2+t3} + else if(h<240) {rgb.b=t1; rgb.r=t2; rgb.g=t1-t3} + else if(h<300) {rgb.b=t1; rgb.g=t2; rgb.r=t2+t3} + else if(h<360) {rgb.r=t1; rgb.g=t2; rgb.b=t1-t3} + else {rgb.r=0; rgb.g=0; rgb.b=0} + } + return {r:Math.round(rgb.r), g:Math.round(rgb.g), b:Math.round(rgb.b)}; + }, + RGBToHex = function (rgb) { + var hex = [ + rgb.r.toString(16), + rgb.g.toString(16), + rgb.b.toString(16) + ]; + $.each(hex, function (nr, val) { + if (val.length == 1) { + hex[nr] = '0' + val; + } + }); + return hex.join(''); + }, + HSBToHex = function (hsb) { + return RGBToHex(HSBToRGB(hsb)); + }; + return { + init: function (options) { + options = $.extend({}, defaults, options||{}); + if (typeof options.color == 'string') { + options.color = HexToHSB(options.color); + } else if (options.color.r != undefined && options.color.g != undefined && options.color.b != undefined) { + options.color = RGBToHSB(options.color); + } else if (options.color.h != undefined && options.color.s != undefined && options.color.b != undefined) { + options.color = fixHSB(options.color); + } else { + return this; + } + options.origColor = options.color; + return this.each(function () { + if (!$(this).data('colorpickerId')) { + var id = 'collorpicker_' + parseInt(Math.random() * 1000); + $(this).data('colorpickerId', id); + var cal = $(tpl).attr('id', id); + if (options.flat) { + cal.appendTo(this).show(); + } else { + cal.appendTo(document.body); + } + options.fields = cal + .find('input') + .bind('keydown', keyDown) + .bind('change', change) + .bind('blur', blur) + .bind('focus', focus); + cal.find('span').bind('mousedown', downIncrement); + options.selector = cal.find('div.colorpicker_color').bind('mousedown', downSelector); + options.selectorIndic = options.selector.find('div div'); + options.hue = cal.find('div.colorpicker_hue div'); + cal.find('div.colorpicker_hue').bind('mousedown', downHue); + options.newColor = cal.find('div.colorpicker_new_color'); + options.currentColor = cal.find('div.colorpicker_current_color'); + cal.data('colorpicker', options); + cal.find('div.colorpicker_submit') + .bind('mouseenter', enterSubmit) + .bind('mouseleave', leaveSubmit) + .bind('click', clickSubmit); + fillRGBFields(options.color, cal.get(0)); + fillHSBFields(options.color, cal.get(0)); + fillHexFields(options.color, cal.get(0)); + setHue(options.color, cal.get(0)); + setSelector(options.color, cal.get(0)); + setCurrentColor(options.color, cal.get(0)); + setNewColor(options.color, cal.get(0)); + if (options.flat) { + cal.css({ + position: 'relative', + display: 'block' + }); + } else { + $(this).bind(options.eventName, show); + } + } + }); + }, + showPicker: function() { + return this.each( function () { + if ($(this).data('colorpickerId')) { + show.apply(this); + } + }); + }, + hidePicker: function() { + return this.each( function () { + if ($(this).data('colorpickerId')) { + $('#' + $(this).data('colorpickerId')).hide(); + } + }); + }, + setColor: function(col) { + if (typeof col == 'string') { + col = HexToHSB(col); + } else if (col.r != undefined && col.g != undefined && col.b != undefined) { + col = RGBToHSB(col); + } else if (col.h != undefined && col.s != undefined && col.b != undefined) { + col = fixHSB(col); + } else { + return this; + } + return this.each(function(){ + if ($(this).data('colorpickerId')) { + var cal = $('#' + $(this).data('colorpickerId')); + cal.data('colorpicker').color = col; + cal.data('colorpicker').origColor = col; + fillRGBFields(col, cal.get(0)); + fillHSBFields(col, cal.get(0)); + fillHexFields(col, cal.get(0)); + setHue(col, cal.get(0)); + setSelector(col, cal.get(0)); + setCurrentColor(col, cal.get(0)); + setNewColor(col, cal.get(0)); + } + }); + } + }; + }(); + $.fn.extend({ + ColorPicker: ColorPicker.init, + ColorPickerHide: ColorPicker.hide, + ColorPickerShow: ColorPicker.show, + ColorPickerSetColor: ColorPicker.setColor + }); +})(jQuery) + +// hex to decimal code found here and used with minor modification: http://www.telerik.com/community/forums/aspnet-ajax/colorpicker/calculate-color-contrast-in-javascript.aspx +function getDec(hexChar) { + if (typeof hexChar == 'undefined') { + return 0; + } + switch(hexChar.toUpperCase()) { + case '0': return 0; + case '1': return 1; + case '2': return 2; + case '3': return 3; + case '4': return 4; + case '5': return 5; + case '6': return 6; + case '7': return 7; + case '8': return 8; + case '9': return 9; + case 'A': return 10; + case 'B': return 11; + case 'C': return 12; + case 'D': return 13; + case 'E': return 14; + case 'F': return 15; + }; +} +function hexToDec(hex) { + var colorChars = hex.split(''); + var dec = (getDec(colorChars[0]) * 16) + getDec(colorChars[1]); + return dec; +} +function getRGB(color) { + // remove the '#' + if (color.indexOf('#') != -1) { + color = color.substring(color.indexOf('#') + 1); + } + var r = hexToDec(color.substr(0, 2)); + var g = hexToDec(color.substr(2, 2)); + var b = hexToDec(color.substr(4, 2)); + return { r: r, g: g, b: b}; +} \ No newline at end of file diff --git a/wp-content/themes/carrington-blog/carrington-core/lightbox/LICENSE.txt b/wp-content/themes/carrington-blog/carrington-core/lightbox/LICENSE.txt new file mode 100644 index 000000000..55a9d861d --- /dev/null +++ b/wp-content/themes/carrington-blog/carrington-core/lightbox/LICENSE.txt @@ -0,0 +1,30 @@ +Software License Agreement (BSD License) + +Copyright (c) 2008 Warren Krewenki +All rights reserved. + +Redistribution and use of this software in source and binary forms, with or without modification, are +permitted provided that the following conditions are met: + +* Redistributions of source code must retain the above + copyright notice, this list of conditions and the + following disclaimer. + +* Redistributions in binary form must reproduce the above + copyright notice, this list of conditions and the + following disclaimer in the documentation and/or other + materials provided with the distribution. + +* Neither the name of jQuery Lightbox nor the names of its + contributors may be used to endorse or promote products + derived from this software without specific prior + written permission of jQuery Lightbox. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED +WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A +PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR +ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR +TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF +ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. \ No newline at end of file diff --git a/wp-content/themes/carrington-blog/carrington-core/lightbox/css/thickbox.css b/wp-content/themes/carrington-blog/carrington-core/lightbox/css/thickbox.css new file mode 100644 index 000000000..2586a5c47 --- /dev/null +++ b/wp-content/themes/carrington-blog/carrington-core/lightbox/css/thickbox.css @@ -0,0 +1,157 @@ +/* ----------------------------------------------------------------------------------------------------------------*/ +/* ---------->>> thickbox settings <<<-----------------------------------------------------------------------------*/ +/* ----------------------------------------------------------------------------------------------------------------*/ +#TB_overlay { + position: fixed; + z-index:100; + top: 0px; + left: 0px; + height:100%; + width:100%; +} + +.TB_overlayMacFFBGHack {background: url(../img/macFFBgHack.png) repeat;} +.TB_overlayBG { + background-color:#000; + filter:alpha(opacity=75); + -moz-opacity: 0.75; + opacity: 0.75; +} + +* html #TB_overlay { /* ie6 hack */ + position: absolute; + height: expression(document.body.scrollHeight > document.body.offsetHeight ? document.body.scrollHeight : document.body.offsetHeight + 'px'); +} + +#TB_window { + position: fixed; + background: #ffffff; + z-index: 102; + display:none; + border: 2px solid #ccc; + text-align:left; + top:50%; + left:50%; +} + +* html #TB_window { /* ie6 hack */ +position: absolute; +margin-top: expression(0 - parseInt(this.offsetHeight / 2) + (TBWindowMargin = document.documentElement && document.documentElement.scrollTop || document.body.scrollTop) + 'px'); +} + +#TB_window img#TB_Image { + display:block; +} + +#TB_caption{ + padding:7px 30px 10px 25px; + float:left; + overflow:hidden; + word-wrap: break-word; +} + +#TB_closeWindow{ + height:25px; + padding:11px 25px 10px 0; + float:right; +} + +#TB_closeAjaxWindow{ + float:right; + padding:5px 15px 5px 0; + margin-bottom:1px; + text-align:right; +} + +#TB_ajaxWindowTitle{ + float:left; + padding:5px 0 5px 15px; +} + +#TB_title{ + height:27px; +} + +#TB_ImageWrapper { + margin:15px 15px 0; + position:relative; +} +#TB_ImageHoverNav { + height:100%; + top:0; + width: 100%; + position:absolute; + zoom:1; +} +a#TB_prev, +a#TB_next { + background:transparent url(../img/blank.gif); /* IE6 hover area hack */ + height:100%; + width: 49%; + text-indent:-32000px; +} +a#TB_prev { + float:left; +} +a#TB_next { + float:right; +} + +#TB_ajaxContent{ + clear:both; + padding:2px 15px 15px 15px; + overflow:auto; + text-align:left; + line-height:1.4em; +} + +#TB_ajaxContent.TB_modal{ + padding:15px; +} + +#TB_ajaxContent p{ + padding:5px 0px 5px 0px; +} + +#TB_load{ + position: fixed; + display:none; + height:13px; + width:208px; + z-index:103; + top: 50%; + left: 50%; + margin: -6px 0 0 -104px; /* -height/2 0 0 -width/2 */ +} + +* html #TB_load { /* ie6 hack */ +position: absolute; +margin-top: expression(0 - parseInt(this.offsetHeight / 2) + (TBWindowMargin = document.documentElement && document.documentElement.scrollTop || document.body.scrollTop) + 'px'); +} + +#TB_HideSelect{ + z-index:99; + position:fixed; + top: 0; + left: 0; + background-color:#fff; + border:none; + filter:alpha(opacity=0); + -moz-opacity: 0; + opacity: 0; + height:100%; + width:100%; +} + +* html #TB_HideSelect { /* ie6 hack */ + position: absolute; + height: expression(document.body.scrollHeight > document.body.offsetHeight ? document.body.scrollHeight : document.body.offsetHeight + 'px'); +} + +#TB_iframeContent{ + clear:both; + border:none; + margin-bottom:-1px; + margin-top:1px; + _margin-bottom:1px; +} \ No newline at end of file diff --git a/wp-content/themes/carrington-blog/carrington-core/lightbox/img/blank.gif b/wp-content/themes/carrington-blog/carrington-core/lightbox/img/blank.gif new file mode 100644 index 0000000000000000000000000000000000000000..1d11fa9ada9e93505b3d736acb204083f45d5fbf GIT binary patch literal 43 ucmZ?wbhEHbWMp7uX!y@?;J^U}1_s5SEQ|~c3=BFT0wlx0#N@)rU=0A%AqP7E literal 0 HcmV?d00001 diff --git a/wp-content/themes/carrington-blog/carrington-core/lightbox/img/loadingAnimation.gif b/wp-content/themes/carrington-blog/carrington-core/lightbox/img/loadingAnimation.gif new file mode 100644 index 0000000000000000000000000000000000000000..82290f48334c81272ff5991962951758137a08ba GIT binary patch literal 5886 zcmZ?wbhEHbyuiTAaD;*3_wV1|zkmPy`Sbht?_a%o_3YWRM~@!eyLa!_ty|ZwUAuJY z(z$czPMtb+^ytxp2M_MuyLac#om;nV-MDe%%9Shs|NqZG2q^yN_Hzvhc6JPKHPSO+ zW@KPsQ2fcl%EchUpaaqias~tIe}$tCL7DS1R;|l<y{|y$d`a$p0cA74^M88SST1RQ zE9zcS<YFQxc`D=bO9!{f&RL>Wu|9LJy}m9nEo*!1`<-jf1l_#x(O9>ht+7||@Ien1 z0e1HC=77q^_D1d+Z_l=l&hDPR{;nAB$sJuiy*&LB0%K;hPmK+j$3Dw*+M@XjxYw-U zTe@M%q`8e8b?hpe*x6WFSlD>E>W*=8@f<vT@bJ;&Cr+I?$U5!9rORyBj^8+Q_5AhA zS8gA>d-|%^@sp2Ou3mWh=GMz&uOHodaOcha_uS78aHv{ICQM_QaL|E=ha=)dfP<qy zr?gSc4~<1G?Yp$J_IL<RbnTSoug#GVdgwMm()Ry6m7NR|j&(~2JH%LSeCjiU+e<^@ zguqozd&VX%-h_mM=UJRv#cXGpya@7lm~B@pV)`<~CA2-xc1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yZ&^{{NBG&y4P>D?{l2| zcI}%^hCPYzkLea>20sewpS)J=&bJMbxr^LeG`bC?_C0^M?CiejJC5#c*ecD(Y@1T@ zzVNkEcl5n?_XI#4W=@PTLe;($q%lI1lLi7IR#UD_>2A$?K4C_a<)aBLF<mlz%U7(l z;aVD?+3IyFYVzF|;@WI+tJ6Mc{NAkV$H~%qe2Iy~(!+^)`<{O<QO>VZsj4Y$QEqDt zE~{v5aOkUVZ<;(|YHz1fxB6_6xgGso6Bns+aEdHeW@XP+=G?eigoTA|bMWS^+f_Gm z?O<Wuypi+39+eeGRkt2m&bj~e!5y0}9#>v*;q<i)r%s>UdsF3-8mHq$_8z6J&rY0Y zQ)Ob}UfIgQ^IqlS=jE$@DF6E6akp7re*uRj^JmdNlRw;d^5Au4NO|G^$hlEe)2C%d zp|V?3{xr@TpVH?$O`4GOU(m(#)Dq`ubNF^_;Sj#UI91(w(xIP0>1Sq2x&PY2X%gpa zYm>?6nq~0f;%whuK3#)`13|VszRWz3<)nRh-KTA*SgK2PJT^uio~EK*mJzVM>P}Uw zO1N&UFvFWoQWLJIH8ZjNe)m&)$IE%F4Wdl8cLW<A=yuB5xy9^AN$H+!%*LS*@$Bh> zncg|`{@h&L!NSIOrb}AXp>eeX<BqnwA>Urx*DihL8FuJfXo&XuZ(n<Ne|t0OSpM>y zwKeHQ+qpuvr|$liQ+o9B+WS}UP5M>#=DPcn*c>sNyAz-7E>2(C74O0|Thqk#M&N<R z-#`Ak6rZ_6zP_tb^FTnRvg9(U#_x(53NDFUsyik%=s8@yU3l8}#vT7a&V+^n$-EBf z7QRZ4@OGI)&I^@p2&gP7*5YDc#4$TIL%2ZY$cr#ui)Sky_t|`Vk<6{gz+epkl)1NK literal 0 HcmV?d00001 diff --git a/wp-content/themes/carrington-blog/carrington-core/lightbox/img/macFFBgHack.png b/wp-content/themes/carrington-blog/carrington-core/lightbox/img/macFFBgHack.png new file mode 100644 index 0000000000000000000000000000000000000000..c6473b324ee1dae1faaacc0826639833f551116c GIT binary patch literal 207 zcmeAS@N?(olHy`uVBq!ia0y~yV2}i14mJh`h9fUqlNlHoSc;uILpV4%IBGajIv5xj zI14-?iy0WWg+Q3`(%rg03=9l1C9V-A!TD(=<%vb942~)JNvR5MnMJAP`9;~q3eLgC zGp@NYGcYiSg48(|r6!hS=I1GdWag$anClyw=^L0wE&tEWz`&s4>EamT(fRhQBO`+W v2ZQ34`sJa~T=njZZ09%b<@17p1MHC(89vJYncvF5z`)??>gTe~DWM4fXgoQB literal 0 HcmV?d00001 diff --git a/wp-content/themes/carrington-blog/carrington-core/lightbox/thickbox.js b/wp-content/themes/carrington-blog/carrington-core/lightbox/thickbox.js new file mode 100644 index 000000000..cfd23b433 --- /dev/null +++ b/wp-content/themes/carrington-blog/carrington-core/lightbox/thickbox.js @@ -0,0 +1,332 @@ +/* + * Thickbox 3.1 - One Box To Rule Them All. + * By Cody Lindley (http://www.codylindley.com) + * Copyright (c) 2007 cody lindley + * Licensed under the MIT License: http://www.opensource.org/licenses/mit-license.php +*/ + +var tb_pathToImage = "images/loadingAnimation.gif"; + +/*!!!!!!!!!!!!!!!!! edit below this line at your own risk !!!!!!!!!!!!!!!!!!!!!!!*/ + +//on page load call tb_init +jQuery(document).ready(function(){ + tb_init('a.thickbox, area.thickbox, input.thickbox');//pass where to apply thickbox + imgLoader = new Image();// preload image + imgLoader.src = tb_pathToImage; +}); + +//add thickbox to href & area elements that have a class of .thickbox +function tb_init(domChunk){ + jQuery(domChunk).click(function(){ + var t = this.title || this.name || null; + var a = this.href || this.alt; + var g = this.rel || false; + tb_show(t,a,g); + this.blur(); + return false; + }); +} + +function tb_show(caption, url, imageGroup) {//function called when the user clicks on a thickbox link + + try { + if (typeof document.body.style.maxHeight === "undefined") {//if IE 6 + jQuery("body","html").css({height: "100%", width: "100%"}); + jQuery("html").css("overflow","hidden"); + if (document.getElementById("TB_HideSelect") === null) {//iframe to hide select elements in ie6 + jQuery("body").append("<iframe id='TB_HideSelect'></iframe><div id='TB_overlay'></div><div id='TB_window'></div>"); + jQuery("#TB_overlay").click(tb_remove); + } + }else{//all others + if(document.getElementById("TB_overlay") === null){ + jQuery("body").append("<div id='TB_overlay'></div><div id='TB_window'></div>"); + jQuery("#TB_overlay").click(tb_remove); + } + } + + if(tb_detectMacXFF()){ + jQuery("#TB_overlay").addClass("TB_overlayMacFFBGHack");//use png overlay so hide flash + }else{ + jQuery("#TB_overlay").addClass("TB_overlayBG");//use background and opacity + } + + if(caption===null){caption="";} + jQuery("body").append("<div id='TB_load'><img src='"+imgLoader.src+"' /></div>");//add loader to the page + jQuery('#TB_load').show();//show loader + + var baseURL; + if(url.indexOf("?")!==-1){ //ff there is a query string involved + baseURL = url.substr(0, url.indexOf("?")); + }else{ + baseURL = url; + } + + var urlString = /\.jpg$|\.jpeg$|\.png$|\.gif$|\.bmp$/; + var urlType = baseURL.toLowerCase().match(urlString); + + if(urlType == '.jpg' || urlType == '.jpeg' || urlType == '.png' || urlType == '.gif' || urlType == '.bmp'){//code to show images + + TB_PrevCaption = ""; + TB_PrevURL = ""; + TB_PrevHTML = ""; + TB_NextCaption = ""; + TB_NextURL = ""; + TB_NextHTML = ""; + TB_imageCount = ""; + TB_FoundURL = false; + if(imageGroup){ + TB_TempArray = jQuery("a[rel="+imageGroup+"]").get(); + for (TB_Counter = 0; ((TB_Counter < TB_TempArray.length) && (TB_NextHTML === "")); TB_Counter++) { + var urlTypeTemp = TB_TempArray[TB_Counter].href.toLowerCase().match(urlString); + if (!(TB_TempArray[TB_Counter].href == url)) { + if (TB_FoundURL) { + TB_NextCaption = TB_TempArray[TB_Counter].title; + TB_NextURL = TB_TempArray[TB_Counter].href; + TB_NextHTML = "<a id='TB_next' href='#'>Next ></a>"; + } else { + TB_PrevCaption = TB_TempArray[TB_Counter].title; + TB_PrevURL = TB_TempArray[TB_Counter].href; + TB_PrevHTML = "<a id='TB_prev' href='#'>< Prev</a>"; + } + } else { + TB_FoundURL = true; + TB_imageCount = "Image " + (TB_Counter + 1) +" of "+ (TB_TempArray.length); + } + } + } + + imgPreloader = new Image(); + imgPreloader.onload = function(){ + imgPreloader.onload = null; + +// preload patch from: http://drupal.org/files/issues/thickbox_preloadimage.patch +prevImg = new Image(); +nextImg = new Image(); +var tb_links = jQuery('a[class="thickbox"]'); +var i = -1; +tb_links.each(function(n) { if (this.href == imgPreloader.src) { i = n; } }); +if (i != -1) { + if (i > 0) { prevImg.src = tb_links[i-1].href; } + if (i+1 < tb_links.length) { nextImg.src = tb_links[i+1].href; } +} + + + // Resizing large images - orginal by Christian Montoya edited by me. + var pagesize = tb_getPageSize(); + var x = pagesize[0] - 150; + var y = pagesize[1] - 170; + var imageWidth = imgPreloader.width; + var imageHeight = imgPreloader.height; + if (imageWidth > x) { + imageHeight = imageHeight * (x / imageWidth); + imageWidth = x; + if (imageHeight > y) { + imageWidth = imageWidth * (y / imageHeight); + imageHeight = y; + } + } else if (imageHeight > y) { + imageWidth = imageWidth * (y / imageHeight); + imageHeight = y; + if (imageWidth > x) { + imageHeight = imageHeight * (x / imageWidth); + imageWidth = x; + } + } + // End Resizing + + + /* TODO: auto-calculate heights based on jQuery.height() of elements */ + TB_WIDTH = imageWidth + 30; + TB_HEIGHT = imageHeight + 130; + jQuery("#TB_window").append("<div id='TB_title'><div id='TB_closeAjaxWindow'><a href='#' id='TB_closeWindowButton' title='Close'>close</a> or Esc Key</div></div><div id='TB_ImageWrapper' style='height:"+imageHeight+"px;width:"+imageWidth+"px;'><div id='TB_ImageHoverNav'>"+TB_PrevHTML+TB_NextHTML+"</div><img id='TB_Image' src='"+url+"' width='"+imageWidth+"' height='"+imageHeight+"' alt='"+caption+"'/></div><div id='TB_caption'>"+caption+"<div id='TB_secondLine'>" + TB_imageCount + "</div></div>"); + jQuery("#TB_closeWindowButton").click(tb_remove); + + if (!(TB_PrevHTML === "")) { + function goPrev(){ + if(jQuery(document).unbind("click",goPrev)){jQuery(document).unbind("click",goPrev);} + jQuery("#TB_window").remove(); + jQuery("body").append("<div id='TB_window'></div>"); + tb_show(TB_PrevCaption, TB_PrevURL, imageGroup); + return false; + } + jQuery("#TB_prev").click(goPrev); + } + + if (!(TB_NextHTML === "")) { + function goNext(){ + jQuery("#TB_window").remove(); + jQuery("body").append("<div id='TB_window'></div>"); + tb_show(TB_NextCaption, TB_NextURL, imageGroup); + return false; + } + jQuery("#TB_next").click(goNext); + + } + + document.onkeydown = function(e){ + if (e == null) { // ie + keycode = event.keyCode; + } else { // mozilla + keycode = e.which; + } + if(keycode == 27){ // close + tb_remove(); + } else if(keycode == 190 || keycode == 39){ // display next image + if(!(TB_NextHTML == "")){ + document.onkeydown = ""; + goNext(); + } + } else if(keycode == 188 || keycode == 37){ // display previous image + if(!(TB_PrevHTML == "")){ + document.onkeydown = ""; + goPrev(); + } + } + }; + + tb_position(); + jQuery("#TB_load").remove(); + jQuery("#TB_ImageOff").click(tb_remove); + jQuery("#TB_window").css({display:"block"}); //for safari using css instead of show + }; + + imgPreloader.src = url; + }else{//code to show html + + var queryString = url.replace(/^[^\?]+\??/,''); + var params = tb_parseQuery( queryString ); + + TB_WIDTH = (params['width']*1) + 30 || 630; //defaults to 630 if no paramaters were added to URL + TB_HEIGHT = (params['height']*1) + 40 || 440; //defaults to 440 if no paramaters were added to URL + ajaxContentW = TB_WIDTH - 30; + ajaxContentH = TB_HEIGHT - 45; + + if(url.indexOf('TB_iframe') != -1){// either iframe or ajax window + urlNoQuery = url.split('TB_'); + jQuery("#TB_iframeContent").remove(); + if(params['modal'] != "true"){//iframe no modal + jQuery("#TB_window").append("<div id='TB_title'><div id='TB_ajaxWindowTitle'>"+caption+"</div><div id='TB_closeAjaxWindow'><a href='#' id='TB_closeWindowButton' title='Close'>close</a> or Esc Key</div></div><iframe frameborder='0' hspace='0' src='"+urlNoQuery[0]+"' id='TB_iframeContent' name='TB_iframeContent"+Math.round(Math.random()*1000)+"' onload='tb_showIframe()' style='width:"+(ajaxContentW + 29)+"px;height:"+(ajaxContentH + 17)+"px;' > </iframe>"); + }else{//iframe modal + jQuery("#TB_overlay").unbind(); + jQuery("#TB_window").append("<iframe frameborder='0' hspace='0' src='"+urlNoQuery[0]+"' id='TB_iframeContent' name='TB_iframeContent"+Math.round(Math.random()*1000)+"' onload='tb_showIframe()' style='width:"+(ajaxContentW + 29)+"px;height:"+(ajaxContentH + 17)+"px;'> </iframe>"); + } + }else{// not an iframe, ajax + if(jQuery("#TB_window").css("display") != "block"){ + if(params['modal'] != "true"){//ajax no modal + jQuery("#TB_window").append("<div id='TB_title'><div id='TB_ajaxWindowTitle'>"+caption+"</div><div id='TB_closeAjaxWindow'><a href='#' id='TB_closeWindowButton'>close</a> or Esc Key</div></div><div id='TB_ajaxContent' style='width:"+ajaxContentW+"px;height:"+ajaxContentH+"px'></div>"); + }else{//ajax modal + jQuery("#TB_overlay").unbind(); + jQuery("#TB_window").append("<div id='TB_ajaxContent' class='TB_modal' style='width:"+ajaxContentW+"px;height:"+ajaxContentH+"px;'></div>"); + } + }else{//this means the window is already up, we are just loading new content via ajax + jQuery("#TB_ajaxContent")[0].style.width = ajaxContentW +"px"; + jQuery("#TB_ajaxContent")[0].style.height = ajaxContentH +"px"; + jQuery("#TB_ajaxContent")[0].scrollTop = 0; + jQuery("#TB_ajaxWindowTitle").html(caption); + } + } + + jQuery("#TB_closeWindowButton").click(tb_remove); + + if(url.indexOf('TB_inline') != -1){ + jQuery("#TB_ajaxContent").append(jQuery('#' + params['inlineId']).children()); + jQuery("#TB_window").unload(function () { + jQuery('#' + params['inlineId']).append( jQuery("#TB_ajaxContent").children() ); // move elements back when you're finished + }); + tb_position(); + jQuery("#TB_load").remove(); + jQuery("#TB_window").css({display:"block"}); + }else if(url.indexOf('TB_iframe') != -1){ + tb_position(); + if($.browser.safari){//safari needs help because it will not fire iframe onload + jQuery("#TB_load").remove(); + jQuery("#TB_window").css({display:"block"}); + } + }else{ + jQuery("#TB_ajaxContent").load(url += "&random=" + (new Date().getTime()),function(){//to do a post change this load method + tb_position(); + jQuery("#TB_load").remove(); + tb_init("#TB_ajaxContent a.thickbox"); + jQuery("#TB_window").css({display:"block"}); + }); + } + + } + + if(!params['modal']){ + document.onkeyup = function(e){ + if (e == null) { // ie + keycode = event.keyCode; + } else { // mozilla + keycode = e.which; + } + if(keycode == 27){ // close + tb_remove(); + } + }; + } + + } catch(e) { + //nothing here + } +} + +//helper functions below +function tb_showIframe(){ + jQuery("#TB_load").remove(); + jQuery("#TB_window").css({display:"block"}); +} + +function tb_remove() { + jQuery("#TB_imageOff").unbind("click"); + jQuery("#TB_closeWindowButton").unbind("click"); + jQuery("#TB_window").fadeOut("fast",function(){jQuery('#TB_window,#TB_overlay,#TB_HideSelect').trigger("unload").unbind().remove();}); + jQuery("#TB_load").remove(); + if (typeof document.body.style.maxHeight == "undefined") {//if IE 6 + jQuery("body","html").css({height: "auto", width: "auto"}); + jQuery("html").css("overflow",""); + } + document.onkeydown = ""; + document.onkeyup = ""; + return false; +} + +function tb_position() { +jQuery("#TB_window").css({marginLeft: '-' + parseInt((TB_WIDTH / 2),10) + 'px', width: TB_WIDTH + 'px'}); + if ( !(jQuery.browser.msie && jQuery.browser.version < 7)) { // take away IE6 + jQuery("#TB_window").css({marginTop: '-' + parseInt((TB_HEIGHT / 2),10) + 'px'}); + } +} + +function tb_parseQuery ( query ) { + var Params = {}; + if ( ! query ) {return Params;}// return empty object + var Pairs = query.split(/[;&]/); + for ( var i = 0; i < Pairs.length; i++ ) { + var KeyVal = Pairs[i].split('='); + if ( ! KeyVal || KeyVal.length != 2 ) {continue;} + var key = unescape( KeyVal[0] ); + var val = unescape( KeyVal[1] ); + val = val.replace(/\+/g, ' '); + Params[key] = val; + } + return Params; +} + +function tb_getPageSize(){ + var de = document.documentElement; + var w = window.innerWidth || self.innerWidth || (de&&de.clientWidth) || document.body.clientWidth; + var h = window.innerHeight || self.innerHeight || (de&&de.clientHeight) || document.body.clientHeight; + arrayPageSize = [w,h]; + return arrayPageSize; +} + +function tb_detectMacXFF() { + var userAgent = navigator.userAgent.toLowerCase(); + if (userAgent.indexOf('mac') != -1 && userAgent.indexOf('firefox')!=-1) { + return true; + } +} + + diff --git a/wp-content/themes/carrington-blog/carrington-core/templates.php b/wp-content/themes/carrington-blog/carrington-core/templates.php index f0c4f2823..1fb0139f0 100644 --- a/wp-content/themes/carrington-blog/carrington-core/templates.php +++ b/wp-content/themes/carrington-blog/carrington-core/templates.php @@ -1,9 +1,9 @@ <?php -// This file is part of the Carrington Core Platform for WordPress -// http://crowdfavorite.com/wordpress/carrington-core/ +// This file is part of the Carrington Theme Framework for WordPress +// http://carringtontheme.com // -// Copyright (c) 2008-2012 Crowd Favorite, Ltd. All rights reserved. +// Copyright (c) 2008-2010 Crowd Favorite, Ltd. All rights reserved. // http://crowdfavorite.com // // Released under the GPL license @@ -17,12 +17,6 @@ if (__FILE__ == $_SERVER['SCRIPT_FILENAME']) { die(); } -/** - * Includes the appropriate file for a page - * - * @param string [$file] filename of the page template - * -**/ function cfct_page($file = '') { if (empty($file)) { $file = cfct_default_file('pages'); @@ -30,170 +24,61 @@ function cfct_page($file = '') { cfct_template_file('pages', $file); } -/** - * Includes the appropriate template file for a header - * -**/ function cfct_header() { $file = cfct_choose_general_template('header'); cfct_template_file('header', $file); } -/** - * Includes the appropriate template file for a footer - * -**/ function cfct_footer() { $file = cfct_choose_general_template('footer'); cfct_template_file('footer', $file); } -/** - * Includes the appropriate template file for a sidebar - * -**/ function cfct_sidebar() { $file = cfct_choose_general_template('sidebar'); cfct_template_file('sidebar', $file); } -/** - * Includes the appropriate template file for a header - * -**/ function cfct_posts() { $file = cfct_choose_general_template('posts'); cfct_template_file('posts', $file); } -/** - * Includes the appropriate template file for a single page - * -**/ function cfct_single() { $file = cfct_choose_general_template('single'); cfct_template_file('single', $file); } -/** - * Includes the appropriate template file for an attachement - * -**/ function cfct_attachment() { $file = cfct_choose_general_template('attachment'); cfct_template_file('attachment', $file); } -/** - * Includes the appropriate template file for the loop - * -**/ function cfct_loop() { $file = cfct_choose_general_template('loop'); cfct_template_file('loop', $file); } -/** - * Includes the appropriate template file for the content - * -**/ function cfct_content() { $file = cfct_choose_content_template(); cfct_template_file('content', $file); } -/** - * Chooses the appropriate template file for the content in a feed and returns that content - * -**/ -function cfct_content_feed($content) { - if (is_feed()) { -// find template - $file = cfct_choose_content_template_feed(); - if ($file) { -// load template - $content = cfct_template_content('content', $file); - } - } - $content = str_replace(']]>', ']]>', $content); - return $content; -} -add_filter('the_content_feed', 'cfct_content_feed'); - -/** - * Output feed content without infinite loop - * -**/ -function cfct_the_content_feed() { - remove_filter('the_content_feed', 'cfct_content_feed'); - the_content_feed('rss2'); - add_filter('the_content_feed', 'cfct_content_feed'); -} - -/** - * Includes the appropriate template file for the excerpt - * -**/ function cfct_excerpt() { $file = cfct_choose_content_template('excerpt'); cfct_template_file('excerpt', $file); } -/** - * Chooses the appropriate template file for the excerpt in a feed and returns that content - * -**/ -function cfct_excerpt_feed($content) { - if (is_feed()) { -// find template - $file = cfct_choose_content_template_feed('excerpt'); - if ($file) { -// load template - $content = cfct_template_content('excerpt', $file); - } - } - return $content; -} -add_filter('the_excerpt_rss', 'cfct_excerpt_feed'); - -/** - * Output feed content without infinite loop - * -**/ -function cfct_the_excerpt_feed() { - remove_filter('the_excerpt_rss', 'cfct_excerpt_feed'); - the_excerpt_rss(); - add_filter('the_excerpt_rss', 'cfct_excerpt_feed'); -} - -/** - * Includes the appropriate template file for comments - * -**/ function cfct_comments() { $file = cfct_choose_general_template('comments'); cfct_template_file('comments', $file); } -/** - * Includes the appropriate template file for a single comment - * - * @param $data not used - * -**/ function cfct_comment($data = null) { $file = cfct_choose_comment_template(); cfct_template_file('comment', $file, $data); } -/** - * Includes the appropriate template file for a threaded comment - * - * @param array $comment The comment currently being processed - * @param array $args Custom arguments - * @param int $depth The depth of a comment - * -**/ function cfct_threaded_comment($comment, $args = array(), $depth) { $GLOBALS['comment'] = $comment; $data = array( @@ -203,31 +88,18 @@ function cfct_threaded_comment($comment, $args = array(), $depth) { cfct_template_file('comments', 'threaded', $data); } -/** - * Includes the appropriate template file for a form - * -**/ function cfct_form($name = '') { $parts = cfct_leading_dir($name); cfct_template_file('forms/'.$parts['dir'], $parts['file']); } -/** - * Includes the appropriate template file based on a string - * - * @param string $name The name of the string corresponding to the filename in /misc directory - * -**/ function cfct_misc($name = '') { $parts = cfct_leading_dir($name); cfct_template_file('misc/'.$parts['dir'], $parts['file']); } -/** - * Includes the appropriate template file for an error - * -**/ function cfct_error($name = '') { cfct_template_file('error', $name); } +?> \ No newline at end of file diff --git a/wp-content/themes/carrington-blog/carrington-core/utility.php b/wp-content/themes/carrington-blog/carrington-core/utility.php index 3e90ed5c6..5482cf2fb 100644 --- a/wp-content/themes/carrington-blog/carrington-core/utility.php +++ b/wp-content/themes/carrington-blog/carrington-core/utility.php @@ -1,9 +1,9 @@ <?php -// This file is part of the Carrington Core Platform for WordPress -// http://crowdfavorite.com/wordpress/carrington-core/ +// This file is part of the Carrington Theme Framework for WordPress +// http://carringtontheme.com // -// Copyright (c) 2008-2012 Crowd Favorite, Ltd. All rights reserved. +// Copyright (c) 2008-2010 Crowd Favorite, Ltd. All rights reserved. // http://crowdfavorite.com // // Released under the GPL license @@ -17,12 +17,6 @@ if (__FILE__ == $_SERVER['SCRIPT_FILENAME']) { die(); } -/** - * Die with custom error page if it exists - * - * @param string $str String to die with if no file found - * -**/ function cfct_die($str = '') { if (!empty($str)) { if (file_exists(CFCT_PATH.'error/exit.php')) { @@ -35,12 +29,6 @@ function cfct_die($str = '') { } } -/** - * Display custom banners for alerts - * - * @param string $str String to display if no banner file found - * -**/ function cfct_banner($str = '') { if (!empty($str)) { if (file_exists(CFCT_PATH.'misc/banner.php')) { @@ -52,49 +40,20 @@ function cfct_banner($str = '') { } } -/** - * Get a Carrington Framework option, load the default otherwise - * - * @param string $name Name of the option to retrieve - * @return mixed Value of the option - * -**/ function cfct_get_option($name) { $defaults = array( - cfct_option_name('login_link_enabled') => 'yes', - cfct_option_name('copyright') => sprintf(__('Copyright © %s · %s', 'carrington'), date('Y'), get_bloginfo('name')), - cfct_option_name('credit') => 'yes', - cfct_option_name('lightbox') => 'yes', - cfct_option_name('header_image') => 0, + 'cfct_credit' => 'yes', + 'cfct_lightbox' => 'yes', + 'cfct_header_image' => 0, ); - $name = cfct_option_name($name); - $defaults = apply_filters('cfct_option_defaults', $defaults); $value = get_option($name); - - - // We want to check for defaults registered using the prefixed and unprefixed versions of the option name. - if ($value === false) { - $prefix = cfct_get_option_prefix(); - $basname = substr($name, strlen($prefix) + 1, -1); - - if (isset($defaults[$name])) { - $value = $defaults[$name]; - } - else if (isset($basename) && isset($defaults[$basename])) { - $value = $defaults[$basename]; - } - } - if ($name == cfct_option_name('copyright')) { - $value = str_replace('%Y', date('Y'), $value); + if ($value == '' && isset($defaults[$name])) { + $value = $defaults[$name]; } return $value; } -/** - * Load theme plugins - * -**/ function cfct_load_plugins() { $files = cfct_files(CFCT_PATH.'plugins'); if (count($files)) { @@ -110,26 +69,12 @@ function cfct_load_plugins() { } } -/** - * Return the default file to use for a given directory - * - * @param string $dir Directory to get the default file for - * @return string Filename pertaining to the default file - * -**/ function cfct_default_file($dir) { $fancy = $dir.'-default.php'; file_exists(CFCT_PATH.$dir.'/'.$fancy) ? $default = $fancy : $default = 'default.php'; return $default; } -/** - * Return the context of the current page - * - * @return string The context of the current page - * -**/ - function cfct_context() { $context = 'home'; if (is_home()) { @@ -147,9 +92,6 @@ function cfct_context() { else if (is_tag()) { $context = 'tag'; } - else if (is_tax()) { - $context = 'taxonomy'; - } else if (is_author()) { $context = 'author'; } @@ -170,12 +112,10 @@ function cfct_context() { } /** - * Get the filename for a given directory, type and keys - * - * @param string $dir Folder name of file - * @param string $type File name of file - * @param array $keys Keys that could be used for additional filename params - * @return mixed Path to the file, false if file does not exist + * @param $template = folder name of file + * @param $type = file name of file + * @param $keys = keys that could be used for additional filename params + * returns false if file does not exist * */ function cfct_filename($dir, $type = 'default', $keys = array()) { @@ -232,18 +172,6 @@ function cfct_filename($dir, $type = 'default', $keys = array()) { $file = 'parent-'.$keys[0]; } break; - case 'taxonomy': - switch (count($keys)) { - case 1: - $file = 'tax-'.$keys[0]; - break; - case 2: - $file = 'tax-'.$keys[0].'-'.$keys[1]; - break; - default: - break; - } - break; default: // handles page, etc. $file = $type; @@ -261,7 +189,6 @@ function cfct_filename($dir, $type = 'default', $keys = array()) { case 'author': case 'category': case 'tag': - case 'taxonomy': // child theme path $path = STYLESHEETPATH.'/'.$dir.'/archive.php'; if (!file_exists($path)) { @@ -283,13 +210,6 @@ function cfct_filename($dir, $type = 'default', $keys = array()) { return apply_filters('cfct_filename', $path); } -/** - * Include a specific file based on context, directory and keys - * - * @param string $dir - * @param array $keys Keys used to help build the filename - * -**/ function cfct_template($dir, $keys = array()) { $context = cfct_context(); $file = cfct_filename($dir, $context, $keys); @@ -301,74 +221,30 @@ function cfct_template($dir, $keys = array()) { } } -/** - * Include a specific file based on directory and filename - * - * @param string $dir Directory the file will be in - * @param string $file Filename - * @param array $data pass in data to be extracted for use by the template - * -**/ -function cfct_template_file($dir, $file, $data = array()) { - // bring in expected globals so that templates don't need to bring them in - // added in version 3.4 - can be overridden via filter - $global_vars = apply_filters('cfct_template_file_globals', array('posts', 'post', 'wp_did_header', 'wp_did_template_redirect', 'wp_query', 'wp_rewrite', 'wpdb', 'wp_version', 'wp', 'id', 'comment', 'user_ID')); - if (is_array($global_vars)) { - foreach ($global_vars as $global_var) { - global $$global_var; - } - } +function cfct_template_file($dir, $file, $data = null) { $path = ''; if (!empty($file)) { $file = basename($file, '.php'); - /* Check for file in the child theme first - var name is deliberately funny. Avoids inadvertantly - overwriting path variable with extract() below. */ - $_cfct_filepath = STYLESHEETPATH.'/'.$dir.'/'.$file.'.php'; - if (!file_exists($_cfct_filepath)) { - $_cfct_filepath = CFCT_PATH.$dir.'/'.$file.'.php'; + // child theme support + $path = STYLESHEETPATH.'/'.$dir.'/'.$file.'.php'; + if (!file_exists($path)) { + $path = CFCT_PATH.$dir.'/'.$file.'.php'; } } - if (file_exists($_cfct_filepath)) { - /* Extract $data as late as possible, so we don't accidentally overwrite - local function vars */ - extract($data); - include($_cfct_filepath); + if (file_exists($path)) { + include($path); } else { cfct_die('Error loading '.$file.' '.__LINE__); } } -/** - * Include a specific file based on directory and filename and return the output - * - * @param string $dir Directory the file will be in - * @param string $file Filename - * @param array $data pass in data to be extracted for use by the template - * -**/ -function cfct_template_content($dir, $file, $data = array()) { - ob_start(); - cfct_template_file($dir, $file, $data); - return ob_get_clean(); -} - -/** - * Gets the proper filename (path) to use in displaying a template - * - * @param string $dir Directory to use/search in - * @return string Path to the file - * -**/ function cfct_choose_general_template($dir) { $exec_order = array( 'author', 'role', 'category', - 'taxonomy', 'tag', - 'type', 'single', 'default' ); @@ -388,14 +264,6 @@ function cfct_choose_general_template($dir) { return apply_filters('cfct_choose_general_template', $filename, $dir); } -/** - * Gets the proper filename (path) to use for displaying a page based on an author's name - * - * @param string $dir Directory to use for selecting the template file - * @param array $files A list of files to loop through - * @return mixed Path to the file, false if no file exists - * -**/ function cfct_choose_general_template_author($dir, $files) { $files = cfct_author_templates($dir, $files); if (count($files)) { @@ -413,16 +281,8 @@ function cfct_choose_general_template_author($dir, $files) { return false; } -/** - * Gets the proper filename (path) to use for displaying a page based on a category's slug - * - * @param string $dir Directory to use for selecting the template file - * @param array $files A list of files to loop through - * @return mixed Path to the file, false if no file exists - * -**/ function cfct_choose_general_template_category($dir, $files) { - $files = cfct_cat_templates($dir, $files); + $files = cfct_cat_templates($dir, $files); if (count($files)) { global $cat; $slug = cfct_cat_id_to_slug($cat); @@ -434,35 +294,6 @@ function cfct_choose_general_template_category($dir, $files) { return false; } -/** - * Gets the proper filename (path) to use for displaying a page based on a custom taxonomy and a slug within that taxonomy - * - * @param string $dir Directory to use for selecting the template file - * @param array $files A list of files to loop through - * @return mixed Path to the file, false if no file exists - * -**/ -function cfct_choose_general_template_taxonomy($dir, $files) { - $files = cfct_tax_templates($dir, $files); - if (count($files)) { - $tax = get_query_var('taxonomy'); - $term = get_term_by('slug', get_query_var('term'), get_query_var('taxonomy')); - if (!empty($term) && in_array('tax-'.$tax.'-'.$term->slug.'.php', $files)) { - $keys = array($tax, $term->slug); - return cfct_filename($dir, 'taxonomy', $keys); - } - } - return false; -} - -/** - * Gets the proper filename (path) to use for displaying a page based on a tag slug - * - * @param string $dir Directory to use for selecting the template file - * @param array $files A list of files to loop through - * @return mixed Path to the file, false if no file exists - * -**/ function cfct_choose_general_template_tag($dir, $files) { $files = cfct_tag_templates($dir, $files); if (count($files)) { @@ -475,34 +306,6 @@ function cfct_choose_general_template_tag($dir, $files) { return false; } -/** - * Gets the proper filename (path) to use for displaying a page based on custom post type - * - * @param string $dir Directory to use for selecting the template file - * @param array $files A list of files to loop through - * @return mixed Path to the file, false if no file exists - * -**/ -function cfct_choose_general_template_type($dir, $files) { - $files = cfct_type_templates($dir, $files); - if (count($files)) { - $type = get_query_var('post_type'); - $file = 'type-'.$type.'.php'; - if (in_array($file, $files)) { - return $file; - } - } - return false; -} - -/** - * Gets the proper filename (path) to use for displaying a page based on a user's role - * - * @param string $dir Directory to use for selecting the template file - * @param array $files A list of files to loop through - * @return mixed Path to the file, false if no file exists - * -**/ function cfct_choose_general_template_role($dir, $files) { $files = cfct_role_templates($dir, $files); if (count($files)) { @@ -522,14 +325,6 @@ function cfct_choose_general_template_role($dir, $files) { return false; } -/** - * Gets the proper filename (path) to use for displaying a page based on whether or not it is a single page and its general context - * - * @param string $dir Directory to use for selecting the template file - * @param array $files A list of files to loop through - * @return mixed Path to the file, false if no file exists - * -**/ function cfct_choose_general_template_single($dir, $files) { if (cfct_context() == 'single') { $files = cfct_single_templates($dir, $files); @@ -554,45 +349,21 @@ function cfct_choose_general_template_single($dir, $files) { return false; } -/** - * Gets the proper filename (path) to use for displaying a default page based on context - * - * @param string $dir Directory to use for selecting the template file - * @param array $files A list of files to loop through - * @return mixed path to the file, false if no file exists - * -**/ function cfct_choose_general_template_default($dir, $files) { $context = cfct_context(); - $keys = array(); - if ($context == 'taxonomy') { - $keys = array(get_query_var('taxonomy')); - } - return cfct_filename($dir, $context, $keys); + return cfct_filename($dir, $context); } -/** - * Chooses which template to display for the single context - * - * @param array $files A list of files to search through to find the correct template - * @param string $filter Used in filtering the filename - * @param string $dir The directory to search for matching files in - * @return mixed path to the file, false if no file exists - * -**/ -function cfct_choose_single_template($files = array(), $filter = '*', $dir = '') { +function cfct_choose_single_template($files = array(), $filter = '*') { // must be called within the_loop - cfct_choose_general_template_single() approximates a loop for this reason. $exec_order = array( 'author', 'meta', - 'format', 'category', - 'taxonomy', 'type', 'role', 'tag', 'parent', // for pages - 'default', ); $exec_order = apply_filters('cfct_single_match_order', $exec_order); $filename = false; @@ -602,7 +373,7 @@ function cfct_choose_single_template($files = array(), $filter = '*', $dir = '') } if (function_exists($func_name)) { $filename = $func_name($dir, $files, $filter); - if ($filename !== false) { + if ($filename != false) { break; } } @@ -610,17 +381,8 @@ function cfct_choose_single_template($files = array(), $filter = '*', $dir = '') return apply_filters('cfct_choose_single_template', $filename); } - /** - * Chooses which template to display for the single context based on custom post type - * - * @param string $dir Directory to search through for files - * @param array $files A list of files to search through to find the correct template - * @param string $filter Used in filtering the filename - * @return mixed path to the file, false if no file exists - * -**/ function cfct_choose_single_template_type($dir, $files, $filter) { - $type_files = cfct_type_templates($dir, $files, $filter); + $type_files = cfct_type_templates('', $files); if (count($type_files)) { global $post; $file = cfct_filename_filter('type-'.$post->post_type.'.php', $filter); @@ -631,19 +393,10 @@ function cfct_choose_single_template_type($dir, $files, $filter) { return false; } -/** - * Chooses which template to display for the single context based on author login - * - * @param string $dir Directory to use for selecting the template file - * @param array $files A list of files to search through to find the correct template - * @param string $filter Used in filtering the filename - * @return mixed Path to the file, false if no file exists - * -**/ function cfct_choose_single_template_author($dir, $files, $filter) { - $author_files = cfct_author_templates($dir, $files, $filter); + $author_files = cfct_author_templates('', $files); if (count($author_files)) { - $author = get_the_author_meta('login'); + $author = get_the_author_login(); $file = cfct_filename_filter('author-'.$author.'.php', $filter); if (in_array($file, $author_files)) { return $file; @@ -652,18 +405,9 @@ function cfct_choose_single_template_author($dir, $files, $filter) { return false; } -/** - * Chooses which template to display for the single context based on meta information - * - * @param string $dir Directory to use for selecting the template file - * @param array $files A list of files to search through to find the correct template - * @param string $filter Used in filtering the filename - * @return mixed Path to the file, false if no file exists - * -**/ function cfct_choose_single_template_meta($dir, $files, $filter) { global $post; - $meta_files = cfct_meta_templates('', $files, $filter); + $meta_files = cfct_meta_templates('', $files); if (count($meta_files)) { $meta = get_post_custom($post->ID); if (count($meta)) { @@ -689,42 +433,11 @@ function cfct_choose_single_template_meta($dir, $files, $filter) { return false; } -/** - * Chooses which template to display for the single context based on post format - * - * @param string $dir Directory to use for selecting the template file - * @param array $files A list of files to search through to find the correct template - * @param string $filter Used in filtering the filename - * @return mixed Path to the file, false if no file exists - * -**/ -function cfct_choose_single_template_format($dir, $files, $filter) { - global $post; - $format_files = cfct_format_templates($dir, $files, $filter); - if (count($format_files)) { - $post_format = get_post_format($post->ID); - foreach ($format_files as $file) { - if (cfct_format_filename_to_format($file) == $post_format) { - return cfct_filename_filter($file, $filter); - } - } - } - return false; -} - -/** - * Chooses which template to display for the single context based on category slug - * - * @param string $dir Directory to use for selecting the template file - * @param array $files A list of files to search through to find the correct template - * @param string $filter Used in filtering the filename - * @return mixed Path to the file, false if no file exists - * -**/ function cfct_choose_single_template_category($dir, $files, $filter) { - $cat_files = cfct_cat_templates($dir, $files, $filter); + $cat_files = cfct_cat_templates($type, $files); if (count($cat_files)) { foreach ($cat_files as $file) { + $file = cfct_filename_filter($file, $filter); $cat_id = cfct_cat_filename_to_id($file); if (in_category($cat_id)) { return $file; @@ -734,17 +447,8 @@ function cfct_choose_single_template_category($dir, $files, $filter) { return false; } -/** - * Chooses which template to display for the single context based on user role - * - * @param string $dir Directory to use for selecting the template file - * @param array $files A list of files to search through to find the correct template - * @param string $filter Used in filtering the filename - * @return mixed Path to the file, false if no file exists - * -**/ function cfct_choose_single_template_role($dir, $files, $filter) { - $role_files = cfct_role_templates($dir, $files, $filter); + $role_files = cfct_role_templates($type, $files); if (count($role_files)) { $user = new WP_User(get_the_author_meta('ID')); if (count($user->roles)) { @@ -761,50 +465,9 @@ function cfct_choose_single_template_role($dir, $files, $filter) { return false; } -/** - * Chooses which template to display for the single context based on taxonomy name and slug within that taxonomy - * - * @param string $dir Directory to use for selecting the template file - * @param array $files A list of files to search through to find the correct template - * @param string $filter used in filtering the filename - * @return mixed path to the file, false if no file exists - * -**/ -function cfct_choose_single_template_taxonomy($dir, $files, $filter) { - global $post; - - $tax_files = cfct_tax_templates($dir, $files, $filter); - if (count($tax_files)) { - foreach ($tax_files as $file) { - $file = cfct_filename_filter($file, $filter); - $tax = cfct_tax_filename_to_tax_name($file); - $file_slug = cfct_tax_filename_to_slug($file); - $terms = wp_get_post_terms($post->ID, $tax); - if (is_array($terms) && count($terms)) { - foreach ($terms as $term) { - if ($term->taxonomy == $tax && $term->slug == $file_slug) { - return $file; - } - } - } - } - } - return false; -} - -/** - * Chooses which template to display for the single context based - * on post_tag - * - * @param string $dir Directory to use for selecting the template file - * @param array $files A list of files to search through to find the correct template - * @param string $filter Used in filtering the filename - * @return mixed Path to the file, false if no file exists - * -**/ function cfct_choose_single_template_tag($dir, $files, $filter) { global $post; - $tag_files = cfct_tag_templates($dir, $files, $filter); + $tag_files = cfct_tag_templates($type, $files); if (count($tag_files)) { $tags = get_the_tags($post->ID); if (is_array($tags) && count($tags)) { @@ -821,18 +484,9 @@ function cfct_choose_single_template_tag($dir, $files, $filter) { return false; } -/** - * Chooses which template to display for the single context based on a post's parent - * - * @param string $dir Directory to use for selecting the template file - * @param array $files A list of files to search through to find the correct template - * @param string $filter Used in filtering the filename - * @return mixed Path to the file, false if no file exists - * -**/ function cfct_choose_single_template_parent($dir, $files, $filter) { global $post; - $parent_files = cfct_parent_templates($dir, $files, $filter); + $parent_files = cfct_parent_templates($type, $files); if (count($parent_files) && $post->post_parent > 0) { $parent = cfct_post_id_to_slug($post->post_parent); $file = cfct_filename_filter('parent-'.$parent.'.php', $filter); @@ -843,13 +497,6 @@ function cfct_choose_single_template_parent($dir, $files, $filter) { return false; } -/** - * Chooses which template to display for the content context - * - * @param string $content Used in filtering and default if no template file can be found - * @return mixed Path to the file, false if no file exists - * -**/ function cfct_choose_content_template($type = 'content') { $files = cfct_files(CFCT_PATH.$type); $filename = cfct_choose_single_template($files); @@ -862,31 +509,6 @@ function cfct_choose_content_template($type = 'content') { return apply_filters('cfct_choose_content_template', $filename, $type); } -/** - * Handle content template selection for feed requests. Leverages single context with a feed- prefix. - * - * @param string $dir Directory to use for selecting the template file - * @param array $files A list of files to loop through - * @return mixed Path to the file, false if no file exists - * -**/ -function cfct_choose_content_template_feed($type = 'content') { - $files = cfct_files(CFCT_PATH.$type); - $files = cfct_filter_files($files, 'feed-'); - if (count($files)) { - $filename = cfct_choose_single_template($files, 'feed-*'); - return $filename; - } - return false; -} - - -/** - * Chooses which template to display for the comment context - * - * @return mixed Path to the file, false if no file exists - * -**/ function cfct_choose_comment_template() { $exec_order = array( 'ping', @@ -912,13 +534,6 @@ function cfct_choose_comment_template() { return apply_filters('cfct_choose_comment_template', $filename); } -/** - * Chooses which template to display for the comment context based on whether or not the comment is a ping or trackback - * - * @param array $files A list of files to search through to find the correct template - * @return mixed Path to the file, false if no file exists - * -**/ function cfct_choose_comment_template_ping($files) { global $comment; if (in_array('ping.php', $files)) { @@ -932,13 +547,6 @@ function cfct_choose_comment_template_ping($files) { return false; } -/** - * Chooses which template to display for the comment context based on meta data - * - * @param array $files A list of files to search through to find the correct template - * @return mixed Path to the file, false if no file exists - * -**/ function cfct_choose_comment_template_meta($files) { global $comment; $meta_files = cfct_meta_templates('', $files); @@ -967,13 +575,6 @@ function cfct_choose_comment_template_meta($files) { return false; } -/** - * Chooses which template to display for the comment context based on the post author - * - * @param array $files A list of files to search through to find the correct template - * @return mixed Path to the file, false if no file exists - * -**/ function cfct_choose_comment_template_author($files) { global $post, $comment; if (!empty($comment->user_id) && $comment->user_id == $post->post_author && in_array('author.php', $files)) { @@ -982,13 +583,6 @@ function cfct_choose_comment_template_author($files) { return false; } -/** - * Chooses which template to display for the comment context based on the comment author - * - * @param array $files A list of files to search through to find the correct template - * @return mixed Path to the file, false if no file exists - * -**/ function cfct_choose_comment_template_user($files) { global $comment; $files = cfct_comment_templates('user', $files); @@ -1004,13 +598,6 @@ function cfct_choose_comment_template_user($files) { return false; } -/** - * Chooses which template to display for the comment context based on comment author's role - * - * @param array $files A list of files to search through to find the correct template - * @return mixed Path to the file, false if no file exists - * -**/ function cfct_choose_comment_template_role($files) { global $comment; $files = cfct_comment_templates('role', $files); @@ -1030,25 +617,10 @@ function cfct_choose_comment_template_role($files) { return false; } -/** - * Chooses the default template to be used in the comment context - * - * @param array $files A list of files to search through to find the correct template - * @return mixed Path to the file, false if no file exists - * -**/ function cfct_choose_comment_template_default($files) { return cfct_default_file('comment'); } -/** - * Adds to a filename based on a filter string - * - * @param string $filename Filename to filter - * @param string $filter What to add - * @return string The filtered filename - * -**/ function cfct_filename_filter($filename, $filter) { // check for filter already appended if (substr($filename, 0, strlen($filter) - 1) == str_replace('*', '', $filter)) { @@ -1057,13 +629,6 @@ function cfct_filename_filter($filename, $filter) { return str_replace('*', $filename, $filter); } -/** - * Get a list of php files within a given path as well as files in corresponding child themes - * - * @param sting $path Path to the directory to search - * @return array Files within the path directory - * -**/ function cfct_files($path) { $files = apply_filters('cfct_files_'.$path, false); if ($files) { @@ -1095,19 +660,11 @@ function cfct_files($path) { return $files; } -/** - * Filters a list of files based on a prefix - * - * @param array $files A list of files to be filtered - * @param string $prefix A string to search for and filter with in the filenames - * @return array A list of files that contain the prefix - * -**/ function cfct_filter_files($files = array(), $prefix = '') { $matches = array(); if (count($files)) { foreach ($files as $file) { - if (strpos($file, $prefix) === 0) { + if (strpos($file, $prefix) !== false) { $matches[] = $file; } } @@ -1115,167 +672,62 @@ function cfct_filter_files($files = array(), $prefix = '') { return $matches; } -/** - * Get a list of files that match the meta template structure - * - * @param string $dir Directory to search through for files if none are given - * @param array $files A list of files to search through - * @return array List of files that match the meta template structure - * -**/ -function cfct_meta_templates($dir, $files = null, $filter = '*') { +function cfct_meta_templates($dir, $files = null) { if (is_null($files)) { $files = cfct_files(CFCT_PATH.$dir); } - $prefix = str_replace('*', '', $filter).'meta-'; - $matches = cfct_filter_files($files, $prefix); + $matches = cfct_filter_files($files, 'meta-'); return apply_filters('cfct_meta_templates', $matches); } -/** - * Get a list of files that match the category template structure - * - * @param string $dir Directory to search through for files if none are given - * @param array $files A list of files to search through - * @return array List of files that match the category template structure - * -**/ -function cfct_cat_templates($dir, $files = null, $filter = '*') { +function cfct_cat_templates($dir, $files = null) { if (is_null($files)) { $files = cfct_files(CFCT_PATH.$dir); } - $prefix = str_replace('*', '', $filter).'cat-'; - $matches = cfct_filter_files($files, $prefix); + $matches = cfct_filter_files($files, 'cat-'); return apply_filters('cfct_cat_templates', $matches); } -/** - * Get a list of files that match the tag template structure - * - * @param string $dir Directory to search through for files if none are given - * @param array $files A list of files to search through - * @return array List of files that match the tag template structure - * -**/ -function cfct_tag_templates($dir, $files = null, $filter = '*') { +function cfct_tag_templates($dir, $files = null) { if (is_null($files)) { $files = cfct_files(CFCT_PATH.$dir); } - $prefix = str_replace('*', '', $filter).'tag-'; - $matches = cfct_filter_files($files, $prefix); + $matches = cfct_filter_files($files, 'tag-'); return apply_filters('cfct_tag_templates', $matches); } -/** - * Get a list of files that match the custom taxonomy template structure - * - * @param string $dir Directory to search through for files if none are given - * @param array $files A list of files to search through - * @return array List of files that match the custom taxonomy template structure - * -**/ -function cfct_tax_templates($dir, $files = null, $filter = '*') { - if (is_null($files)) { - $files = cfct_files(CFCT_PATH.$dir); - } - $prefix = str_replace('*', '', $filter).'tax-'; - $matches = cfct_filter_files($files, $prefix); - return apply_filters('cfct_tax_templates', $matches); -} - -/** - * Get a list of files that match the post format structure - * - * @param string $dir Directory to search through for files if none are given - * @param array $files A list of files to search through - * @return array List of files that match the post format template structure - * -**/ -function cfct_format_templates($dir, $files = null, $filter = '*') { - if (is_null($files)) { - $files = cfct_files(CFCT_PATH.$dir); - } - $prefix = str_replace('*', '', $filter).'format-'; - $matches = cfct_filter_files($files, $prefix); - return apply_filters('cfct_format_templates', $matches); -} - -/** - * Get a list of files that match the author template structure - * - * @param string $dir Directory to search through for files if none are given - * @param array $files A list of files to search through - * @return array list of files that match the author template structure - * -**/ -function cfct_author_templates($dir, $files = null, $filter = '*') { +function cfct_author_templates($dir, $files = null) { if (is_null($files)) { $files = cfct_files(CFCT_PATH.$dir); } - $prefix = str_replace('*', '', $filter).'author-'; - $matches = cfct_filter_files($files, $prefix); + $matches = cfct_filter_files($files, 'author-'); return apply_filters('cfct_author_templates', $matches); } -/** - * Get a list of files that match the custom post type template structure - * - * @param string $dir Directory to search through for files if none are given - * @param array $files A list of files to search through - * @return array List of files that match the custom post type template structure - * -**/ -function cfct_type_templates($dir, $files = null, $filter = '*') { +function cfct_type_templates($dir, $files = null) { if (is_null($files)) { $files = cfct_files(CFCT_PATH.$dir); } - $prefix = str_replace('*', '', $filter).'type-'; - $matches = cfct_filter_files($files, $prefix); + $matches = cfct_filter_files($files, 'type-'); return apply_filters('cfct_type_templates', $matches); } -/** - * Get a list of files that match the user role template structure - * - * @param string $dir Directory to search through for files if none are given - * @param array $files A list of files to search through - * @return array List of files that match the user role template structure - * -**/ -function cfct_role_templates($dir, $files = null, $filter = '*') { +function cfct_role_templates($dir, $files = null) { if (is_null($files)) { $files = cfct_files(CFCT_PATH.$dir); } - $prefix = str_replace('*', '', $filter).'role-'; - $matches = cfct_filter_files($files, $prefix); + $matches = cfct_filter_files($files, 'role-'); return apply_filters('cfct_role_templates', $matches); } -/** - * Get a list of files that match the post parent template structure - * - * @param string $dir Directory to search through for files if none are given - * @param array $files A list of files to search through - * @return array List of files that match the post parent template structure - * -**/ -function cfct_parent_templates($dir, $files = null, $filter = '*') { +function cfct_parent_templates($dir, $files = null) { if (is_null($files)) { $files = cfct_files(CFCT_PATH.$dir); } - $prefix = str_replace('*', '', $filter).'parent-'; - $matches = cfct_filter_files($files, $prefix); + $matches = cfct_filter_files($files, 'parent-'); return apply_filters('cfct_parent_templates', $matches); } -/** - * Get a list of files that match the single template structure - * - * @param string $dir Directory to search through for files if none are given - * @param array $files A list of files to search through - * @return array List of files that match the single template structure - * -**/ function cfct_single_templates($dir, $files = null) { if (is_null($files)) { $files = cfct_files(CFCT_PATH.$dir); @@ -1284,30 +736,6 @@ function cfct_single_templates($dir, $files = null) { return apply_filters('cfct_single_templates', $matches); } -/** - * Get a list of files from list that should be used in feed consideration - * - * @param string $dir Directory to search through for files if none are given - * @param array $files A list of files to search through - * @return array List of files that match the single template structure - * -**/ -function cfct_feed_templates($dir, $files = null) { - if (is_null($files)) { - $files = cfct_files(CFCT_PATH.$dir); - } - $matches = cfct_filter_files($files, 'feed'); - return apply_filters('cfct_feed_templates', $matches); -} - -/** - * Get a list of files that match the comment template structure for a given type - * - * @param string $type The type of template to search for - * @param array $files A list of files to search through - * @return array List of files that match the comment template structure for a given type - * -**/ function cfct_comment_templates($type, $files = false) { if (!$files) { $files = cfct_files(CFCT_PATH.'comment'); @@ -1324,174 +752,48 @@ function cfct_comment_templates($type, $files = false) { return apply_filters('cfct_comment_templates', $matches); } -/** - * Get the id of a category from the category slug of a filename - * - * @param string $file Filename - * @return int Category id matching the category slug of the filename - * -**/ function cfct_cat_filename_to_id($file) { $cat = cfct_cat_filename_to_slug($file); $cat = get_category_by_slug($cat); return $cat->cat_ID; } -/** - * Get the name of a category from the category slug of a filename - * - * @param string $file Filename - * @return string Category name matching the category slug of the filename - * -**/ function cfct_cat_filename_to_name($file) { $cat = cfct_cat_filename_to_slug($file); $cat = get_category_by_slug($cat); return $cat->name; } -/** - * Get the slug of a category from a filename - * - * @param string $file Filename - * @return string Category slug - * -**/ function cfct_cat_filename_to_slug($file) { - $prefixes = apply_filters('cfct_cat_filename_prefixes', array('feed-cat-', 'single-cat-', 'cat-')); - $suffixes = apply_filters('cfct_cat_filename_suffixes', array('.php')); - return str_replace(array_merge($prefixes, $suffixes), '', $file); + return str_replace(array('single-cat-', 'cat-', '.php'), '', $file); } -/** - * Get the slug of a category from its id - * - * @param int $id Category id - * @return string Category slug - * -**/ function cfct_cat_id_to_slug($id) { $cat = &get_category($id); return $cat->slug; } -/** - * Get the id of a user from their username - * - * @param string $username A user's username - * @return int The id of the user - * -**/ function cfct_username_to_id($username) { - $user = get_user_by('ID', $username); - return (isset($user->ID) ? $user->ID : 0); + return get_profile('ID', $username); } -/** - * Get the slug of a tag from a filename - * - * @param string $file Filename - * @return string Tag slug - * -**/ function cfct_tag_filename_to_name($file) { - $prefixes = apply_filters('cfct_tag_filename_prefixes', array('feed-tag-', 'single-tag-', 'tag-')); - $suffixes = apply_filters('cfct_tag_filename_suffixes', array('.php')); - return str_replace(array_merge($prefixes, $suffixes), '', $file); + return str_replace(array('single-tag-', 'tag-', '.php'), '', $file); } -/** - * Get the author from a filename - * - * @param string $file Filename - * @return string Author - * -**/ function cfct_author_filename_to_name($file) { - $prefixes = apply_filters('cfct_author_filename_prefixes', array('feed-author-', 'single-author-', 'author-')); - $suffixes = apply_filters('cfct_author_filename_suffixes', array('.php')); - return str_replace(array_merge($prefixes, $suffixes), '', $file); + return str_replace(array('single-author-', 'author-', '.php'), '', $file); } -/** - * Get the role from a filename - * - * @param string $file Filename - * @return string Role - * -**/ function cfct_role_filename_to_name($file) { - $prefixes = apply_filters('cfct_role_filename_prefixes', array('feed-role-', 'single-role-', 'role-')); - $suffixes = apply_filters('cfct_role_filename_suffixes', array('.php')); - return str_replace(array_merge($prefixes, $suffixes), '', $file); -} - -/** - * Get the post format from a filename - * - * @param string $file Filename - * @return string Post format - * -**/ -function cfct_format_filename_to_format($file) { - $prefixes = apply_filters('cfct_format_filename_prefixes', array('feed-format-', 'single-format-', 'format-')); - $suffixes = apply_filters('cfct_format_filename_suffixes', array('.php')); - return str_replace(array_merge($prefixes, $suffixes), '', $file); + return str_replace(array('single-role-', 'role-', '.php'), '', $file); } -/** - * Get the taxonomy name from a filename - * - * @param string $file Filename - * @return string Taxonomy name - * -**/ -function cfct_tax_filename_to_tax_name($file) { - $prefixes = apply_filters('cfct_tax_filename_prefixes', array('feed-tax-', 'single-tax-', 'tax-')); - $suffixes = apply_filters('cfct_tax_filename_suffixes', array('.php')); - $tax = str_replace(array_merge($prefixes, $suffixes), '', $file); - $tax = explode('-', $tax); - return $tax[0]; -} - -/** - * Get the slug of a taxonomy from a filename - * - * @param string $file Filename - * @return string Taxonomy slug - * -**/ -function cfct_tax_filename_to_slug($file) { - $prefixes = apply_filters('cfct_tax_filename_prefixes', array('feed-tax-', 'single-tax-', 'tax-')); - $suffixes = apply_filters('cfct_tax_filename_suffixes', array('.php')); - $slug = str_replace(array_merge($prefixes, $suffixes), '', $file); - $slug = explode('-', $slug); - unset($slug[0]); - if (count($slug)) { - return implode('-', $slug); - } - return ''; -} - -/** - * Get the post name from its id - * - * @param int $id A post id - * @return string Post name - * -**/ function cfct_post_id_to_slug($id) { $post = get_post($id); return $post->post_name; } -/** - * Custom formatting for strings - * - * @param string $str A string to be formatted - * @return string Formatted string - * -**/ function cfct_basic_content_formatting($str) { $str = wptexturize($str); $str = convert_smilies($str); @@ -1500,13 +802,6 @@ function cfct_basic_content_formatting($str) { return $str; } -/** - * Get an array with the path to the director of the file as well as the filename - * - * @param string $path A path to a file - * @return array Contains the directory the file is in as well as the filename - * -**/ function cfct_leading_dir($path) { $val = array( 'dir' => '', @@ -1523,70 +818,4 @@ function cfct_leading_dir($path) { return $val; } -/** - * Prevent code from breaking in WP versions < 3.1 - * - * -**/ -if (!function_exists('get_post_format')) { - function get_post_format($post_id) { - return false; - } -} - -/** - * Generate markup for login/logout links - * - * @param string $redirect URL to redirect after the login or logout - * @param string $before Markup to display before - * @param string $after Markup to display after - * @return string Generated login/logout Markup - */ -function cfct_get_loginout($redirect = '', $before = '', $after = '') { - if (cfct_get_option('login_link_enabled') != 'no') { - return $before . wp_loginout($redirect, false) . $after; - } -} - -/** - * Recursively merges two arrays down overwriting values if keys match. - * - * @param array $array_1 Array to merge into - * @param array $array_2 Array in which values are merged from - * - * @return array Merged array - */ -function cfct_array_merge_recursive($array_1, $array_2) { - foreach ($array_2 as $key => $value) { - if (isset($array_1[$key]) && is_array($array_1[$key]) && is_array($value)) { - $array_1[$key] = cfct_array_merge_recursive($array_1[$key], $value); - } - else { - $array_1[$key] = $value; - } - } - - return $array_1; -} - -/** - * Returns the options prefix - */ -function cfct_get_option_prefix() { - return apply_filters('cfct_option_prefix', 'cfct'); -} - -/** - * Prefix options names - */ -function cfct_option_name($name) { - $prefix = cfct_get_option_prefix(); - // If its already prefixed, we don't need to do it again. - if (strpos($name, $prefix.'_') !== 0) { - return $prefix.'_'.$name; - } - else { - return $name; - } -} - +?> \ No newline at end of file diff --git a/wp-content/themes/carrington-blog/comment/README.txt b/wp-content/themes/carrington-blog/comment/README.txt new file mode 100644 index 000000000..9e909e0fd --- /dev/null +++ b/wp-content/themes/carrington-blog/comment/README.txt @@ -0,0 +1,38 @@ +## comment/ + +### Overview + +This directory holds templates for displaying a comment in it's entirety. These templates do not hold the comment loop, or the "Comments" title or the form to allow commenting; they just show a single comment. + +Typically these templates will be brought in to a template in _comments/_, but can also be used to display single comments as needed. + + +## Comment Context + +When choosing a template to use in the Comment Context, the Carrington engine looks at the type of comment and the author of the comment to choose which template to use. + +A "default" template is required, and will be used when there are no other templates that match a given comment. This could be because no other templates have been created, or because the comment in question doesn't match the templates that are available. + +The order in which these conditions are checked defaults to the following: + +1. ping +2. author +3. user +4. meta +5. role +6. default + +however this order can be overridden with a plugin using the `cfct_comment_match_order` hook. + +Once a template match has been found, no other processing is done. + + +### Supported Templates (Comment Context) + +- *comment-default.php* - Used when there are no other templates that match for a given comment. +- *ping.php* - Used if the comment is a pingback or a trackback. +- *author.php* - Used when the author of the post leaves a comment. +- *user-{username}.php* - Used when a user with that username leaves a comment. For example, a template with a file name of _user-jsmith.php_ would be used for a comment by user _jsmith_. Any WordPres username can take the place of {username} in the file name. +- *meta-{key}.php* - Used when there is a custom field for the comment matching the key listed in the file name. This is useful if you want to be able to flag comments as "tweetbacks" or similar, and give those posts some custom treatment. In this example, you could add a custom field of "tweetback" with a value of the URL of the Tweet and it would use a template of <code>meta-tweetback.php</code> if that template exists. The value does not matter in this match. +- *meta-{key}-{value}.php* - Used when there is a custom field for the comment matching the key and value listed in the file name. This is useful if you want to be able to flag comments as "voted" (someone voting the post up or down) or similar, and give those posts some custom treatment. In this example, you could add a custom field of "voted" with a value of "up" or "down" with their comment and it would use a template of <code>meta-voted-up.php</code> or <code>meta-voted-down.php</code> if that template exists. +- *role-{role}.php* - Used when a comment is made by a user with a certain role. For example, a template with a file name of _role-subscriber.php_ would be used for a user with a role of "subscriber" (typical for a registered commentor who is not an author or an admin). Any WordPress role can take the place of {role} in the file name. \ No newline at end of file diff --git a/wp-content/themes/carrington-blog/comments/README.txt b/wp-content/themes/carrington-blog/comments/README.txt new file mode 100644 index 000000000..759362159 --- /dev/null +++ b/wp-content/themes/carrington-blog/comments/README.txt @@ -0,0 +1,44 @@ +## comments/ + +This directory holds templates for displaying the comment loop and the comment form - what is typically called in by WordPress's `comment_template()` function. + +This level of abstraction us useful to be able to load in the comments and new comment form for a post/page via AJAX if desired. + + +## General Context + +When choosing a template to use in the General Context, the Carrington engine looks at the type of request is being fulfilled. It will identify the request as the home page, a category archive, and individual post, etc. + +There is additional checking done for single post requests. All options in the Content Context are supported here with a 'single-' prefix added to the file. See specifics below. + +A "default" template is required, and will be used when there are no other templates that match a given comment. This could be because no other templates have been created, or because the comment in question doesn't match the templates that are available. + +By default, conditions are checked in this order: + +1. author +2. role +3. category +4. tag +5. single +6. default (home, search, archive, 404, etc.) + +This can be altered using the `cfct_general_match_order` hook. + + +### Supported Templates (General Context) + +- *{dirname}-default.php* (or default.php) - Used when there are no other templates that match for a given page/post. +- *archive.php* - Used for date archives or if there are no specific category, author or tag templates. +- *author.php* - Used for author archive lists. +- *author-{username}.php* - Used when the post/page is authored by a specific user. For example, a template with a file name of _author-jsmith.php_ would be used for a post/page by user _jsmith_. Any WordPress username can take the place of {username} in the file name. +- *role-{rolename}.php - Used when the post author has a particular role. This might be the role of _contributor_, _author_, _editor_, etc. and use a file of _role-contributor.php_, _role_author.php_, etc. where the role name takes the place of the {rolename} in the file name. +- *category.php* - Used for category archive lists. +- *cat-{slug}.php* - Used fr displaying a given category. The category is matched by the "slug" - for example a post in category "General" (with a category slug of "general") could use a template of _cat-general.php_. +- *home.php* - Used when on the home page. +- *page.php* - Used for pages that do not match any other contextual templates. +- *search.php* - Used when displaying search results. +- *single.php* - Used for single post pages. +- *single-{content context filenames}.php* - Used for single post pages. +- *tag.php* - Used for tag archive lists. +- *tag-{slug}.php* - Used for displaying a given tag. The tag is matched by the "slug" - for example a post in tag "News" (with a tag slug of "news") could use a template of _tag-news.php_. + diff --git a/wp-content/themes/carrington-blog/comments/comments-default.php b/wp-content/themes/carrington-blog/comments/comments-default.php index 45cbaee10..0788a2189 100644 --- a/wp-content/themes/carrington-blog/comments/comments-default.php +++ b/wp-content/themes/carrington-blog/comments/comments-default.php @@ -53,7 +53,7 @@ if (have_comments() || comments_open()) { echo '<ol class="pinglist commentlist hfeed">', wp_list_comments('type=pings&callback=cfct_threaded_comment'), '</ol>'; } } - comment_form(); + cfct_form('comment'); } ?> \ No newline at end of file diff --git a/wp-content/themes/carrington-blog/content/README.txt b/wp-content/themes/carrington-blog/content/README.txt new file mode 100644 index 000000000..dd43330ea --- /dev/null +++ b/wp-content/themes/carrington-blog/content/README.txt @@ -0,0 +1,43 @@ +## content/ + +This directory holds the templates for displaying a post. Typically this will be the full post with title, meta information (date, categories, tags, author, etc.) and the full output of `the_content()`. + + +## Post Context + +When choosing a template to use in the Post Context, the Carrington engine looks information (author, category, tags, custom fields, etc.) related to the post/page being shown. + +Commonly these templates are included by templates in the _loop/_; but are also useful for bringing in an atomic post representation via AJAX or placing one within another template. + +A "default" template is required, and will be used when there are no other templates that match a given post. This could be because no other templates have been created, or because the post in question doesn't match the templates that are available. + +You can create templates to be used with posts/pages given various conditions. For example, you might want to give all posts in a certain category some specific styling rules. Or perhaps posts with a certain custom field or by a specific author. This is accomplished by creating templates with file names that match these conditions, then placing them in the _content/_ directory. All templates other than _{dirname}-default.php_ are optional. + +The order in which these conditions are checked defaults to the following: + +1. author +2. meta +3. category +4. type +5. role +6. tag +7. parent +8. default + +however this order can be overridden with a plugin using the `cfct_single_match_order` hook. + +Once a template match has been found, no other processing is done. + + +### Supported Templates (Post Context) + +- *{dirname}-default.php* - Used when there are no other templates that match for a given post/page. +- *author-{username}.php* - Used when a user with that username authors a post/page. For example, a template with a file name of <code>author-jsmith.php</code> would be used for a poat/page by user <code>jsmith</code>. Any WordPres username can take the place of {username} in the file name. +- *cat-{slug}.php* - Used when a post is in a given category. The category is matched by the "slug" - for example a post in category "General" (with a category slug of "general") could use a template of <code>cat-general.php</code>. +- *type-{post_type}.php* - Used when a post belongs to a specific custom post type. The type is matched by the "post_type" property of the post. For example if you had a custom post type of <code>news</code>, you could use a template with the name <code>type-news.php</code>. +- *meta-{key}.php* - Used when there is a custom field for the post/page matching the key listed in the file name. This is useful if you want to be able to flag posts as "photo" or similar, and give those posts some custom treatment. In this example, you could add a custom field of "photo" with a value of the URL of the image to a post/page and it would use a template of <code>meta-photo.php</code> if that template exists. The value does not matter in this match. +- *meta-{key}-{value}.php* - Used when there is a custom field for the post/page matching the key and value listed in the file name. This is useful if you want to be able to flag posts as "featured" or similar, and give those posts some custom treatment. In this example, you could add a custom field of "featured" with a value of "yes" to a post/page and it would use a template of <code>meta-featured-yes.php</code> if that template exists. +- *page.php* - Used when the content is being displayed is a page (not a post). +- *parent-{slug}.php* - Used when a page is a child page of a specific parent page. The page is matched by the "slug" - for example a page under a parent page with slug of "example" could use a template of <code>parent-example.php</code>. +- *role-{role}.php* - Used when a post/page is authored by a user with a particular role. The {role} is an all lowercase representation of the role string - for example, an author with an "Administrator" role might use a template of <code>role-administrator.php</code>. This is primarily useful if you have a set of authors that are given a Contributor role; or a Guest Columnist role or similar. Any WordPress role can take the place of {role} in the file name. +- *tag-{slug}.php* - Used when a post has a certain tag applied to it. The tag is matched by the "slug" - for example a post with tag "Reference" (with a tag slug of "reference") could use a template of <code>tag-reference.php</code>. diff --git a/wp-content/themes/carrington-blog/content/content-default.php b/wp-content/themes/carrington-blog/content/content-default.php index 821aa4c5a..cbbac37fc 100644 --- a/wp-content/themes/carrington-blog/content/content-default.php +++ b/wp-content/themes/carrington-blog/content/content-default.php @@ -17,6 +17,10 @@ if (__FILE__ == $_SERVER['SCRIPT_FILENAME']) { die(); } if (CFCT_DEBUG) { cfct_banner(__FILE__); } + +global $previousday; +$previousday = -1; + ?> <div id="post-content-<?php the_ID() ?>" <?php post_class('full'); ?>> @@ -46,7 +50,7 @@ if (CFCT_DEBUG) { cfct_banner(__FILE__); } <span class="author vcard full-author"> <?php printf(__('<span class="by alt-font">By</span> %s', 'carrington-blog'), '<a class="url fn" href="'.get_author_posts_url(get_the_author_meta('ID')).'" title="View all posts by ' . attribute_escape(get_the_author()) . '">'.get_the_author().'</a>') ?> </span> - <span class="date full-date"><span class="ndash alt-font">–</span> <abbr class="published" title="<?php the_time('c'); ?>"><?php the_time('F j, Y'); ?></abbr></span> + <span class="date full-date"><span class="ndash alt-font">–</span> <abbr class="published" title="<?php the_time('Y-m-d\TH:i'); ?>"><?php the_date(); ?></abbr></span> </p><!--/by-line--> <div id="post-comments-<?php the_ID(); ?>-target"></div> diff --git a/wp-content/themes/carrington-blog/content/page.php b/wp-content/themes/carrington-blog/content/page.php index d18f1ec50..c9dad3110 100644 --- a/wp-content/themes/carrington-blog/content/page.php +++ b/wp-content/themes/carrington-blog/content/page.php @@ -17,6 +17,10 @@ if (__FILE__ == $_SERVER['SCRIPT_FILENAME']) { die(); } if (CFCT_DEBUG) { cfct_banner(__FILE__); } + +global $previousday; +$previousday = -1; + ?> <div id="post-content-<?php the_ID() ?>" <?php post_class('full'); ?>> <h1 class="entry-title full-title"><?php the_title() ?></h1> @@ -38,7 +42,7 @@ if (CFCT_DEBUG) { cfct_banner(__FILE__); } <span class="author vcard full-author"> <?php printf(__('<span class="by alt-font">By</span> %s', 'carrington-blog'), '<a class="url fn" href="'.get_author_posts_url(get_the_author_meta('ID')).'" title="View all posts by ' . attribute_escape(get_the_author()) . '">'.get_the_author().'</a>') ?> </span> - <span class="date full-date"><abbr class="published" title="<?php the_time('c'); ?>"><?php the_time('F j, Y'); ?></abbr></span> + <span class="date full-date"><abbr class="published" title="<?php the_time('Y-m-d\TH:i:sO'); ?>"><?php the_time(); ?></abbr></span> </p><!--/by-line--> <div class="clear"></div> <?php edit_post_link(__('Edit', 'carrington-blog'), '<div class="edit">', '</div>'); ?> diff --git a/wp-content/themes/carrington-blog/css/README.txt b/wp-content/themes/carrington-blog/css/README.txt new file mode 100644 index 000000000..1fb41adad --- /dev/null +++ b/wp-content/themes/carrington-blog/css/README.txt @@ -0,0 +1,8 @@ +## css/ + +Organizational folder for holding theme image files. You can reference these files using the built-in WordPress `bloginfo()` function like so: + + <link rel="stylesheet" type="text/css" + href="<?php bloginfo('template_directory'); ?>/css/base.css" /> + +This directory is not used by the Carrington engine (template naming conventions are not supported), it is provided solely for convenience and for better organization of these files. \ No newline at end of file diff --git a/wp-content/themes/carrington-blog/assets/css/attachment-light.css b/wp-content/themes/carrington-blog/css/attachment-light.css similarity index 100% rename from wp-content/themes/carrington-blog/assets/css/attachment-light.css rename to wp-content/themes/carrington-blog/css/attachment-light.css diff --git a/wp-content/themes/carrington-blog/assets/css/attachment.css b/wp-content/themes/carrington-blog/css/attachment.css similarity index 100% rename from wp-content/themes/carrington-blog/assets/css/attachment.css rename to wp-content/themes/carrington-blog/css/attachment.css diff --git a/wp-content/themes/carrington-blog/assets/css/carrington-blog.css b/wp-content/themes/carrington-blog/css/carrington-blog.css similarity index 97% rename from wp-content/themes/carrington-blog/assets/css/carrington-blog.css rename to wp-content/themes/carrington-blog/css/carrington-blog.css index 68583bec5..5828483d5 100644 --- a/wp-content/themes/carrington-blog/assets/css/carrington-blog.css +++ b/wp-content/themes/carrington-blog/css/carrington-blog.css @@ -517,7 +517,7 @@ li.li-comment li.li-comment { margin:0; padding:0; } -.respond { +form.comment-form { background-color:#efeff1; border:1px solid #e9eaea; margin-bottom:8px; @@ -531,33 +531,16 @@ li.li-comment li.li-comment { margin-right:9px; width:200px; } -.comment-form .help, -.comment-form-title small { +.comment-form em { color:#999; font-weight:normal; font-style:normal; font-size:12px; } -.comment-form-title small a { - color: #A00004; -} -.comment-form-title small a:hover { - text-decoration: underline; -} -.comment-form .some-html-is-ok { - display: block; - margin-bottom: 9px; -} -.comment-form-comment { - margin-bottom: 0; -} .comment-form textarea { height:9em; width:95%; } -.comment-form .form-submit { - margin-bottom: 9px; -} /* Sidebar and Widgets ============================== */ diff --git a/wp-content/themes/carrington-blog/assets/css/css.php b/wp-content/themes/carrington-blog/css/css.php similarity index 100% rename from wp-content/themes/carrington-blog/assets/css/css.php rename to wp-content/themes/carrington-blog/css/css.php diff --git a/wp-content/themes/carrington-blog/css/ie.css b/wp-content/themes/carrington-blog/css/ie.css new file mode 100644 index 000000000..01387cdfb --- /dev/null +++ b/wp-content/themes/carrington-blog/css/ie.css @@ -0,0 +1,45 @@ +/* +// This file is part of the Carrington Blog Theme for WordPress +// http://carringtontheme.com +// +// Copyright (c) 2008-2009 Crowd Favorite, Ltd. All rights reserved. +// http://crowdfavorite.com +// +// Released under the GPL license +// http://www.opensource.org/licenses/gpl-license.php +// +// ********************************************************************** +// This program is distributed in the hope that it will be useful, but +// WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. +// ********************************************************************** +*/ + +/* hasLayout fixes */ +ul li, +.nav ul, +.full, +.entry-content, +.entry-summary, +.commentlist .hentry, +.widget, +.comment-form, +#content, +#sidebar, +#carrington-about .about {zoom:1;} + +.entry-content { + width:100%; +} + +/* Suckerfish dropdowns stick in IE7 without this bit */ +*:first-child+html .nav {height: 1%;} +*:first-child+html .nav li {height: 1%;} + +/* Margin float fix */ +.full p.comments-link{ + margin:0; +} +.comment-reply-link { + filter:alpha(opacity=70); +} \ No newline at end of file diff --git a/wp-content/themes/carrington-blog/css/ie6.css b/wp-content/themes/carrington-blog/css/ie6.css new file mode 100644 index 000000000..b0ae1f311 --- /dev/null +++ b/wp-content/themes/carrington-blog/css/ie6.css @@ -0,0 +1,36 @@ +/* +// This file is part of the Carrington Blog Theme for WordPress +// http://carringtontheme.com +// +// Copyright (c) 2008-2009 Crowd Favorite, Ltd. All rights reserved. +// http://crowdfavorite.com +// +// Released under the GPL license +// http://www.opensource.org/licenses/gpl-license.php +// +// ********************************************************************** +// This program is distributed in the hope that it will be useful, but +// WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. +// ********************************************************************** +*/ + +/* hasLayout fixes */ +.pagination, +.pagination-single { zoom:1; } + +/* Harden text widgets against italics problem */ +.textwidget { + overflow:visible; +} + +/* Border dotted looks like junk in IE. */ +.archive, +.excerpt, +.search, +ol.commentlist li.li-comment, +.ping, +#carrington-archives ul, +#carrington-archives li { + border-style:solid; +} \ No newline at end of file diff --git a/wp-content/themes/carrington-blog/css/iepngfix.htc b/wp-content/themes/carrington-blog/css/iepngfix.htc new file mode 100644 index 000000000..a90fed0eb --- /dev/null +++ b/wp-content/themes/carrington-blog/css/iepngfix.htc @@ -0,0 +1,187 @@ +<public:component> +<script type="text/javascript"> + +// IE5.5+ PNG Alpha Fix v2.0 Alpha +// (c) 2004-2008 Angus Turnbull http://www.twinhelix.com + +// This is licensed under the GNU LGPL, version 2.1 or later. +// For details, see: http://creativecommons.org/licenses/LGPL/2.1/ + +var IEPNGFix = window.IEPNGFix || {}; +IEPNGFix.data = IEPNGFix.data || {}; + + +// This must be a path to a blank image, relative to the HTML document(s). +// In production use I suggest '/images/blank.gif' or similar. That's all! +IEPNGFix.blankImg = CFCT_BLANKIMG; + + +IEPNGFix.fix = function(elm, src, t) { + // Applies an image 'src' to an element 'elm' using the DirectX filter. + // If 'src' is null, filter is disabled. + // Disables the 'hook' to prevent infinite recursion on setting BG/src. + // 't' = type, where background tile = 0, background = 1, IMG SRC = 2. + + var h = this.hook.enabled; + this.hook.enabled = 0; + + var f = 'DXImageTransform.Microsoft.AlphaImageLoader'; + src = (src || '').replace(/\(/g, '%28').replace(/\)/g, '%29'); + + if ( + src && !(/IMG|INPUT/.test(elm.nodeName) && (t != 2)) && + elm.currentStyle.width == 'auto' && elm.currentStyle.height == 'auto' + ) { + elm.style.width = elm.offsetWidth + 'px'; + elm.style.height = elm.clientHeight + 'px'; + if (elm.currentStyle.display == 'inline') { + elm.style.display = 'inline-block'; + } + } + + if (t == 1) { + elm.style.backgroundImage = 'url("' + this.blankImg + '")'; + } + if (t == 2) { + elm.src = this.blankImg; + } + + if (elm.filters[f]) { + elm.filters[f].enabled = src ? true : false; + if (src) { + elm.filters[f].src = src; + } + } else if (src) { + elm.style.filter = 'progid:' + f + '(src="' + src + + '",sizingMethod="' + (t == 2 ? 'scale' : 'crop') + '")'; + } + + this.hook.enabled = h; +}; + + +IEPNGFix.process = function(elm, init) { + // Checks the onpropertychange event (on first 'init' run, a fake event) + // and calls the filter-applying-functions. + + if ( + !/MSIE (5\.5|6)/.test(navigator.userAgent) || + typeof elm.filters == 'unknown' + ) { + return; + } + if (!this.data[elm.uniqueID]) { + this.data[elm.uniqueID] = { + className: '' + }; + } + var data = this.data[elm.uniqueID], + evt = init ? { propertyName: 'src,backgroundImage' } : event, + isSrc = /src/.test(evt.propertyName), + isBg = /backgroundImage/.test(evt.propertyName), + isPos = /width|height|background(Pos|Rep)/.test(evt.propertyName), + isClass = !init && ((elm.className != data.className) && + (elm.className || data.className)); + if (!(isSrc || isBg || isPos || isClass)) { + return; + } + data.className = elm.className; + var blank = this.blankImg.match(/([^\/]+)$/)[1], + eS = elm.style, + eCS = elm.currentStyle; + + // Required for Whatever:hover - erase set BG if className changes. + if ( + isClass && (eS.backgroundImage.indexOf('url(') == -1 || + eS.backgroundImage.indexOf(blank) > -1) + ) { + return setTimeout(function() { + eS.backgroundImage = ''; + }, 0); + } + + // Foregrounds. + if (isSrc && elm.src && { IMG: 1, INPUT: 1 }[elm.nodeName]) { + if ((/\.png/i).test(elm.src)) { + this.fix(elm, elm.src, 2); + } else if (elm.src.indexOf(blank) == -1) { + this.fix(elm, ''); + } + } + + // Backgrounds. + var bgSrc = eCS.backgroundImage || eS.backgroundImage; + if ((bgSrc + elm.src).indexOf(blank) == -1) { + var bgPNG = bgSrc.match(/url[("']+(.*\.png[^\)"']*)[\)"']/i); + if (bgPNG) { + if (this.tileBG && !{ IMG: 1, INPUT: 1 }[elm.nodeName]) { + this.tileBG(elm, bgPNG[1]); + this.fix(elm, '', 1); + } else { + if (data.tiles && data.tiles.src) { + this.tileBG(elm, ''); + } + this.fix(elm, bgPNG[1], 1); + this.childFix(elm); + } + } else { + if (data.tiles && data.tiles.src) { + this.tileBG(elm, ''); + } + this.fix(elm, ''); + } + } else if ((isPos || isClass) && data.tiles && data.tiles.src) { + this.tileBG(elm, data.tiles.src); + } + + if (init) { + this.hook.enabled = 1; + elm.attachEvent('onpropertychange', this.hook); + } +}; + + +IEPNGFix.childFix = function(elm) { + // "hasLayout" fix for unclickable children inside PNG backgrounds. + var tags = [ + 'a', + 'input', + 'select', + 'textarea', + 'button', + 'iframe', + 'object' + ], + t = tags.length, + tFix = []; + while (t--) { + var pFix = elm.all.tags(tags[t]), + e = pFix.length; + while (e--) { + tFix.push(pFix[e]); + } + } + t = tFix.length; + if (t && (/relative|absolute/i).test(elm.currentStyle.position)) { + alert('IEPNGFix: Unclickable children of element:' + + '\n\n<' + elm.nodeName + (elm.id && ' id=' + elm.id) + '>'); + } + while (t--) { + if (!(/relative|absolute/i).test(tFix[t].currentStyle.position)) { + tFix[t].style.position = 'relative'; + } + } +}; + + +IEPNGFix.hook = function() { + if (IEPNGFix.hook.enabled) { + IEPNGFix.process(element, 0); + } +}; + + +IEPNGFix.process(element, 1); + +</script> +</public:component> diff --git a/wp-content/themes/carrington-blog/css/img.css b/wp-content/themes/carrington-blog/css/img.css new file mode 100644 index 000000000..b908c44a5 --- /dev/null +++ b/wp-content/themes/carrington-blog/css/img.css @@ -0,0 +1,147 @@ +/* +// This file is part of the Carrington Blog Theme for WordPress +// http://carringtontheme.com +// +// Copyright (c) 2008-2009 Crowd Favorite, Ltd. All rights reserved. +// http://crowdfavorite.com +// +// Released under the GPL license +// http://www.opensource.org/licenses/gpl-license.php +// +// ********************************************************************** +// This program is distributed in the hope that it will be useful, but +// WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. +// ********************************************************************** +*/ + +.rule, +.rule-major, +.rule-minor { + background-color:#fff; + background-repeat:no-repeat; + background-position:center; + border:0; +} +.rule { + background-image:url(../img/divider-ornament.gif); + +} +.rule-major { + background-image:url(../img/comments-divider.gif); +} +.rule-minor { + background-image:url(../img/divider-ornament.gif); +} +.nav li li { + background:url(../img/dropdown-divider.gif) no-repeat center top; +} +.nav li li:first-child, +.nav li li.first-child { + background:transparent; +} +.pagination, +.pagination-single { + background-image:url(../img/grey-to-white-gradient.png); + background-repeat:repeat-x; + background-position:left top; +} +.close { + background-image: url(../img/header/texture-light.png) top center; +} + +.full .comments-link a, +.full .comments-link a:visited, +.full .comments-link span, +.excerpt .comments-link a, +.excerpt .comments-link a:visited, +.excerpt .comments-link span{ + background: url(../img/comment.gif) no-repeat left center; + padding: 1px 0 0 20px; +} +.excerpt .comments-link a, +.excerpt .comments-link a:visited, +.excerpt .comments-link span{ + width:120px; +} +.commentlist .bypostauthor { + background-image: url(../img/watermark-light.gif); + background-repeat:no-repeat; + background-position:left top; +} + +form.comment-form { + background-image: url(../img/watermark-light.gif); + background-repeat:repeat-x; + background-position:left top; +} + +#header { + background-image:url(../img/header/gradient-dark.png); +} +#header .wrapper { + background-image:url(../img/header/texture-dark.png); +} +#sub-header { + background-image: url(../img/sub-header-border-bottom.gif); + background-repeat:repeat-x; + background-position:left bottom; +} +#sidebar { + background:url(../img/sidebar-background.gif) no-repeat left top; + background-color: #fff !important; +} +#footer { + background-image: url(../img/footer/gradient-dark.png); +} +#footer .wrapper { + background: url(../img/footer/divider-ornament-wide-light.png) no-repeat center bottom; +} +#carrington-subscribe { + background: url(../img/divider-ornament.gif) no-repeat center bottom; +} + +#carrington-subscribe a{ + background:url(../img/rss-button.gif) no-repeat left top; +} + +#carrington-about { + background: url(../img/divider-ornament.gif) no-repeat center bottom; +} +#carrington-about .about{ + background:url(../img/watermark-light.gif) repeat-x left top; +} + +/* Gallery +=================================== */ + +body#attachment #header { + background-image:url(../img/header/gradient-dark.png); + background-repeat:repeat-x; + background-position:center bottom; +} +body#attachment #header .wrapper { + background-position:center bottom; +} +.figure-info { + background:transparent url(../img/divider-ornament-wide-dark.png) no-repeat scroll center top; +} +.previous-attachment, +.next-attachment { + padding-bottom:13px; +} +.previous-attachment { + background:url(../img/attachment/150px-flourish-left-dark.png) no-repeat right bottom; +} +.next-attachment{ + background:url(../img/attachment/150px-flourish-right-dark.png) no-repeat left bottom; +} + +/* Misc +=================================== */ + +#TB_title{ + background-image: url(../img/header/texture-dark.png); + background-repeat:no-repeat; + background-position:center bottom; +} diff --git a/wp-content/themes/carrington-blog/assets/css/typography.css b/wp-content/themes/carrington-blog/css/typography.css similarity index 100% rename from wp-content/themes/carrington-blog/assets/css/typography.css rename to wp-content/themes/carrington-blog/css/typography.css diff --git a/wp-content/themes/carrington-blog/error/README.txt b/wp-content/themes/carrington-blog/error/README.txt new file mode 100644 index 000000000..51caf9f40 --- /dev/null +++ b/wp-content/themes/carrington-blog/error/README.txt @@ -0,0 +1,15 @@ +## error/ + +This directory holds templates for error conditions. WordPress supports the 404 error out of the box, but you may want to create additional error templates for other conditions (not authorized, etc.). + +You can load an error template by using the following code: + + cfct_error('not-authorized.php'); + + +### Example File Descriptions + +- *404.php* - used for "File not Found" errors. +- *exit.php* - used to display a message when exiting on some error condition. + +This directory is not used by the Carrington engine (template naming conventions are not supported), it is provided solely for convenience and for better organization of these files. \ No newline at end of file diff --git a/wp-content/themes/carrington-blog/excerpt/README.txt b/wp-content/themes/carrington-blog/excerpt/README.txt new file mode 100644 index 000000000..12455d0fb --- /dev/null +++ b/wp-content/themes/carrington-blog/excerpt/README.txt @@ -0,0 +1,45 @@ +## excerpt/ + +(This information is very similar to the _content/_) + +This directory holds the templates for displaying a the excerpt for a post. Typically this will include the title and some sub-set of meta information (date, categories, tags, author, etc.) and the full output of `the_content()`. + + +## Post Context + +When choosing a template to use in the Post Context, the Carrington engine looks information (author, category, tags, custom fields, etc.) related to the post/page being shown. + +Commonly these templates are included by templates in the _loop/_; but are also useful for bringing in an atomic post representation via AJAX or placing one within another template. + +A "default" template is required, and will be used when there are no other templates that match a given post. This could be because no other templates have been created, or because the post in question doesn't match the templates that are available. + +You can create templates to be used with posts/pages given various conditions. For example, you might want to give all posts in a certain category some specific styling rules. Or perhaps posts with a certain custom field or by a specific author. This is accomplished by creating templates with file names that match these conditions, then placing them in the _content/_ directory. All templates other than _{dirname}-default.php_ are optional. + +The order in which these conditions are checked defaults to the following: + +1. author +2. meta +3. category +4. type +5. role +6. tag +7. parent +8. default + +however this order can be overridden with a plugin using the `cfct_single_match_order` hook. + +Once a template match has been found, no other processing is done. + + +### Supported Templates (Post Context) + +- *{dirname}-default.php* - Used when there are no other templates that match for a given post/page. +- *author-{username}.php* - Used when a user with that username authors a post/page. For example, a template with a file name of <code>author-jsmith.php</code> would be used for a poat/page by user <code>jsmith</code>. Any WordPres username can take the place of {username} in the file name. +- *cat-{slug}.php* - Used when a post is in a given category. The category is matched by the "slug" - for example a post in category "General" (with a category slug of "general") could use a template of <code>cat-general.php</code>. +- *type-{post_type}.php* - Used when a post belongs to a specific custom post type. The type is matched by the "post_type" property of the post. For example if you had a custom post type of <code>news</code>, you could use a template with the name <code>type-news.php</code>. +- *meta-{key}.php* - Used when there is a custom field for the post/page matching the key listed in the file name. This is useful if you want to be able to flag posts as "photo" or similar, and give those posts some custom treatment. In this example, you could add a custom field of "photo" with a value of the URL of the image to a post/page and it would use a template of <code>meta-photo.php</code> if that template exists. The value does not matter in this match. +- *meta-{key}-{value}.php* - Used when there is a custom field for the post/page matching the key and value listed in the file name. This is useful if you want to be able to flag posts as "featured" or similar, and give those posts some custom treatment. In this example, you could add a custom field of "featured" with a value of "yes" to a post/page and it would use a template of <code>meta-featured-yes.php</code> if that template exists. +- *page.php* - Used when the content is being displayed is a page (not a post). +- *parent-{slug}.php* - Used when a page is a child page of a specific parent page. The page is matched by the "slug" - for example a page under a parent page with slug of "example" could use a template of <code>parent-example.php</code>. +- *role-{role}.php* - Used when a post/page is authored by a user with a particular role. The {role} is an all lowercase representation of the role string - for example, an author with an "Administrator" role might use a template of <code>role-administrator.php</code>. This is primarily useful if you have a set of authors that are given a Contributor role; or a Guest Columnist role or similar. Any WordPress role can take the place of {role} in the file name. +- *tag-{slug}.php* - Used when a post has a certain tag applied to it. The tag is matched by the "slug" - for example a post with tag "Reference" (with a tag slug of "reference") could use a template of <code>tag-reference.php</code>. diff --git a/wp-content/themes/carrington-blog/excerpt/excerpt-default.php b/wp-content/themes/carrington-blog/excerpt/excerpt-default.php index 9c351c5e6..4d15d3e87 100644 --- a/wp-content/themes/carrington-blog/excerpt/excerpt-default.php +++ b/wp-content/themes/carrington-blog/excerpt/excerpt-default.php @@ -22,7 +22,7 @@ if (CFCT_DEBUG) { cfct_banner(__FILE__); } <div id="post-excerpt-<?php the_ID() ?>" <?php post_class('excerpt'); ?>> <strong class="entry-title"><a href="<?php the_permalink() ?>" title="Permanent link to <?php the_title_attribute() ?>" rel="bookmark" rev="post-<?php the_ID(); ?>"><?php the_title(); ?></a></strong> - <span class="date small"><abbr class="published" title="<?php the_time('c'); ?>"><?php the_time('F j, Y'); ?></abbr></span> + <span class="date small"><abbr class="published" title="<?php the_time('Y-m-d\TH:i'); ?>"><?php the_time('F j, Y'); ?></abbr></span> <p class="categories filed alt-font"><?php _e('Posted in ', 'carrington-blog'); the_category(', ') ?>.</p> diff --git a/wp-content/themes/carrington-blog/excerpt/search.php b/wp-content/themes/carrington-blog/excerpt/search.php index 34f736c2d..a83e3c261 100644 --- a/wp-content/themes/carrington-blog/excerpt/search.php +++ b/wp-content/themes/carrington-blog/excerpt/search.php @@ -29,6 +29,6 @@ if (CFCT_DEBUG) { cfct_banner(__FILE__); } <span class="author vcard"> <?php printf(__('<span class="by alt-font">By</span> %s', 'carrington-blog'), '<a class="url fn" href="'.get_author_posts_url(get_the_author_meta('ID')).'" title="View all posts by ' . attribute_escape(get_the_author()) . '">'.get_the_author().'</a>') ?> </span> - <span class="date"><span class="ndash alt-font">–</span> <abbr class="published" title="<?php the_time('c'); ?>"><?php the_time('F j, Y'); ?></abbr></span> + <span class="date"><span class="ndash alt-font">–</span> <abbr class="published" title="<?php the_time('Y-m-d\TH:i'); ?>"><?php the_time('F j, Y'); ?></abbr></span> </p> </div><!-- .post --> \ No newline at end of file diff --git a/wp-content/themes/carrington-blog/footer/README.txt b/wp-content/themes/carrington-blog/footer/README.txt new file mode 100644 index 000000000..17321b0de --- /dev/null +++ b/wp-content/themes/carrington-blog/footer/README.txt @@ -0,0 +1,42 @@ +## footer/ + +The standard _footer.php_ file (included using the WordPress `get_footer()` function) in Carrington is set up to call the `cfct_footer()` function, which will choose the appropriate footer file from this directory - based on the context of the given page. This can be useful if you want to have pages to have a custom footer, or perhaps a certain category to have a custom footer. + + +## General Context + +When choosing a template to use in the General Context, the Carrington engine looks at the type of request is being fulfilled. It will identify the request as the home page, a category archive, and individual post, etc. + +There is additional checking done for single post requests. All options in the Content Context are supported here with a 'single-' prefix added to the file. See specifics below. + +A "default" template is required, and will be used when there are no other templates that match a given comment. This could be because no other templates have been created, or because the comment in question doesn't match the templates that are available. + +By default, conditions are checked in this order: + +1. author +2. role +3. category +4. tag +5. single +6. default (home, search, archive, 404, etc.) + +This can be altered using the `cfct_general_match_order` hook. + + +### Supported Templates (General Context) + +- *{dirname}-default.php* (or default.php) - Used when there are no other templates that match for a given page/post. +- *archive.php* - Used for date archives or if there are no specific category, author or tag templates. +- *author.php* - Used for author archive lists. +- *author-{username}.php* - Used when the post/page is authored by a specific user. For example, a template with a file name of _author-jsmith.php_ would be used for a post/page by user _jsmith_. Any WordPress username can take the place of {username} in the file name. +- *role-{rolename}.php - Used when the post author has a particular role. This might be the role of _contributor_, _author_, _editor_, etc. and use a file of _role-contributor.php_, _role_author.php_, etc. where the role name takes the place of the {rolename} in the file name. +- *category.php* - Used for category archive lists. +- *cat-{slug}.php* - Used fr displaying a given category. The category is matched by the "slug" - for example a post in category "General" (with a category slug of "general") could use a template of _cat-general.php_. +- *home.php* - Used when on the home page. +- *page.php* - Used for pages that do not match any other contextual templates. +- *search.php* - Used when displaying search results. +- *single.php* - Used for single post pages. +- *single-{content context filenames}.php* - Used for single post pages. +- *tag.php* - Used for tag archive lists. +- *tag-{slug}.php* - Used for displaying a given tag. The tag is matched by the "slug" - for example a post in tag "News" (with a tag slug of "news") could use a template of _tag-news.php_. + diff --git a/wp-content/themes/carrington-blog/forms/README.txt b/wp-content/themes/carrington-blog/forms/README.txt new file mode 100644 index 000000000..07650e7f1 --- /dev/null +++ b/wp-content/themes/carrington-blog/forms/README.txt @@ -0,0 +1,18 @@ +## forms/ + +### Overview + +This directory holds forms that may be used in various places throughout the theme. + +These forms can be included in other theme files using the following code: + + <?php cfct_form('comment'); ?> + +Where `comment.php` is the name of the file in the _forms/_ directory that you want to include. + + +### Example File Descriptions + +Included by default are the "post comment" form (_comment.php_) and the "search" form (_search.php_). Create as many forms as you like and store them here to keep them organized. + +This directory is not used by the Carrington engine (template naming conventions are not supported), it is provided solely for convenience and for better organization of these files. \ No newline at end of file diff --git a/wp-content/themes/carrington-blog/forms/comment.php b/wp-content/themes/carrington-blog/forms/comment.php new file mode 100644 index 000000000..e8254f1ce --- /dev/null +++ b/wp-content/themes/carrington-blog/forms/comment.php @@ -0,0 +1,98 @@ +<?php + +// This file is part of the Carrington Blog Theme for WordPress +// http://carringtontheme.com +// +// Copyright (c) 2008-2010 Crowd Favorite, Ltd. All rights reserved. +// http://crowdfavorite.com +// +// Released under the GPL license +// http://www.opensource.org/licenses/gpl-license.php +// +// ********************************************************************** +// This program is distributed in the hope that it will be useful, but +// WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. +// ********************************************************************** + +if (__FILE__ == $_SERVER['SCRIPT_FILENAME']) { die(); } +if (CFCT_DEBUG) { cfct_banner(__FILE__); } + +global $post, $user_identity; + +$commenter = wp_get_current_commenter(); +extract($commenter); + +$req = get_option('require_name_email'); + +// if post is open to new comments +if (comments_open()) { + // if you need to be regestered to post comments.. + if ( get_option('comment_registration') && !is_user_logged_in() ) { ?> + +<p id="you-must-be-logged-in-to-comment"><?php printf(__('You must be <a href="%s">logged in</a> to post a comment.', 'carrington-blog'), get_bloginfo('wpurl').'/wp-login.php?redirect_to='.urlencode(get_permalink())); ?></p> + +<?php + } + else { +?> + +<div id="respond-p<?php echo $post->ID; ?>"> + <form action="<?php echo trailingslashit(get_bloginfo('wpurl')); ?>wp-comments-post.php" method="post" class="comment-form"> + <p class="comment-form-comment tight"> + <label class="h3" for="comment-p<?php echo $post->ID; ?>"><?php + if (function_exists('comment_form_title')) { + comment_form_title(); + echo ' <em id="cancel-comment-reply">', cancel_comment_reply_link(), '</em>'; + } + else { + _e('Post a comment', 'carrington-blog'); + } +?></label> + <br class="lofi" /> + <span class="comment-form-comment-area"> + <textarea id="comment-p<?php echo $post->ID; ?>" name="comment" rows="8" cols="40"></textarea><br /> + <em class="some-html-is-ok"><abbr title="<?php printf(__('You can use: %s', 'carrington-blog'), allowed_tags()); ?>"><?php _e('Some HTML is OK', 'carrington-blog'); ?></abbr></em> + </span> + </p> +<?php // if you're not logged in... + if (!is_user_logged_in()) { +?> + <p class="comment-form-user-info tight"> + <input type="text" id="author-p<?php echo $post->ID; ?>" name="author" value="<?php echo $comment_author; ?>" size="22" /> + <label for="author-p<?php echo $post->ID; ?>"><?php _e('Name', 'carrington-blog'); if ($req) { echo ' <em>' , _e('(required)', 'carrington-blog'), '</em>'; } ?></label> + </p><!--/name--> + <p class="comment-form-user-info tight"> + <input type="text" id="email-p<?php echo $post->ID; ?>" name="email" value="<?php echo $comment_author_email; ?>" size="22" /> + <label for="email-p<?php echo $post->ID; ?>"><?php + _e('Email ', 'carrington-blog'); + $req ? $email_note = __('(required, but never shared)', 'carrington-jam') : $email_note = __('(never shared)', 'carrington-jam'); + echo ' <em>'.$email_note.'</em>'; +?></label> + </p><!--/email--> + <p class="comment-form-user-info tight"> + <input type="text" id="url-p<?php echo $post->ID; ?>" name="url" value="<?php echo $comment_author_url; ?>" size="22" /> + <label title="<?php _e('Your website address', 'carrington-blog'); ?>" for="url-p<?php echo $post->ID; ?>"><?php _e('Web', 'carrington-blog'); ?></label> + </p><!--/url--> +<?php + } +?> + <p class="tight"> + <input name="submit" type="submit" value="<?php _e('Post comment', 'carrington-blog'); ?>" /> + <span class="comment-form-trackback"><?php printf(__('or, reply to this post via <a rel="trackback" href="%s">trackback</a>.', 'carrington-blog'), get_trackback_url()); ?></span> + </p> +<?php // if you're logged in... + if (is_user_logged_in()) { +?> + <p class="logged-in tight"><?php printf(__('Logged in as <a href="%s">%s</a>. ', 'carrington-blog'), get_bloginfo('wpurl').'/wp-admin/profile.php', $user_identity); wp_loginout(); ?>.</p> +<?php + } + cfct_comment_id_fields(); + do_action('comment_form', $post->ID); +?> + </form> +</div> +<?php + } // If registration required and not logged in +} // If you delete this the sky will fall on your head +?> \ No newline at end of file diff --git a/wp-content/themes/carrington-blog/forms/search.php b/wp-content/themes/carrington-blog/forms/search.php index f7bb6c6a6..6c7e83b20 100644 --- a/wp-content/themes/carrington-blog/forms/search.php +++ b/wp-content/themes/carrington-blog/forms/search.php @@ -18,19 +18,18 @@ if (__FILE__ == $_SERVER['SCRIPT_FILENAME']) { die(); } if (CFCT_DEBUG) { cfct_banner(__FILE__); } -$s = get_query_var('s'); - if (get_option('permalink_structure') != '') { $onsubmit = "location.href=this.action+'search/'+encodeURIComponent(this.s.value).replace(/%20/g, '+'); return false;"; } else { $onsubmit = ''; } + ?> <form method="get" id="cfct-search" action="<?php echo trailingslashit(get_bloginfo('url')); ?>" onsubmit="<?php echo $onsubmit; ?>"> <div> - <input type="text" id="cfct-search-input" name="s" value="<?php echo esc_attr($s); ?>" size="15" /> + <input type="text" id="cfct-search-input" name="s" value="<?php echo wp_specialchars($s, 1); ?>" size="15" /> <input type="submit" name="submit_button" value="<?php _e('Search', 'carrington-blog'); ?>" /> </div> </form> \ No newline at end of file diff --git a/wp-content/themes/carrington-blog/functions.php b/wp-content/themes/carrington-blog/functions.php index 50d5d2eef..238e98106 100644 --- a/wp-content/themes/carrington-blog/functions.php +++ b/wp-content/themes/carrington-blog/functions.php @@ -23,50 +23,6 @@ define('CFCT_DEBUG', false); define('CFCT_PATH', trailingslashit(TEMPLATEPATH)); define('CFCT_HOME_LIST_LENGTH', 5); define('CFCT_HOME_LATEST_LENGTH', 250); -define('CFCT_VER', '1.1'); - -include_once(CFCT_PATH.'functions/admin.php'); -include_once(CFCT_PATH.'carrington-core/carrington.php'); - -/** - * Load in assets at wp_enqueue_scripts hook - * This function loads a file that contains calls to wp_enqueue_script - * and wp_enqueue_style, etc. - */ -function cfct_load_front_end_assets() { - cfct_template_file('assets', 'load'); -} -add_action('wp_enqueue_scripts', 'cfct_load_front_end_assets'); - -/** - * Theme setup work - */ -function cfct_setup() { - $sidebar_defaults = array( - 'before_widget' => '<div id="%1$s" class="widget %2$s">', - 'after_widget' => '<div class="clear"></div></div>', - 'before_title' => '<h2 class="widget-title">', - 'after_title' => '</h2>' - ); - - register_sidebar(array_merge( - $sidebar_defaults, - array('name' => 'Primary Sidebar') - )); - - register_sidebar(array_merge( - $sidebar_defaults, - array('name' => 'Secondary Sidebar') - )); - - add_theme_support('automatic-feed-links'); -} -add_action('after_setup_theme', 'cfct_setup'); - -function cfct_add_pingback_link() { - echo '<link rel="pingback" href="'.get_bloginfo('pingback_url').'" />'; -} -add_action('wp_head', 'cfct_add_pingback_link'); $cfct_options = array( 'cfct_home_column_1_cat', @@ -126,252 +82,179 @@ function cfct_blog_option_defaults($options) { } add_filter('cfct_option_defaults', 'cfct_blog_option_defaults'); -// Filter comment reply link to work with namespaced comment-reply javascript. -add_filter('cancel_comment_reply_link', 'cfct_get_cancel_comment_reply_link', 10, 3); -/** - * Start and end an output buffer at specific actions that you specify. - * Warning: this is a bit of a tricky thing to do, but it works in a pinch. - * Basically, don't use this unless you really have to. - */ -class CFCT_OB_On_Action { - protected $ob_started = false; - protected $hooks_attached = false; - protected $callback; - - public function __construct($start_action, $end_action, $callback = null, $priority = 10) { - if ($callback === null) { - $callback = array($this, 'callback'); - } - - $this->start_action = $start_action; - $this->end_action = $end_action; - $this->callback = $callback; - $this->priority = $priority; - - $this->attach_hooks(); - } - - /** - * If you specialize this class, you can customize this function to do something - * with the buffer. Otherwise, just pass your callback in using the $callback param in __construct(). - */ - public function callback($buffer) { - // Do something... - } - - /** - * Attach hooks for actions. Only runs once. - */ - protected function attach_hooks() { - if ($this->hooks_attached === true) { - return; - } - add_action($this->start_action, array($this, 'start')); - add_action($this->end_action, array($this, 'end')); - $this->hooks_attached = true; +function cfct_blog_init() { + if (cfct_get_option('cfct_ajax_load') == 'yes') { + cfct_ajax_load(); } - - protected function remove_hooks() { - remove_action($this->start_action, array($this, 'start')); - remove_action($this->end_action, array($this, 'end')); - } - - public function start() { - ob_start($this->callback); - $this->ob_started = true; - } - - public function end() { - /* Check if this function is running before $this->start() gets a chance to run. - This could happen if the end action passed runs before the start action. Under - no circumstances do you want that to happen. If it does, throw a traceable error - so we know what's going on. */ - if ($this->ob_started !== true) { - throw new Exception("Uh-oh! Method end() ran before start(). This can happen if the end action you provided runs before the start action. Make sure you specify an end action that always runs after the start action.", 1); - } - ob_end_flush(); + if (cfct_get_option('cfct_lightbox') != 'no' && !is_admin()) { + wp_enqueue_script('cfct_thickbox', get_bloginfo('template_directory').'/carrington-core/lightbox/thickbox.js', array('jquery'), '1.0'); +// in the future we'll use this, but for now we want 2.5 compatibility +// wp_enqueue_style('jquery-lightbox', get_bloginfo('template_directory').'/carrington-core/lightbox/css/lightbox.css'); } } +add_action('init', 'cfct_blog_init'); -/** - * A collection of filters for comment_form(). - * Usage: CFCT_Comment_Form::setup(); - */ -class CFCT_Comment_Form { - public static $i18n = 'carrington-blog'; - protected static $instance; - protected static $hooks_attached = false; - - /** - * Singleton factory method - * @return object instance of CFCT_Comment_Form - */ - public static function get_instance() { - if (!self::$instance) { - self::$instance = new CFCT_Comment_Form(); - } - return self::$instance; - } - - /** - * Convenient factory method that instantiates single instance and - * attaches hooks automatically. - * @return object instance of CFCT_Comment_Form - */ - public static function setup() { - $ins = self::get_instance(); - $ins->attach_hooks(); - return $ins; - } - - /** - * Attach hooks to WordPress. Runs only once. - * @uses CFCT_OB_On_Action - */ - public function attach_hooks() { - if (self::$hooks_attached === true) { - return false; - } - add_action('comment_form_defaults', array($this, 'configure_args')); - add_filter('comment_id_fields', array($this, 'comment_id_fields'), 10, 3); - - // Set up an output buffer so we can do string replacements on areas that aren't filterable. - new CFCT_OB_On_Action('comment_form_before', 'comment_form_after', array($this, 'ob_callback')); - - self::$hooks_attached = true; - } - - public function ob_callback($buffer) { - global $post; - $mod = 'p'.$post->ID; - $buffer = strtr($buffer, array( - 'id="respond"' => 'id="respond-'.$mod.'" class="respond"', - 'id="commentform"' => 'class="comment-form"', - 'id="reply-title"' => 'class="comment-form-title"', +wp_enqueue_script('jquery'); +wp_enqueue_script('carrington', get_bloginfo('template_directory').'/js/carrington.js', array('jquery'), '1.0'); - 'id="author"' => 'id="author-'.$mod.'"', - 'for="author"' => 'for="author-'.$mod.'"', - - 'id="email"' => 'id="email-'.$mod.'"', - 'for="email"' => 'for="email-'.$mod.'"', +// Filter comment reply link to work with namespaced comment-reply javascript. +add_filter('cancel_comment_reply_link', 'cfct_get_cancel_comment_reply_link', 10, 3); - 'id="url"' => 'id="url-'.$mod.'"', - 'for="url"' => 'for="url-'.$mod.'"', - - 'id="comment"' => 'id="comment-'.$mod.'"' - )); - - return $buffer; +function cfct_blog_head() { +// see enqueued style in cfct_blog_init, we'll activate that in the future + if (cfct_get_option('cfct_lightbox') != 'no') { + echo ' +<link rel="stylesheet" type="text/css" media="screen" href="'.get_bloginfo('template_directory').'/carrington-core/lightbox/css/thickbox.css" /> + '; } - - public function comment_id_fields($result, $id, $replytoid) { - // Remove default WP comment ID fields - $result = ''; - - // Add trackback link, since this function renders right next to the submit button - $result .= ' <span class="comment-form-trackback">'.sprintf(__('or, reply to this post via <a rel="trackback" href="%s">trackback</a>.', self::$i18n), get_trackback_url()).'</span>'; - - // Add our customized comment ID fields - $result .= cfct_get_comment_id_fields($id, $replytoid); - return $result; + cfct_get_option('cfct_ajax_load') == 'no' ? $ajax_load = 'false' : $ajax_load = 'true'; + echo ' +<script type="text/javascript"> +var CFCT_URL = "'.get_bloginfo('url').'"; +var CFCT_AJAX_LOAD = '.$ajax_load.'; +</script> + '; + if (cfct_get_option('cfct_lightbox') != 'no') { + echo ' +<script type="text/javascript"> +tb_pathToImage = "' . get_bloginfo('template_directory') . '/carrington-core/lightbox/img/loadingAnimation.gif"; +jQuery(function($) { + $("a.thickbox").each(function() { + var url = $(this).attr("rel"); + var post_id = $(this).parents("div.post, div.page").attr("id"); + $(this).attr("href", url).attr("rel", post_id); + }); +}); +</script> + '; } - - /** - * Attach to 'configure_args' hook - */ - public function configure_args($default_args) { - $commenter = wp_get_current_commenter(); - $req = get_option( 'require_name_email' ); - - $author_help = ($req ? __('(required)', self::$i18n) : ''); - $email_help = ($req ? __('(required, but never shared)', self::$i18n) : __('(never shared)', self::$i18n)); - - $fields = array( - 'author' => self::to_input_block(__( 'Name', self::$i18n ), 'author', $commenter['comment_author'], $req, $author_help), - 'email' => self::to_input_block(__( 'Email', self::$i18n ), 'email', $commenter['comment_author_email'], $req, $email_help), - 'url' => self::to_input_block(__( 'Web', self::$i18n ), 'url', $commenter['comment_author_url']) - ); - - $textarea = self::to_tag('textarea', '', array( - 'name' => 'comment', - 'id' => 'comment', - 'rows' => 6, - 'cols' => 60, - 'required' => 'required' - )); - - $comment_field = self::to_tag('p', $textarea, array('class' => 'comment-form-comment')); - - $html_tags = sprintf(__('You can use: %s', self::$i18n), esc_attr(allowed_tags())); - - $args = array( - 'fields' => $fields, - 'comment_field' => $comment_field, - 'label_submit' => __('Post Comment', self::$i18n), - 'cancel_reply_link' => __('Cancel reply', self::$i18n), - 'comment_notes_after' => '<small class="help some-html-is-ok"><abbr title="'.$html_tags.'">'.__('Some HTML is OK', 'carrington-text').'</abbr></small>', - 'comment_notes_before' => '' - ); - return array_merge($default_args, $args); +// preview + if (isset($_GET['cfct_action']) && $_GET['cfct_action'] == 'custom_color_preview' && current_user_can('manage_options')) { + cfct_blog_custom_colors('preview'); } - - /** - * Helper: Turn an array or two into HTML attribute string - */ - public static function to_attr($arr1 = array(), $arr2 = array()) { - $attrs = array(); - $arr = array_merge($arr1, $arr2); - foreach ($arr as $key => $value) { - if (function_exists('esc_attr')) { - $key = esc_attr($key); - $value = esc_attr($value); - } - $attrs[] = $key.'="'.$value.'"'; - } - return implode(' ', $attrs); + else if (cfct_get_option('cfct_custom_colors') == 'yes') { + cfct_blog_custom_colors(); } - - /** - * Helper for creating HTML tag from strings and arrays of attributes. - */ - public static function to_tag($tag, $text = '', $attr1 = array(), $attr2 = array()) { - if (function_exists('esc_attr')) { - $tag = esc_attr($tag); - } - $attrs = self::to_attr($attr1, $attr2); - if ($text !== false) { - $tag = '<'.$tag.' '.$attrs.'>'.$text.'</'.$tag.'>'; + if (cfct_get_option('cfct_custom_header_image') == 'yes') { + $header_image = cfct_get_option('cfct_header_image'); + if ($header_image != 0 && $img = wp_get_attachment_image_src($header_image, 'large')) { +?> +<style type="text/css"> +#header .wrapper { + background-image: url(<?php echo $img[0]; ?>); + background-repeat: no-repeat; + height: <?php echo $img[2]; ?>px; +} +</style> +<?php } - // No text == self closing tag else { - $tag = '<'.$tag.' '.$attrs.' />'; +?> +<style type="text/css"> +#header .wrapper { + background-image: url(); +} +</style> +<?php } - - return $tag; } - - public static function to_input_block($label, $id, $value, $req = null, $help_text = '') { - $label = self::to_tag('label', $label, array('for' => $id)); - - $maybe_req = ($req ? array('required' => 'required') : array() ); - $input_defaults = array( - 'id' => $id, - 'name' => $id, - 'class' => 'type-text', - 'value' => $value - ); - $input = self::to_tag('input', false, $input_defaults, $maybe_req); - - $help = ''; - if ($help_text) { - $help = self::to_tag('small', $help_text, array('class' => 'help')); - } - - return self::to_tag('p', $input . ' ' . $label . ' ' . $help, array( - 'class' => 'comment-form-user-info tight' - )); +} +add_action('wp_head', 'cfct_blog_head'); + +function cfct_blog_custom_colors($type = 'option') { + $colors = cfct_get_custom_colors($type); + if (get_option('cfct_header_image_type') == 'light') { + $header_img_type = 'light'; + $header_grad_type = 'dark'; } + else { + $header_img_type = 'dark'; + $header_grad_type = 'light'; + } + get_option('cfct_footer_image_type') == 'light' ? $footer_img_type = 'light' : $footer_img_type = 'dark'; +?> +<style type="text/css"> +#header { + background-color: #<?php echo $colors['cfct_header_background_color']; ?>; + color: #<?php echo $colors['cfct_header_text_color']; ?>; +} +#header a, +#header a:visited { + color: #<?php echo $colors['cfct_header_link_color']; ?>; +} +#sub-header, +.nav ul{ + background-color: #<?php echo $colors['cfct_header_nav_background_color']; ?>; + color: #<?php echo $colors['cfct_header_nav_text_color']; ?>; +} +#sub-header a, +#sub-header a:visited, +.nav li li a, +.nav li li a:visited { + color: #<?php echo $colors['cfct_header_nav_link_color']; ?> !important; +} +h1, +h1 a, +h1 a:hover, +h1 a:visited { + color: #<?php echo $colors['cfct_page_title_color']; ?>; +} +h2, +h2 a, +h2 a:hover, +h2 a:visited { + color: #<?php echo $colors['cfct_page_subtitle_color']; ?>; +} +a, +a:hover, +a:visited { + color: #<?php echo $colors['cfct_link_color']; ?>; +} +.hentry .edit, +.hentry .edit a, +.hentry .edit a:visited, +.hentry .edit a:hover, +.comment-reply-link, +.comment-reply-link:visited, +.comment-reply-link:hover { + background-color: #<?php echo $colors['cfct_link_color']; ?>; +} +#footer { + background-color: #<?php echo $colors['cfct_footer_background_color']; ?>; + color: #<?php echo $colors['cfct_footer_text_color']; ?>; +} +#footer a, +#footer a:visited { + color: #<?php echo $colors['cfct_footer_link_color']; ?>; +} +#footer p#developer-link a, +#footer p#developer-link a:visited { + background-image: url(<?php bloginfo('template_directory'); ?>/img/footer/by-crowd-favorite-<?php echo $footer_img_type; ?>.png); } -CFCT_Comment_Form::setup(); +<?php + if (cfct_get_option('cfct_css_background_images') != 'no') { +?> +#header { + background-image: url(<?php bloginfo('template_directory'); ?>/img/header/gradient-<?php echo $header_grad_type; ?>.png); +} +#header .wrapper { + background-image: url(<?php bloginfo('template_directory'); ?>/img/header/texture-<?php echo $header_img_type; ?>.png); +} +#footer { + background-image: url(<?php bloginfo('template_directory'); ?>/img/footer/gradient-<?php echo $footer_img_type; ?>.png); +} +<?php + } +?> +</style> +<?php + +} + +include_once(CFCT_PATH.'functions/admin.php'); +include_once(CFCT_PATH.'functions/sidebars.php'); + +include_once(CFCT_PATH.'carrington-core/carrington.php'); + ?> \ No newline at end of file diff --git a/wp-content/themes/carrington-blog/functions/README.txt b/wp-content/themes/carrington-blog/functions/README.txt new file mode 100644 index 000000000..e262d06f4 --- /dev/null +++ b/wp-content/themes/carrington-blog/functions/README.txt @@ -0,0 +1,5 @@ +## functions/ + +This directory contains custom features and functionality for this particular Carrington based theme. + +This directory is not used by the Carrington engine (template naming conventions are not supported), it is provided solely for convenience and for better organization of these files. \ No newline at end of file diff --git a/wp-content/themes/carrington-blog/functions/admin.php b/wp-content/themes/carrington-blog/functions/admin.php index 3269a577b..173f179ed 100644 --- a/wp-content/themes/carrington-blog/functions/admin.php +++ b/wp-content/themes/carrington-blog/functions/admin.php @@ -36,10 +36,13 @@ function cfct_blog_settings_form() { foreach ($values as $k => $v) { foreach ($settings as $setting) { $options = $setting.'_options'; - if (empty($$options)) { - $$options = ''; + if ($k == cfct_get_option($setting)) { + $selected = 'selected="selected"'; } - $$options .= "\n\t".'<option value="'.$k.'" '.selected($k, cfct_get_option($setting), false).'>'.$v.'</option>'; + else { + $selected = ''; + } + $$options .= "\n\t<option value='$k' $selected>$v</option>"; } } $cfct_posts_per_archive_page = get_option('cfct_posts_per_archive_page'); @@ -52,7 +55,7 @@ function cfct_blog_settings_form() { <table class="form-table"> <tbody> <tr valign="top"> - <th scope="row">'.__('Design', 'carrington-blog').'</td> + <th scope="row">'.sprintf(__('Design', 'carrington-blog'), $key).'</td> <td> <fieldset> <p> @@ -104,7 +107,7 @@ function cfct_blog_settings_form() { <table class="form-table"> <tbody> <tr valign="top"> - <th scope="row">'.__('Behavior', 'carrington-blog').'</td> + <th scope="row">'.sprintf(__('Behavior', 'carrington-blog'), $key).'</td> <td> <fieldset> <p> @@ -259,7 +262,7 @@ function cfct_blog_admin_css() { '; } // our copy of thickbox used for color previews -if (is_admin() && isset($_GET['page']) && $_GET['page'] == 'carrington-settings') { +if (is_admin() && $_GET['page'] == 'carrington-settings') { add_action('admin_head', 'cfct_blog_admin_css'); wp_enqueue_script('cfct_thickbox', get_bloginfo('template_directory').'/carrington-core/lightbox/thickbox.js', array('jquery'), '1.0'); } diff --git a/wp-content/themes/carrington-blog/functions/sidebars.php b/wp-content/themes/carrington-blog/functions/sidebars.php new file mode 100644 index 000000000..5b6137bcb --- /dev/null +++ b/wp-content/themes/carrington-blog/functions/sidebars.php @@ -0,0 +1,42 @@ +<?php + +// This file is part of the Carrington Blog Theme for WordPress +// http://carringtontheme.com +// +// Copyright (c) 2008-2010 Crowd Favorite, Ltd. All rights reserved. +// http://crowdfavorite.com +// +// Released under the GPL license +// http://www.opensource.org/licenses/gpl-license.php +// +// ********************************************************************** +// This program is distributed in the hope that it will be useful, but +// WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. +// ********************************************************************** + +if (__FILE__ == $_SERVER['SCRIPT_FILENAME']) { die(); } + +if (function_exists('register_sidebar')) { + register_sidebar( + array( + 'name' => 'Primary Sidebar', + 'before_widget' => '<div id="%1$s" class="widget %2$s">', + 'after_widget' => '<div class="clear"></div></div>', + 'before_title' => '<h2 class="widget-title">', + 'after_title' => '</h2>' + ) + ); + register_sidebar( + array( + 'name' => 'Secondary Sidebar', + 'before_widget' => '<div id="%1$s" class="widget %2$s">', + 'after_widget' => '<div class="clear"></div></div>', + 'before_title' => '<h2 class="widget-title">', + 'after_title' => '</h2>' + ) + ); +} + + +?> \ No newline at end of file diff --git a/wp-content/themes/carrington-blog/header/README.txt b/wp-content/themes/carrington-blog/header/README.txt new file mode 100644 index 000000000..9ac0bd960 --- /dev/null +++ b/wp-content/themes/carrington-blog/header/README.txt @@ -0,0 +1,42 @@ +## header/ + +The standard _header.php_ file in Carrington is set up to call the `cfct_header()` function, which will choose the appropriate header file from this directory - based on the context of the given page. This can be useful if you want to have pages to have a custom header, or perhaps a certain category to have a custom header. + + +## General Context + +When choosing a template to use in the General Context, the Carrington engine looks at the type of request is being fulfilled. It will identify the request as the home page, a category archive, and individual post, etc. + +There is additional checking done for single post requests. All options in the Content Context are supported here with a 'single-' prefix added to the file. See specifics below. + +A "default" template is required, and will be used when there are no other templates that match a given comment. This could be because no other templates have been created, or because the comment in question doesn't match the templates that are available. + +By default, conditions are checked in this order: + +1. author +2. role +3. category +4. tag +5. single +6. default (home, search, archive, 404, etc.) + +This can be altered using the `cfct_general_match_order` hook. + + +### Supported Templates (General Context) + +- *{dirname}-default.php* (or default.php) - Used when there are no other templates that match for a given page/post. +- *archive.php* - Used for date archives or if there are no specific category, author or tag templates. +- *author.php* - Used for author archive lists. +- *author-{username}.php* - Used when the post/page is authored by a specific user. For example, a template with a file name of _author-jsmith.php_ would be used for a post/page by user _jsmith_. Any WordPress username can take the place of {username} in the file name. +- *role-{rolename}.php - Used when the post author has a particular role. This might be the role of _contributor_, _author_, _editor_, etc. and use a file of _role-contributor.php_, _role_author.php_, etc. where the role name takes the place of the {rolename} in the file name. +- *category.php* - Used for category archive lists. +- *cat-{slug}.php* - Used fr displaying a given category. The category is matched by the "slug" - for example a post in category "General" (with a category slug of "general") could use a template of _cat-general.php_. +- *home.php* - Used when on the home page. +- *page.php* - Used for pages that do not match any other contextual templates. +- *search.php* - Used when displaying search results. +- *single.php* - Used for single post pages. +- *single-{content context filenames}.php* - Used for single post pages. +- *tag.php* - Used for tag archive lists. +- *tag-{slug}.php* - Used for displaying a given tag. The tag is matched by the "slug" - for example a post in tag "News" (with a tag slug of "news") could use a template of _tag-news.php_. + diff --git a/wp-content/themes/carrington-blog/header/header-default.php b/wp-content/themes/carrington-blog/header/header-default.php index 1c2e04feb..dae6e72f1 100644 --- a/wp-content/themes/carrington-blog/header/header-default.php +++ b/wp-content/themes/carrington-blog/header/header-default.php @@ -25,16 +25,37 @@ $use_background_img = cfct_get_option('cfct_css_background_images'); $use_background_img == 'no' ? $css_ext = '?type=noimg' : $css_ext = ''; ?> -<!DOCTYPE html> -<html <?php language_attributes() ?>> -<head> - <meta charset="<?php bloginfo('charset') ?>" /> +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> +<html xmlns="http://www.w3.org/1999/xhtml" <?php language_attributes() ?>> +<head profile="http://gmpg.org/xfn/11"> + <meta http-equiv="content-type" content="<?php bloginfo('html_type') ?>; charset=<?php bloginfo('charset') ?>" /> - <title><?php wp_title( '-', true, 'right' ); echo esc_html( get_bloginfo('name') ).$title_description; ?></title> + <title><?php wp_title( '-', true, 'right' ); echo wp_specialchars( get_bloginfo('name'), 1 ).$title_description; ?></title> + + <link rel="alternate" type="application/rss+xml" href="<?php bloginfo('rss2_url') ?>" title="<?php printf( __( '%s latest posts', 'carrington' ), wp_specialchars( get_bloginfo('name'), 1 ) ) ?>" /> + <link rel="alternate" type="application/rss+xml" href="<?php bloginfo('comments_rss2_url') ?>" title="<?php printf( __( '%s latest comments', 'carrington' ), wp_specialchars( get_bloginfo('name'), 1 ) ) ?>" /> + <link rel="pingback" href="<?php bloginfo('pingback_url') ?>" /> + <?php wp_get_archives('type=monthly&format=link'); ?> + + <link rel="stylesheet" type="text/css" media="screen" href="<?php bloginfo('template_url') ?>/css/css.php<?php echo $css_ext; ?>" /> + + <!--[if lte IE 7]> + <link rel="stylesheet" href="<?php bloginfo('template_directory') ?>/css/ie.css" type="text/css" media="screen" /> + <![endif]--> + + <!--[if lte IE 6]> + <link rel="stylesheet" href="<?php bloginfo('template_directory') ?>/css/ie6.css" type="text/css" media="screen" /> + + <script type="text/javascript" src="<?php bloginfo('template_directory'); ?>/js/DD_belatedPNG.js"></script> + <script type="text/javascript"> + DD_belatedPNG.fix('img, <?php if ($use_background_img == 'yes') { echo '#header, #footer, #header .wrapper, #footer .wrapper, #TB_title, '; } ?>#developer-link a'); + </script> + <![endif]--> <?php wp_head(); ?> </head> -<body <?php body_class(); ?>> + +<body> <div id="page"> <div id="top"><a class="accessibility" href="#content"><?php _e( 'Skip to content', 'carrington-blog' ); ?></a></div> <hr class="lofi" /> diff --git a/wp-content/themes/carrington-blog/img/README.txt b/wp-content/themes/carrington-blog/img/README.txt new file mode 100644 index 000000000..4f77994b3 --- /dev/null +++ b/wp-content/themes/carrington-blog/img/README.txt @@ -0,0 +1,5 @@ +## img/ + +Organizational folder for holding theme image files. + +This directory is not used by the Carrington engine (template naming conventions are not supported), it is provided solely for convenience and for better organization of these files. \ No newline at end of file diff --git a/wp-content/themes/carrington-blog/assets/img/arrow-bullet.gif b/wp-content/themes/carrington-blog/img/arrow-bullet.gif similarity index 100% rename from wp-content/themes/carrington-blog/assets/img/arrow-bullet.gif rename to wp-content/themes/carrington-blog/img/arrow-bullet.gif diff --git a/wp-content/themes/carrington-blog/assets/img/attachment/150px-flourish-left-dark.png b/wp-content/themes/carrington-blog/img/attachment/150px-flourish-left-dark.png similarity index 100% rename from wp-content/themes/carrington-blog/assets/img/attachment/150px-flourish-left-dark.png rename to wp-content/themes/carrington-blog/img/attachment/150px-flourish-left-dark.png diff --git a/wp-content/themes/carrington-blog/assets/img/attachment/150px-flourish-left-light.png b/wp-content/themes/carrington-blog/img/attachment/150px-flourish-left-light.png similarity index 100% rename from wp-content/themes/carrington-blog/assets/img/attachment/150px-flourish-left-light.png rename to wp-content/themes/carrington-blog/img/attachment/150px-flourish-left-light.png diff --git a/wp-content/themes/carrington-blog/assets/img/attachment/150px-flourish-right-dark.png b/wp-content/themes/carrington-blog/img/attachment/150px-flourish-right-dark.png similarity index 100% rename from wp-content/themes/carrington-blog/assets/img/attachment/150px-flourish-right-dark.png rename to wp-content/themes/carrington-blog/img/attachment/150px-flourish-right-dark.png diff --git a/wp-content/themes/carrington-blog/assets/img/attachment/150px-flourish-right-light.png b/wp-content/themes/carrington-blog/img/attachment/150px-flourish-right-light.png similarity index 100% rename from wp-content/themes/carrington-blog/assets/img/attachment/150px-flourish-right-light.png rename to wp-content/themes/carrington-blog/img/attachment/150px-flourish-right-light.png diff --git a/wp-content/themes/carrington-blog/assets/img/author-comment.jpg b/wp-content/themes/carrington-blog/img/author-comment.jpg similarity index 100% rename from wp-content/themes/carrington-blog/assets/img/author-comment.jpg rename to wp-content/themes/carrington-blog/img/author-comment.jpg diff --git a/wp-content/themes/carrington-blog/assets/img/comment-reply.gif b/wp-content/themes/carrington-blog/img/comment-reply.gif similarity index 100% rename from wp-content/themes/carrington-blog/assets/img/comment-reply.gif rename to wp-content/themes/carrington-blog/img/comment-reply.gif diff --git a/wp-content/themes/carrington-blog/assets/img/comment-thread.gif b/wp-content/themes/carrington-blog/img/comment-thread.gif similarity index 100% rename from wp-content/themes/carrington-blog/assets/img/comment-thread.gif rename to wp-content/themes/carrington-blog/img/comment-thread.gif diff --git a/wp-content/themes/carrington-blog/assets/img/comment.gif b/wp-content/themes/carrington-blog/img/comment.gif similarity index 100% rename from wp-content/themes/carrington-blog/assets/img/comment.gif rename to wp-content/themes/carrington-blog/img/comment.gif diff --git a/wp-content/themes/carrington-blog/assets/img/comments-divider.gif b/wp-content/themes/carrington-blog/img/comments-divider.gif similarity index 100% rename from wp-content/themes/carrington-blog/assets/img/comments-divider.gif rename to wp-content/themes/carrington-blog/img/comments-divider.gif diff --git a/wp-content/themes/carrington-blog/assets/img/divider-ornament-wide-dark.png b/wp-content/themes/carrington-blog/img/divider-ornament-wide-dark.png similarity index 100% rename from wp-content/themes/carrington-blog/assets/img/divider-ornament-wide-dark.png rename to wp-content/themes/carrington-blog/img/divider-ornament-wide-dark.png diff --git a/wp-content/themes/carrington-blog/assets/img/divider-ornament-wide.gif b/wp-content/themes/carrington-blog/img/divider-ornament-wide.gif similarity index 100% rename from wp-content/themes/carrington-blog/assets/img/divider-ornament-wide.gif rename to wp-content/themes/carrington-blog/img/divider-ornament-wide.gif diff --git a/wp-content/themes/carrington-blog/assets/img/divider-ornament.gif b/wp-content/themes/carrington-blog/img/divider-ornament.gif similarity index 100% rename from wp-content/themes/carrington-blog/assets/img/divider-ornament.gif rename to wp-content/themes/carrington-blog/img/divider-ornament.gif diff --git a/wp-content/themes/carrington-blog/assets/img/dropdown-divider.gif b/wp-content/themes/carrington-blog/img/dropdown-divider.gif similarity index 100% rename from wp-content/themes/carrington-blog/assets/img/dropdown-divider.gif rename to wp-content/themes/carrington-blog/img/dropdown-divider.gif diff --git a/wp-content/themes/carrington-blog/assets/img/footer/by-crowd-favorite-dark.png b/wp-content/themes/carrington-blog/img/footer/by-crowd-favorite-dark.png similarity index 100% rename from wp-content/themes/carrington-blog/assets/img/footer/by-crowd-favorite-dark.png rename to wp-content/themes/carrington-blog/img/footer/by-crowd-favorite-dark.png diff --git a/wp-content/themes/carrington-blog/assets/img/footer/by-crowd-favorite-light.png b/wp-content/themes/carrington-blog/img/footer/by-crowd-favorite-light.png similarity index 100% rename from wp-content/themes/carrington-blog/assets/img/footer/by-crowd-favorite-light.png rename to wp-content/themes/carrington-blog/img/footer/by-crowd-favorite-light.png diff --git a/wp-content/themes/carrington-blog/assets/img/footer/divider-ornament-wide-light.png b/wp-content/themes/carrington-blog/img/footer/divider-ornament-wide-light.png similarity index 100% rename from wp-content/themes/carrington-blog/assets/img/footer/divider-ornament-wide-light.png rename to wp-content/themes/carrington-blog/img/footer/divider-ornament-wide-light.png diff --git a/wp-content/themes/carrington-blog/assets/img/footer/gradient-dark.png b/wp-content/themes/carrington-blog/img/footer/gradient-dark.png similarity index 100% rename from wp-content/themes/carrington-blog/assets/img/footer/gradient-dark.png rename to wp-content/themes/carrington-blog/img/footer/gradient-dark.png diff --git a/wp-content/themes/carrington-blog/assets/img/footer/gradient-light.png b/wp-content/themes/carrington-blog/img/footer/gradient-light.png similarity index 100% rename from wp-content/themes/carrington-blog/assets/img/footer/gradient-light.png rename to wp-content/themes/carrington-blog/img/footer/gradient-light.png diff --git a/wp-content/themes/carrington-blog/assets/img/grey-to-white-gradient.png b/wp-content/themes/carrington-blog/img/grey-to-white-gradient.png similarity index 100% rename from wp-content/themes/carrington-blog/assets/img/grey-to-white-gradient.png rename to wp-content/themes/carrington-blog/img/grey-to-white-gradient.png diff --git a/wp-content/themes/carrington-blog/assets/img/header/gradient-dark.png b/wp-content/themes/carrington-blog/img/header/gradient-dark.png similarity index 100% rename from wp-content/themes/carrington-blog/assets/img/header/gradient-dark.png rename to wp-content/themes/carrington-blog/img/header/gradient-dark.png diff --git a/wp-content/themes/carrington-blog/assets/img/header/gradient-light.png b/wp-content/themes/carrington-blog/img/header/gradient-light.png similarity index 100% rename from wp-content/themes/carrington-blog/assets/img/header/gradient-light.png rename to wp-content/themes/carrington-blog/img/header/gradient-light.png diff --git a/wp-content/themes/carrington-blog/assets/img/header/texture-dark.png b/wp-content/themes/carrington-blog/img/header/texture-dark.png similarity index 100% rename from wp-content/themes/carrington-blog/assets/img/header/texture-dark.png rename to wp-content/themes/carrington-blog/img/header/texture-dark.png diff --git a/wp-content/themes/carrington-blog/assets/img/header/texture-light.png b/wp-content/themes/carrington-blog/img/header/texture-light.png similarity index 100% rename from wp-content/themes/carrington-blog/assets/img/header/texture-light.png rename to wp-content/themes/carrington-blog/img/header/texture-light.png diff --git a/wp-content/themes/carrington-blog/assets/img/lightbox/nextlabel.gif b/wp-content/themes/carrington-blog/img/lightbox/nextlabel.gif similarity index 100% rename from wp-content/themes/carrington-blog/assets/img/lightbox/nextlabel.gif rename to wp-content/themes/carrington-blog/img/lightbox/nextlabel.gif diff --git a/wp-content/themes/carrington-blog/assets/img/lightbox/prevlabel.gif b/wp-content/themes/carrington-blog/img/lightbox/prevlabel.gif similarity index 100% rename from wp-content/themes/carrington-blog/assets/img/lightbox/prevlabel.gif rename to wp-content/themes/carrington-blog/img/lightbox/prevlabel.gif diff --git a/wp-content/themes/carrington-blog/assets/img/ndash.gif b/wp-content/themes/carrington-blog/img/ndash.gif similarity index 100% rename from wp-content/themes/carrington-blog/assets/img/ndash.gif rename to wp-content/themes/carrington-blog/img/ndash.gif diff --git a/wp-content/themes/carrington-blog/assets/img/rss-button.gif b/wp-content/themes/carrington-blog/img/rss-button.gif similarity index 100% rename from wp-content/themes/carrington-blog/assets/img/rss-button.gif rename to wp-content/themes/carrington-blog/img/rss-button.gif diff --git a/wp-content/themes/carrington-blog/assets/img/sidebar-background.gif b/wp-content/themes/carrington-blog/img/sidebar-background.gif similarity index 100% rename from wp-content/themes/carrington-blog/assets/img/sidebar-background.gif rename to wp-content/themes/carrington-blog/img/sidebar-background.gif diff --git a/wp-content/themes/carrington-blog/assets/img/spinner.gif b/wp-content/themes/carrington-blog/img/spinner.gif similarity index 100% rename from wp-content/themes/carrington-blog/assets/img/spinner.gif rename to wp-content/themes/carrington-blog/img/spinner.gif diff --git a/wp-content/themes/carrington-blog/assets/img/sub-header-border-bottom.gif b/wp-content/themes/carrington-blog/img/sub-header-border-bottom.gif similarity index 100% rename from wp-content/themes/carrington-blog/assets/img/sub-header-border-bottom.gif rename to wp-content/themes/carrington-blog/img/sub-header-border-bottom.gif diff --git a/wp-content/themes/carrington-blog/assets/img/watermark-light.gif b/wp-content/themes/carrington-blog/img/watermark-light.gif similarity index 100% rename from wp-content/themes/carrington-blog/assets/img/watermark-light.gif rename to wp-content/themes/carrington-blog/img/watermark-light.gif diff --git a/wp-content/themes/carrington-blog/assets/js/DD_belatedPNG.js b/wp-content/themes/carrington-blog/js/DD_belatedPNG.js similarity index 100% rename from wp-content/themes/carrington-blog/assets/js/DD_belatedPNG.js rename to wp-content/themes/carrington-blog/js/DD_belatedPNG.js diff --git a/wp-content/themes/carrington-blog/js/README.txt b/wp-content/themes/carrington-blog/js/README.txt new file mode 100644 index 000000000..4de7497d4 --- /dev/null +++ b/wp-content/themes/carrington-blog/js/README.txt @@ -0,0 +1,5 @@ +## js/ + +Organizational folder for holding theme JavaScript files. + +This directory is not used by the Carrington engine (template naming conventions are not supported), it is provided solely for convenience and for better organization of these files. \ No newline at end of file diff --git a/wp-content/themes/carrington-blog/assets/js/carrington.js b/wp-content/themes/carrington-blog/js/carrington.js similarity index 100% rename from wp-content/themes/carrington-blog/assets/js/carrington.js rename to wp-content/themes/carrington-blog/js/carrington.js diff --git a/wp-content/themes/carrington-blog/assets/js/iepngfix_tilebg.js b/wp-content/themes/carrington-blog/js/iepngfix_tilebg.js old mode 100755 new mode 100644 similarity index 95% rename from wp-content/themes/carrington-blog/assets/js/iepngfix_tilebg.js rename to wp-content/themes/carrington-blog/js/iepngfix_tilebg.js index 1a5863011..41dc83113 --- a/wp-content/themes/carrington-blog/assets/js/iepngfix_tilebg.js +++ b/wp-content/themes/carrington-blog/js/iepngfix_tilebg.js @@ -1,173 +1,173 @@ -// IE5.5+ PNG Alpha Fix v2.0 Alpha: Background Tiling Support -// (c) 2008 Angus Turnbull http://www.twinhelix.com - -// This is licensed under the GNU LGPL, version 2.1 or later. -// For details, see: http://creativecommons.org/licenses/LGPL/2.1/ - -var IEPNGFix = window.IEPNGFix || {}; - -IEPNGFix.tileBG = function(elm, pngSrc, ready) { - // Params: A reference to a DOM element, the PNG src file pathname, and a - // hidden "ready-to-run" passed when called back after image preloading. - - var data = this.data[elm.uniqueID], - elmW = Math.max(elm.clientWidth, elm.scrollWidth), - elmH = Math.max(elm.clientHeight, elm.scrollHeight), - bgX = elm.currentStyle.backgroundPositionX, - bgY = elm.currentStyle.backgroundPositionY, - bgR = elm.currentStyle.backgroundRepeat; - - // Cache of DIVs created per element, and image preloader/data. - if (!data.tiles) { - data.tiles = { - elm: elm, - src: '', - cache: [], - img: new Image(), - old: {} - }; - } - var tiles = data.tiles, - pngW = tiles.img.width, - pngH = tiles.img.height; - - if (pngSrc) { - if (!ready && pngSrc != tiles.src) { - // New image? Preload it with a callback to detect dimensions. - tiles.img.onload = function() { - this.onload = null; - IEPNGFix.tileBG(elm, pngSrc, 1); - }; - return tiles.img.src = pngSrc; - } - } else { - // No image? - if (tiles.src) ready = 1; - pngW = pngH = 0; - } - tiles.src = pngSrc; - - if (!ready && elmW == tiles.old.w && elmH == tiles.old.h && - bgX == tiles.old.x && bgY == tiles.old.y && bgR == tiles.old.r) { - return; - } - - // Convert English and percentage positions to pixels. - var pos = { - top: '0%', - left: '0%', - center: '50%', - bottom: '100%', - right: '100%' - }, - x, - y, - pc; - x = pos[bgX] || bgX; - y = pos[bgY] || bgY; - if (pc = x.match(/(\d+)%/)) { - x = Math.round((elmW - pngW) * (parseInt(pc[1]) / 100)); - } - if (pc = y.match(/(\d+)%/)) { - y = Math.round((elmH - pngH) * (parseInt(pc[1]) / 100)); - } - x = parseInt(x); - y = parseInt(y); - - // Handle backgroundRepeat. - var repeatX = { 'repeat': 1, 'repeat-x': 1 }[bgR], - repeatY = { 'repeat': 1, 'repeat-y': 1 }[bgR]; - if (repeatX) { - x %= pngW; - if (x > 0) x -= pngW; - } - if (repeatY) { - y %= pngH; - if (y > 0) y -= pngH; - } - - // Go! - this.hook.enabled = 0; - if (!({ relative: 1, absolute: 1 }[elm.currentStyle.position])) { - elm.style.position = 'relative'; - } - var count = 0, - xPos, - maxX = repeatX ? elmW : x + 0.1, - yPos, - maxY = repeatY ? elmH : y + 0.1, - d, - s, - isNew; - if (pngW && pngH) { - for (xPos = x; xPos < maxX; xPos += pngW) { - for (yPos = y; yPos < maxY; yPos += pngH) { - isNew = 0; - if (!tiles.cache[count]) { - tiles.cache[count] = document.createElement('div'); - isNew = 1; - } - var clipR = (xPos + pngW > elmW ? elmW - xPos : pngW), - clipB = (yPos + pngH > elmH ? elmH - yPos : pngH); - d = tiles.cache[count]; - s = d.style; - s.behavior = 'none'; - s.left = xPos + 'px'; - s.top = yPos + 'px'; - s.width = clipR + 'px'; - s.height = clipB + 'px'; - s.clip = 'rect(' + - (yPos < 0 ? 0 - yPos : 0) + 'px,' + - clipR + 'px,' + - clipB + 'px,' + - (xPos < 0 ? 0 - xPos : 0) + 'px)'; - s.display = 'block'; - if (isNew) { - s.position = 'absolute'; - s.zIndex = -999; - if (elm.firstChild) { - elm.insertBefore(d, elm.firstChild); - } else { - elm.appendChild(d); - } - } - this.fix(d, pngSrc, 0); - count++; - } - } - } - while (count < tiles.cache.length) { - this.fix(tiles.cache[count], '', 0); - tiles.cache[count++].style.display = 'none'; - } - - this.hook.enabled = 1; - - // Cache so updates are infrequent. - tiles.old = { - w: elmW, - h: elmH, - x: bgX, - y: bgY, - r: bgR - }; -}; - - -IEPNGFix.update = function() { - // Update all PNG backgrounds. - for (var i in IEPNGFix.data) { - var t = IEPNGFix.data[i].tiles; - if (t && t.elm && t.src) { - IEPNGFix.tileBG(t.elm, t.src); - } - } -}; -IEPNGFix.update.timer = 0; - -if (window.attachEvent && !window.opera) { - window.attachEvent('onresize', function() { - clearTimeout(IEPNGFix.update.timer); - IEPNGFix.update.timer = setTimeout(IEPNGFix.update, 100); - }); -} +// IE5.5+ PNG Alpha Fix v2.0 Alpha: Background Tiling Support +// (c) 2008 Angus Turnbull http://www.twinhelix.com + +// This is licensed under the GNU LGPL, version 2.1 or later. +// For details, see: http://creativecommons.org/licenses/LGPL/2.1/ + +var IEPNGFix = window.IEPNGFix || {}; + +IEPNGFix.tileBG = function(elm, pngSrc, ready) { + // Params: A reference to a DOM element, the PNG src file pathname, and a + // hidden "ready-to-run" passed when called back after image preloading. + + var data = this.data[elm.uniqueID], + elmW = Math.max(elm.clientWidth, elm.scrollWidth), + elmH = Math.max(elm.clientHeight, elm.scrollHeight), + bgX = elm.currentStyle.backgroundPositionX, + bgY = elm.currentStyle.backgroundPositionY, + bgR = elm.currentStyle.backgroundRepeat; + + // Cache of DIVs created per element, and image preloader/data. + if (!data.tiles) { + data.tiles = { + elm: elm, + src: '', + cache: [], + img: new Image(), + old: {} + }; + } + var tiles = data.tiles, + pngW = tiles.img.width, + pngH = tiles.img.height; + + if (pngSrc) { + if (!ready && pngSrc != tiles.src) { + // New image? Preload it with a callback to detect dimensions. + tiles.img.onload = function() { + this.onload = null; + IEPNGFix.tileBG(elm, pngSrc, 1); + }; + return tiles.img.src = pngSrc; + } + } else { + // No image? + if (tiles.src) ready = 1; + pngW = pngH = 0; + } + tiles.src = pngSrc; + + if (!ready && elmW == tiles.old.w && elmH == tiles.old.h && + bgX == tiles.old.x && bgY == tiles.old.y && bgR == tiles.old.r) { + return; + } + + // Convert English and percentage positions to pixels. + var pos = { + top: '0%', + left: '0%', + center: '50%', + bottom: '100%', + right: '100%' + }, + x, + y, + pc; + x = pos[bgX] || bgX; + y = pos[bgY] || bgY; + if (pc = x.match(/(\d+)%/)) { + x = Math.round((elmW - pngW) * (parseInt(pc[1]) / 100)); + } + if (pc = y.match(/(\d+)%/)) { + y = Math.round((elmH - pngH) * (parseInt(pc[1]) / 100)); + } + x = parseInt(x); + y = parseInt(y); + + // Handle backgroundRepeat. + var repeatX = { 'repeat': 1, 'repeat-x': 1 }[bgR], + repeatY = { 'repeat': 1, 'repeat-y': 1 }[bgR]; + if (repeatX) { + x %= pngW; + if (x > 0) x -= pngW; + } + if (repeatY) { + y %= pngH; + if (y > 0) y -= pngH; + } + + // Go! + this.hook.enabled = 0; + if (!({ relative: 1, absolute: 1 }[elm.currentStyle.position])) { + elm.style.position = 'relative'; + } + var count = 0, + xPos, + maxX = repeatX ? elmW : x + 0.1, + yPos, + maxY = repeatY ? elmH : y + 0.1, + d, + s, + isNew; + if (pngW && pngH) { + for (xPos = x; xPos < maxX; xPos += pngW) { + for (yPos = y; yPos < maxY; yPos += pngH) { + isNew = 0; + if (!tiles.cache[count]) { + tiles.cache[count] = document.createElement('div'); + isNew = 1; + } + var clipR = (xPos + pngW > elmW ? elmW - xPos : pngW), + clipB = (yPos + pngH > elmH ? elmH - yPos : pngH); + d = tiles.cache[count]; + s = d.style; + s.behavior = 'none'; + s.left = xPos + 'px'; + s.top = yPos + 'px'; + s.width = clipR + 'px'; + s.height = clipB + 'px'; + s.clip = 'rect(' + + (yPos < 0 ? 0 - yPos : 0) + 'px,' + + clipR + 'px,' + + clipB + 'px,' + + (xPos < 0 ? 0 - xPos : 0) + 'px)'; + s.display = 'block'; + if (isNew) { + s.position = 'absolute'; + s.zIndex = -999; + if (elm.firstChild) { + elm.insertBefore(d, elm.firstChild); + } else { + elm.appendChild(d); + } + } + this.fix(d, pngSrc, 0); + count++; + } + } + } + while (count < tiles.cache.length) { + this.fix(tiles.cache[count], '', 0); + tiles.cache[count++].style.display = 'none'; + } + + this.hook.enabled = 1; + + // Cache so updates are infrequent. + tiles.old = { + w: elmW, + h: elmH, + x: bgX, + y: bgY, + r: bgR + }; +}; + + +IEPNGFix.update = function() { + // Update all PNG backgrounds. + for (var i in IEPNGFix.data) { + var t = IEPNGFix.data[i].tiles; + if (t && t.elm && t.src) { + IEPNGFix.tileBG(t.elm, t.src); + } + } +}; +IEPNGFix.update.timer = 0; + +if (window.attachEvent && !window.opera) { + window.attachEvent('onresize', function() { + clearTimeout(IEPNGFix.update.timer); + IEPNGFix.update.timer = setTimeout(IEPNGFix.update, 100); + }); +} diff --git a/wp-content/themes/carrington-blog/loop/README.txt b/wp-content/themes/carrington-blog/loop/README.txt new file mode 100644 index 000000000..dff0636fe --- /dev/null +++ b/wp-content/themes/carrington-blog/loop/README.txt @@ -0,0 +1,48 @@ +## loop/ + +This directory contains files that do "the loop". Generally the files in this directory will be included in a file from the _posts/_ or _pages/_ directory, and they will in turn include templates from the _content/_ or _excerpt/_ directories. + +For example, you might want posts on a search results page to display differently that posts on an archive page. Here is how that page would be built: + +1. A page is identified as a search page - Carrington looks for a _posts/search.php_ file and will fall back on a _posts/default.php_ file if none is found. +2. The _posts/search.php_ file will include the header, footer and sidebar - and will also include a call to `cfct_loop()` to include a loop. +3. Since we don't want to show the full posts in search results, the _posts/search.php_ explicitly asks for a file from the _excerpt/_ directory to display the posts in the search results. It will use _excerpt/search.php_ if that file exists, or fall back on _excerpt/default.php_ if the custom file does not exist. + + +## General Context + +When choosing a template to use in the General Context, the Carrington engine looks at the type of request is being fulfilled. It will identify the request as the home page, a category archive, and individual post, etc. + +There is additional checking done for single post requests. All options in the Content Context are supported here with a 'single-' prefix added to the file. See specifics below. + +A "default" template is required, and will be used when there are no other templates that match a given comment. This could be because no other templates have been created, or because the comment in question doesn't match the templates that are available. + +By default, conditions are checked in this order: + +1. author +2. role +3. category +4. tag +5. single +6. default (home, search, archive, 404, etc.) + +This can be altered using the `cfct_general_match_order` hook. + + +### Supported Templates (General Context) + +- *{dirname}-default.php* (or default.php) - Used when there are no other templates that match for a given page/post. +- *archive.php* - Used for date archives or if there are no specific category, author or tag templates. +- *author.php* - Used for author archive lists. +- *author-{username}.php* - Used when the post/page is authored by a specific user. For example, a template with a file name of _author-jsmith.php_ would be used for a post/page by user _jsmith_. Any WordPress username can take the place of {username} in the file name. +- *role-{rolename}.php - Used when the post author has a particular role. This might be the role of _contributor_, _author_, _editor_, etc. and use a file of _role-contributor.php_, _role_author.php_, etc. where the role name takes the place of the {rolename} in the file name. +- *category.php* - Used for category archive lists. +- *cat-{slug}.php* - Used fr displaying a given category. The category is matched by the "slug" - for example a post in category "General" (with a category slug of "general") could use a template of _cat-general.php_. +- *home.php* - Used when on the home page. +- *page.php* - Used for pages that do not match any other contextual templates. +- *search.php* - Used when displaying search results. +- *single.php* - Used for single post pages. +- *single-{content context filenames}.php* - Used for single post pages. +- *tag.php* - Used for tag archive lists. +- *tag-{slug}.php* - Used for displaying a given tag. The tag is matched by the "slug" - for example a post in tag "News" (with a tag slug of "news") could use a template of _tag-news.php_. + diff --git a/wp-content/themes/carrington-blog/misc/README.txt b/wp-content/themes/carrington-blog/misc/README.txt new file mode 100644 index 000000000..aa1fdcc5d --- /dev/null +++ b/wp-content/themes/carrington-blog/misc/README.txt @@ -0,0 +1,17 @@ +## misc/ + +This directory holds page fragments and snippets that you may want to use across multiple template files. + +These files can be included in other theme files using the following code: + + <?php cfct_misc('nav-posts'); ?> + +Where `nav-posts.php` is the name of the file in the _misc/_ directory that you want to include. + + +### Example File Descriptions + +- *banner.php* - This is used by Carrington to display a message that is passed to it. +- *nav-posts.php* - This is standard paging for posts pages. + +This directory is not used by the Carrington engine (template naming conventions are not supported), it is provided solely for convenience and for better organization of these files. \ No newline at end of file diff --git a/wp-content/themes/carrington-blog/pages/README.txt b/wp-content/themes/carrington-blog/pages/README.txt new file mode 100644 index 000000000..68dc1239d --- /dev/null +++ b/wp-content/themes/carrington-blog/pages/README.txt @@ -0,0 +1,39 @@ +## pages/ + +WP doesn't support page templates in nested folders like this one, so page organization isn't as clean as we'd like. + +Create a page in the theme root: + +File name: page-example.php + +**Note:** We recommend prefixing all of your page files with 'page-' so that they are easily sorted together in your theme directory. + +File contents: + + <?php + + /* + Template Name: Example Template + */ + + if (__FILE__ == $_SERVER['SCRIPT_FILENAME']) { die(); } + if (CFCT_DEBUG) { cfct_banner(__FILE__); } + + cfct_page('example'); + + ?> + +This will then load 'example.php' from the _pages/_ directory, keeping all of your actual page code nicely organized in one spot. + +You can also add your page code to the page-example.php file you create in the theme root, but we're hoping to get support for pages in a sub-directory in a future version of WordPress so we are starting with what we consider to be a "proper" organization structure now. + + +### Supported Filenames + +- pages-default.php (or default.php) + + +### File Descriptions + +A "default" template is required. You can create other templates as desired. + diff --git a/wp-content/themes/carrington-blog/plugins/README.txt b/wp-content/themes/carrington-blog/plugins/README.txt new file mode 100644 index 000000000..295ee577e --- /dev/null +++ b/wp-content/themes/carrington-blog/plugins/README.txt @@ -0,0 +1,9 @@ +## plugins/ + +Carrington supports plugins in the same conceptual manner as WordPress. Carrington includes several hooks and filters so you can customize/override Carrington's default behavior. + +Any .php files placed in this directory will be auto-loaded and processed by Carrington. + +This is the recommended way to interact with the hooks and filters provided by Carrington so that they can be easily distributed with the theme. + +This directory is not used by the Carrington engine (template naming conventions are not supported), it is provided solely for convenience and for better organization of these files. \ No newline at end of file diff --git a/wp-content/themes/carrington-blog/posts/README.txt b/wp-content/themes/carrington-blog/posts/README.txt new file mode 100644 index 000000000..a54470f35 --- /dev/null +++ b/wp-content/themes/carrington-blog/posts/README.txt @@ -0,0 +1,50 @@ +## posts/ + +The files in this directory are "top level" templates for pages in WordPress that show multiple posts at once. These files should call `the_header()`, `the_sidebar()`, `the_footer()` and `cfct_loop()` to include the other parts of the page. + +The file from this directory that will be used is chosen based on the current page context. + +You can explicitly decide which _loop/_ to use from these templates by passing it in as so: + + cfct_template_file('loop', 'example'); + +which would use _loop/example.php_ for the loop. + + +## General Context + +When choosing a template to use in the General Context, the Carrington engine looks at the type of request is being fulfilled. It will identify the request as the home page, a category archive, and individual post, etc. + +There is additional checking done for single post requests. All options in the Content Context are supported here with a 'single-' prefix added to the file. See specifics below. + +A "default" template is required, and will be used when there are no other templates that match a given comment. This could be because no other templates have been created, or because the comment in question doesn't match the templates that are available. + +By default, conditions are checked in this order: + +1. author +2. role +3. category +4. tag +5. single +6. default (home, search, archive, 404, etc.) + +This can be altered using the `cfct_general_match_order` hook. + + +### Supported Templates (General Context) + +- *{dirname}-default.php* (or default.php) - Used when there are no other templates that match for a given page/post. +- *archive.php* - Used for date archives or if there are no specific category, author or tag templates. +- *author.php* - Used for author archive lists. +- *author-{username}.php* - Used when the post/page is authored by a specific user. For example, a template with a file name of _author-jsmith.php_ would be used for a post/page by user _jsmith_. Any WordPress username can take the place of {username} in the file name. +- *role-{rolename}.php - Used when the post author has a particular role. This might be the role of _contributor_, _author_, _editor_, etc. and use a file of _role-contributor.php_, _role_author.php_, etc. where the role name takes the place of the {rolename} in the file name. +- *category.php* - Used for category archive lists. +- *cat-{slug}.php* - Used fr displaying a given category. The category is matched by the "slug" - for example a post in category "General" (with a category slug of "general") could use a template of _cat-general.php_. +- *home.php* - Used when on the home page. +- *page.php* - Used for pages that do not match any other contextual templates. +- *search.php* - Used when displaying search results. +- *single.php* - Used for single post pages. +- *single-{content context filenames}.php* - Used for single post pages. +- *tag.php* - Used for tag archive lists. +- *tag-{slug}.php* - Used for displaying a given tag. The tag is matched by the "slug" - for example a post in tag "News" (with a tag slug of "news") could use a template of _tag-news.php_. + diff --git a/wp-content/themes/carrington-blog/sidebar/README.txt b/wp-content/themes/carrington-blog/sidebar/README.txt new file mode 100644 index 000000000..d8d38abb5 --- /dev/null +++ b/wp-content/themes/carrington-blog/sidebar/README.txt @@ -0,0 +1,42 @@ +## sidebar/ + +This directory holds the sidebar files for the theme. The file from this directory that will be used is chosen based on the current page context. + + +## General Context + +When choosing a template to use in the General Context, the Carrington engine looks at the type of request is being fulfilled. It will identify the request as the home page, a category archive, and individual post, etc. + +There is additional checking done for single post requests. All options in the Content Context are supported here with a 'single-' prefix added to the file. See specifics below. + +A "default" template is required, and will be used when there are no other templates that match a given comment. This could be because no other templates have been created, or because the comment in question doesn't match the templates that are available. + +By default, conditions are checked in this order: + +1. author +2. role +3. category +4. tag +5. single +6. default (home, search, archive, 404, etc.) + +This can be altered using the `cfct_general_match_order` hook. + + +### Supported Templates (General Context) + +- *{dirname}-default.php* (or default.php) - Used when there are no other templates that match for a given page/post. +- *archive.php* - Used for date archives or if there are no specific category, author or tag templates. +- *author.php* - Used for author archive lists. +- *author-{username}.php* - Used when the post/page is authored by a specific user. For example, a template with a file name of _author-jsmith.php_ would be used for a post/page by user _jsmith_. Any WordPress username can take the place of {username} in the file name. +- *role-{rolename}.php - Used when the post author has a particular role. This might be the role of _contributor_, _author_, _editor_, etc. and use a file of _role-contributor.php_, _role_author.php_, etc. where the role name takes the place of the {rolename} in the file name. +- *category.php* - Used for category archive lists. +- *cat-{slug}.php* - Used fr displaying a given category. The category is matched by the "slug" - for example a post in category "General" (with a category slug of "general") could use a template of _cat-general.php_. +- *home.php* - Used when on the home page. +- *page.php* - Used for pages that do not match any other contextual templates. +- *search.php* - Used when displaying search results. +- *single.php* - Used for single post pages. +- *single-{content context filenames}.php* - Used for single post pages. +- *tag.php* - Used for tag archive lists. +- *tag-{slug}.php* - Used for displaying a given tag. The tag is matched by the "slug" - for example a post in tag "News" (with a tag slug of "news") could use a template of _tag-news.php_. + diff --git a/wp-content/themes/carrington-blog/sidebar/sidebar-default.php b/wp-content/themes/carrington-blog/sidebar/sidebar-default.php index a0c9d15ca..7975ead71 100644 --- a/wp-content/themes/carrington-blog/sidebar/sidebar-default.php +++ b/wp-content/themes/carrington-blog/sidebar/sidebar-default.php @@ -27,7 +27,7 @@ $orig_post = $post; <div id="carrington-subscribe" class="widget"> <h2 class="widget-title"><?php _e('Subscribe', 'carrington-blog'); ?></h2> <a class="feed alignright" title="RSS 2.0 feed for posts" rel="alternate" href="<?php bloginfo('rss2_url') ?>"> - <img src="<?php bloginfo('template_directory'); ?>/img/rss-button.gif" alt="<?php esc_attr(printf( __( '%s latest posts', 'carrington' ), get_bloginfo('name'))) ?>" title="<?php esc_attr(printf( __( '%s latest posts', 'carrington' ), get_bloginfo('name'))) ?>" /> + <img src="<?php bloginfo('template_directory'); ?>/img/rss-button.gif" alt="<?php printf( __( '%s latest posts', 'carrington' ), wp_specialchars( get_bloginfo('name'), 1 ) ) ?>" title="<?php printf( __( '%s latest posts', 'carrington' ), wp_specialchars( get_bloginfo('name'), 1 ) ) ?>" /> </a> </div><!--.widget--> <?php diff --git a/wp-content/themes/carrington-blog/single/README.txt b/wp-content/themes/carrington-blog/single/README.txt new file mode 100644 index 000000000..483faf006 --- /dev/null +++ b/wp-content/themes/carrington-blog/single/README.txt @@ -0,0 +1,44 @@ +## single/ + +This directory holds top level templates for "single" post pages. These files should call `the_header()`, `the_sidebar()`, `the_footer()`, `cfct_loop()` and `cfct_comments()` to include the other parts of the page. + +All General Context template filenames apply here, but in reality only single.php and single-{Post Context}.php files will be used as the General Context must fall to "single" to look for templates here. + + +## General Context + +When choosing a template to use in the General Context, the Carrington engine looks at the type of request is being fulfilled. It will identify the request as the home page, a category archive, and individual post, etc. + +There is additional checking done for single post requests. All options in the Content Context are supported here with a 'single-' prefix added to the file. See specifics below. + +A "default" template is required, and will be used when there are no other templates that match a given comment. This could be because no other templates have been created, or because the comment in question doesn't match the templates that are available. + +By default, conditions are checked in this order: + +1. author +2. role +3. category +4. tag +5. single +6. default (home, search, archive, 404, etc.) + +This can be altered using the `cfct_general_match_order` hook. + + +### Supported Templates (General Context) + +- *{dirname}-default.php* (or default.php) - Used when there are no other templates that match for a given page/post. +- *archive.php* - Used for date archives or if there are no specific category, author or tag templates. +- *author.php* - Used for author archive lists. +- *author-{username}.php* - Used when the post/page is authored by a specific user. For example, a template with a file name of _author-jsmith.php_ would be used for a post/page by user _jsmith_. Any WordPress username can take the place of {username} in the file name. +- *role-{rolename}.php - Used when the post author has a particular role. This might be the role of _contributor_, _author_, _editor_, etc. and use a file of _role-contributor.php_, _role_author.php_, etc. where the role name takes the place of the {rolename} in the file name. +- *category.php* - Used for category archive lists. +- *cat-{slug}.php* - Used fr displaying a given category. The category is matched by the "slug" - for example a post in category "General" (with a category slug of "general") could use a template of _cat-general.php_. +- *home.php* - Used when on the home page. +- *page.php* - Used for pages that do not match any other contextual templates. +- *search.php* - Used when displaying search results. +- *single.php* - Used for single post pages. +- *single-{content context filenames}.php* - Used for single post pages. +- *tag.php* - Used for tag archive lists. +- *tag-{slug}.php* - Used for displaying a given tag. The tag is matched by the "slug" - for example a post in tag "News" (with a tag slug of "news") could use a template of _tag-news.php_. + -- GitLab