Commit Graph

299 Commits

Author SHA1 Message Date
nacin
f60b0a2af3 Introduce display_header_text(). props chipbennett for initial patch. see #18887.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20240 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-03-21 18:48:57 +00:00
nacin
f248632c42 WP_Theme::get_allowed_on_network() doesn't take a blog_id argument. props duck_. Restore static declaration accidentally removed in [20193]. see #20103.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20238 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-03-21 17:32:28 +00:00
nacin
359ed454b7 Callbacks for custom headers and custom backgrounds registered through add_theme_support() are now wp-head-callback, admin-head-callback, and admin-preview-callback. see #19910.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20231 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-03-21 03:36:17 +00:00
nacin
369fca1509 In new add_theme_support() logic, fix logic inversion, define HEADER_IMAGE in a simpler way, and force args to be an array. see #20249.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20221 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-03-20 20:34:49 +00:00
nacin
4d3e562dd4 Deprecate add_custom_image_header(), remove_custom_image_header(), add_custom_background(), remove_custom_background(). Replacements are add_theme_support() and remove_theme_support(). see #20249.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20218 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-03-19 21:14:41 +00:00
nacin
127632b10d The word 'support' does not have a overly long 'p'. see #20249.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20214 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-03-19 18:00:27 +00:00
nacin
3c2a88d91e Fix copy-paste issue. see #20249.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20213 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-03-19 17:15:30 +00:00
nacin
6593186cb7 Introduce new registration methods for custom headers and custom backgrounds. Backwards compatible, but old methods will be deprecated. see #20249. see #17242.
Custom header: Use add_theme_support('custom-header', $args) instead of add_custom_image_header(). Deprecates all use of constants.
 * HEADER_TEXTCOLOR is now (string) 'default-text-color'.
 * NO_HEADER_TEXT is nowi ! (bool) 'header-text'.
 * HEADER_IMAGE_WIDTH (and _HEIGHT) are now (int) 'width' and 'height'.
 * HEADER_IMAGE is now (string) 'default-image'.
 * The 3.4 arguments 'suggested-width' and 'suggested-height' are now just 'width' and 'height' (they are "suggested" when flex-width and flex-height are set).
 * Callback arguments for add_custom_image_header() can now be passed to add_theme_support().

Custom background: Use add_theme_support('custom-background, $args) instead of add_custom_background(). Deprecates all use of constants.
 * BACKGROUND_COLOR is now (string) 'default-color'.
 * BACKGROUND_IMAGE is now (string) 'default-image'.
 * Callback arguments for add_custom_background() can now be passed to add_theme_support().

Inheritance: add_theme_support() arguments for custom headers and custom backgrounds is a first-one-wins situation. This is not an unusual paradigm for theming as a child theme (which is included first) overrides a parent theme.
 * Once an argument is explicitly set, it cannot be overridden. You must hook in earlier and set it first.
 * Any argument that is not explicitly set before WP is loaded will inherit the default value for that argument.
 * It is therefore possible for a child theme to pass minimal arguments as long as the parent theme specifies others that may be necessary.
 * Allows for a child theme to alter callbacks for <head> and preview (previously, calling add_custom_image_header more than once broke things).
 * The just-in-time bits ensure that arguments fall back to default values, that the values of all constants are considered (such as one defined after an old add_custom_image_header call), and that all constants are defined (so as to be backwards compatible).

get_theme_support(): Introduce new second argument, which headers and backgrounds leverage to return an argument. current_theme_supports() already supported checking the truthiness of the argument.
 * For example, get_theme_support( 'custom-header', 'width' ) will return the width specified during registration.
 * If you had wanted the default image, use get_theme_support( 'custom-header', 'default-image' ) instead of HEADER_IMAGE. 

Deprecate remove_custom_image_header(), remove_custom_background(). Use remove_theme_support('custom-header'), 'custom-background'.

Deprecate short-lived custom-header-uploads internal support; this is now (bool) 'uploads' for add_theme_support().

New 3.4 functions renamed or removed: Rename get_current_header_data() to get_custom_header(). Remove get_header_image_width() and _height() in favor of get_custom_header()->width and height.



git-svn-id: http://svn.automattic.com/wordpress/trunk@20212 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-03-19 17:12:44 +00:00
nacin
962fae26f4 Updates to WP_Theme, wp_get_themes(), and related deprecated functions, after [UT570] [UT578] [UT579]. see #20103.
* ['Template Files'] and ['Stylesheet Files'] need to return files from the parent theme as well.
 * Don't strip links from the Author header. Some themes rely on the previous behavior, such as to link multiple authors (Sandbox, for example.) Don't restore links to the Name, that's just a bad idea.
 * Ensure we are always passing around arrays in get_files/scandir.
 * Better inline doc for wp_get_themes() arguments.
 * Introduce a 'force' flag for search_theme_directories() to re-scan, rather than return the cache. We will use this to re-build the theme_roots transient in get_theme_roots(), but it is more helpful for unit tests. Since search_theme_directories() is cached, don't cache again in wp_get_themes(). (Again benefits testing.)
 * Handle duplicate theme names in the old get_themes() when two themes match (and neither are a default theme, which is already handled). wp_get_themes() will consider both names to be the same; this is just for back compat since get_themes() is keyed by name.
 * Include an old array key in wp_broken_themes().



git-svn-id: http://svn.automattic.com/wordpress/trunk@20193 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-03-15 15:39:21 +00:00
nacin
69447d2e89 Store stylesheet rather than theme name in the theme_switched option. see #20103.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20163 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-03-08 21:22:24 +00:00
nacin
ead3f2f435 Pass WP_Theme->get_theme_root_uri() to get_theme_root_uri(), thereby always triggering the theme_root_uri filter. see #20103.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20162 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-03-08 18:18:10 +00:00
nacin
c5d5d2f13f Use correct variable. see #20103.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20161 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-03-08 18:00:11 +00:00
nacin
d3487222d5 In wp_get_themes() under multisite, filter out allowed themes before creating WP_Theme objects, rather than after. search_theme_directories() provides us the stylesheet of each theme which is all we need to do the proper intersection. This results in major performance gains on sites that have large numbers of themes unavailable to them. see #20103.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20152 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-03-08 07:46:39 +00:00
nacin
282deeec22 Store relative-to-wp-content theme roots, as that is what get_theme_roots() should be receiving. see #20103.
Since search_theme_directories() now generates this and leverages this as a cache, convert absolute to relative on cache storage, and relative to absolute on cache retrieval.



git-svn-id: http://svn.automattic.com/wordpress/trunk@20118 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-03-06 01:50:54 +00:00
nacin
b53c996068 Cast $wp_theme_directories to array. This had been done in get_themes(). A must-loaded plugin could call these functions before the first theme root is ever added. see #20103.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20116 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-03-05 17:30:09 +00:00
azaozz
dd45b9c2ca Don't pass non-existing rtl stylesheet to TinyMCE, update phpdoc for add_editor_style(), see #19437
git-svn-id: http://svn.automattic.com/wordpress/trunk@20059 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-03-01 00:18:26 +00:00
nacin
71aa5ca72a Strict comparisons for the $allowed arg for wp_get_themes(). Otherwise 'network' does == true. see #20103.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20053 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-29 23:04:25 +00:00
nacin
a8d45a288f Deprecate get_current_theme(). Use (string) wp_get_theme() to get the translated name of the theme. Keep the current_theme option for now. see #20103, see #20138.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20040 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-29 20:07:22 +00:00
nacin
b599bef67a Update switch_theme() to use wp_get_theme(). see #20103, #20138.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20033 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-29 05:09:29 +00:00
nacin
d130a63e25 Introduce WP_Theme, wp_get_themes(), and wp_get_theme() to replace get_themes(), get_theme(), get_theme_data(), current_theme_info(), and others.
* Getters and Helpers: Introduces a series of methods to allow for easy generation of headers for display, and other theme metadata, including page templates.
 * Screenshots: Handles support for multiple screenshots. (see # Additional screenshots must be PNG and start with screenshot-2.png, and be sequential to be counted. see #19816.
 * Error Handling: Broken themes have a WP_Error object attached to them.
 * Caching: Introduces a wp_cache_themes_persistently filter (also in [20020]) to enable persistent caching of all filesystem and sanitization operations normally handled by WP_Theme (and formerly get_file_data() and get_themes()). Themes are cached individually and across five different cache keys for different data pieces.
 * Compatibility: A WP_Theme object is backwards compatible with a theme's array formerly returned by get_themes() and get_theme(), and an stdClass object formerly returned by current_theme_info().
 * i18n/L10n: Theme headers are now localizable with proper Text Domain and Domain Path headers, like plugins. (Language packs may remove the requirement for headers.) For page templates, see #6007 (not fixed yet, but will be easy now). For headers, fixes #15858.
 * PHP and CSS files: New methods that fetch a list of theme files (for the theme editor) only on demand, rather than only loading them into memory. fixes #11214.

Functions deprecated:
 * get_themes(), get_allowed_themes() and get_broken_themes() -- use wp_get_themes()
 * get_theme() and current_theme_info() -- use wp_get_theme()
 * get_site_allowed_themes() -- use WP_Theme::get_allowed_on_network()
 * wpmu_get_blog_allowedthemes() -- use WP_theme::get_allowed_on_site()

see also [20016], [20018], [20019], [20020], [20021], [20022], [20025], [20026], [20027]. also fixes #19244.

see #20103.



git-svn-id: http://svn.automattic.com/wordpress/trunk@20029 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-28 21:24:44 +00:00
nacin
0cb8aed823 Theme root transient caching is now in search_theme_directories(), not get_themes(). see #20103.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20021 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-28 20:08:08 +00:00
nacin
c77de588d4 Rewrite search_theme_directories() -- better performance and allow for caching.
* Update it to use PHP5 scandir().
 * Don't scan individual theme dirs -- we only need to check for style.css. (Solid performance gains.)
 * Improve and simplify branching.
 * Introduce wp_cache_themes_persistently filter to enable persistent caching of the return value, based on the theme_roots transient.

see #20103.


git-svn-id: http://svn.automattic.com/wordpress/trunk@20020 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-28 20:05:00 +00:00
nacin
7df034983a Clarify second argument for get_raw_theme_root() as the multiple negatives can get confusing. see #20103.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20018 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-28 19:59:53 +00:00
nacin
d131a8951a Fix the return value of get_theme_root() when the theme root is outside of WP_CONTENT_DIR, thus making it absolute rather than the typical relative theme root.
Make get_theme_root_uri() tolerate an absolute path for a theme root. It will now make an attempt to find a corresponding URL for absolute paths as well.

see #17597.



git-svn-id: http://svn.automattic.com/wordpress/trunk@20016 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-28 18:02:21 +00:00
nacin
53022ddbfb Revert [20001]. Theme roots that are passed around, stored, and cached can be valid as absolute paths or paths relative to wp-content. We'll have to patch this elsewhere. see #17597.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20015 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-28 16:22:26 +00:00
nacin
e4bfd6ecc1 Move the template loading functions from wp-includes/theme.php to wp-includes/template.php. This includes get_query_template(), locate_template(), and friends. see #20103.
git-svn-id: http://svn.automattic.com/wordpress/trunk@20002 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-28 01:49:49 +00:00
nacin
08e57bfca5 Always return an absolute path in get_raw_theme_root() and get_theme_roots().
These functions were changed in [15641] to avoid any calculations when only one theme directory is registered. However, the short-circuit ended up being relative to WP_CONTENT_DIR, rather than absolute. This broke situations where theme roots are outside the content directory (technically allowed), and made return values inconsistent, as when multiple roots were registered, absolute paths were always returned.

fixes #17597. see #20103. see #14911.



git-svn-id: http://svn.automattic.com/wordpress/trunk@20001 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-28 01:28:56 +00:00
koopersmith
c832f904ae Introduce new theme customizer to replace theme preview. Rough first pass. props koopersmith, ocean90. see #19910.
Merges in http://plugins.svn.wordpress.org/gandalf/branches/dev/ rev 510148.

git-svn-id: http://svn.automattic.com/wordpress/trunk@19995 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-25 04:12:43 +00:00
nacin
206bd59baa Twenty Twelve always trumps its pretenders. see #19978.
git-svn-id: http://svn.automattic.com/wordpress/trunk@19969 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-21 17:39:05 +00:00
nacin
0acbde2f56 Return an empty object properly. see #17242.
git-svn-id: http://svn.automattic.com/wordpress/trunk@19821 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-03 13:38:03 +00:00
ryan
c43ddd7284 Allow flexible sizes for custom header uploads. Round 1. Props aaroncampbell, sabreuse. see #17242
git-svn-id: http://svn.automattic.com/wordpress/trunk@19815 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-02-02 23:35:37 +00:00
ryan
83b131f8e3 User lowercase true, false, null instead of uppercase. Props c3mdigital, mfields. fixes #16302
git-svn-id: http://svn.automattic.com/wordpress/trunk@19687 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-01-05 20:50:54 +00:00
ryan
f809fda4e7 Allow pluggable arg checking in current_theme_supports. Props dd32. fixes #11611
git-svn-id: http://svn.automattic.com/wordpress/trunk@19682 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-01-05 18:29:40 +00:00
ryan
d1ba11c7d1 Update some @since. Props dgwyer. fixes #19638
git-svn-id: http://svn.automattic.com/wordpress/trunk@19673 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-01-04 19:03:33 +00:00
nacin
3f890507d4 Hide the toolbar on all subsequent links in the theme preview. props linuxologos, fixes #19610.
git-svn-id: http://svn.automattic.com/wordpress/trunk@19617 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2011-12-20 22:10:47 +00:00
ryan
07ff8b216b Use one space, not two, after trailing punctuation. fixes #19537
git-svn-id: http://svn.automattic.com/wordpress/trunk@19593 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2011-12-13 23:45:31 +00:00
nacin
e78ef2fc43 Check is_array() against get_themes() in get_theme(). props cgrymala, see #19244.
git-svn-id: http://svn.automattic.com/wordpress/trunk@19287 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2011-11-14 23:56:18 +00:00
ryan
6bbc8d4ce4 Avoid notice when themes dir is empty or missing. Don't reset current theme in current_theme_info() if there are no themes. Show warning in Right Now if there are no themes. Props azaozz. fixes #19089
git-svn-id: http://svn.automattic.com/wordpress/trunk@19251 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2011-11-11 14:10:54 +00:00
nacin
89c0895887 new does not require by reference.
git-svn-id: http://svn.automattic.com/wordpress/trunk@18995 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2011-10-18 20:20:59 +00:00
markjaquith
37aae9f46f Give custom background CSS more specificity. props GaryJ. fixes #18698
git-svn-id: http://svn.automattic.com/wordpress/trunk@18886 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2011-10-05 17:20:43 +00:00
ryan
2edc82cd61 * Move the old sidebars_widgets array upgrade code to wp-admin/includes/upgrade.php
* Avoid infinite loop with wp_get_sidebars_widgets()
* Remove two unneeded wp_get_sidebars_widgets() calls
* Remove unused $wp_registered_sidebars variable from wp_get_sidebars_widgets().
* Combine  a couple of !empty( $sidebars_widgets ) checks in retrieve_widgets()
Props SergeyBiryukov, lancewillett. fixes #17979 #18598


git-svn-id: http://svn.automattic.com/wordpress/trunk@18821 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2011-09-29 21:41:22 +00:00
duck_
6e2ffdc289 Allow current_theme_supports() to be used to check for specific post formats. Props ericmann. Fixes #18691.
git-svn-id: http://svn.automattic.com/wordpress/trunk@18720 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2011-09-19 16:29:03 +00:00
azaozz
dc936c54c1 Rename the newly added action 'after_theme_change' to 'after_switch_theme' so it matches the 'switch_theme' action, props scribu, see #17979
git-svn-id: http://svn.automattic.com/wordpress/trunk@18656 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2011-09-08 20:59:41 +00:00
azaozz
c00346820f Make check_theme_switched() run an action so this enhancement is available to plugins and themes too, see #17979
git-svn-id: http://svn.automattic.com/wordpress/trunk@18655 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2011-09-08 20:07:15 +00:00
azaozz
b79223097c Use theme mods instead of transients for storing the previous theme's widgets config, props aaroncampbell, see #17979
git-svn-id: http://svn.automattic.com/wordpress/trunk@18654 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2011-09-08 19:25:20 +00:00
duck_
2f51b9be0d Fix typos in documentation (wp-includes/[i-z]). See #18560.
git-svn-id: http://svn.automattic.com/wordpress/trunk@18639 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2011-09-05 19:08:15 +00:00
azaozz
4852c5887f Avoid losing widgets when switching themes - take one, props aaroncampbell, see #17979
git-svn-id: http://svn.automattic.com/wordpress/trunk@18630 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2011-09-02 22:13:55 +00:00
ryan
9907923011 Add theme support option for turning on random default headers. fixes #17832
git-svn-id: http://svn.automattic.com/wordpress/trunk@18325 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2011-06-22 19:09:23 +00:00
dd32
2de2e62337 Twenty Eleven trumps it's pretenders. Fixes #17841
git-svn-id: http://svn.automattic.com/wordpress/trunk@18322 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2011-06-20 03:07:24 +00:00
nacin
2571545ec0 @since s/3.2/3.2.0/
git-svn-id: http://svn.automattic.com/wordpress/trunk@18268 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2011-06-11 04:40:18 +00:00
ryan
81a5f821fb Sanitize guid on save and display. Sanitize mime type on save. Don't allow changing mime type via edit form handlers. Protect hidden meta.
git-svn-id: http://svn.automattic.com/wordpress/trunk@17994 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2011-05-22 23:19:42 +00:00
nacin
fad60afa23 Code readability improvements. props niallkennedy, fixes #17166, #17182, #17231, #16474.
git-svn-id: http://svn.automattic.com/wordpress/trunk@17989 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2011-05-22 22:30:05 +00:00
ryan
e0ffff9fb5 Fix hiding of header image. Fix radio selection when falling back to randomized default headers. Props lancewillett, kawauso. see #17240
git-svn-id: http://svn.automattic.com/wordpress/trunk@17770 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2011-04-29 19:45:30 +00:00
ryan
67d53316e0 Allow selecting previously uploader headers and randomly serving previously uploaded or default headers. Props lancewillett. see #17240
git-svn-id: http://svn.automattic.com/wordpress/trunk@17757 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2011-04-28 23:02:16 +00:00
westi
42f57d4798 Remove this new filter as it didn't get enough discussion prior to addition.
Revisit later. See #14310.

git-svn-id: http://svn.automattic.com/wordpress/trunk@17316 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2011-01-15 23:44:06 +00:00
ryan
85f1feed84 Bring out the shears.
git-svn-id: http://svn.automattic.com/wordpress/trunk@17228 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2011-01-06 04:11:14 +00:00
markjaquith
3509f37ac1 I bungled [17214]. Reverting the revert, so it can be reverted properly! see #14310
git-svn-id: http://svn.automattic.com/wordpress/trunk@17220 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2011-01-04 20:55:59 +00:00
markjaquith
6fc301a723 Revert [15611] for 3.1. Needs more time for peer review and iteration. see #14310
git-svn-id: http://svn.automattic.com/wordpress/trunk@17214 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2011-01-04 07:23:41 +00:00
ryan
2de6f5ba96 Ignore unsupported post types in add_theme_support(). Props garyc40. fixes #16073
git-svn-id: http://svn.automattic.com/wordpress/trunk@17213 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2011-01-03 23:56:42 +00:00
nacin
8a6ec685fb Revert [16915]. Don't honor the page template for the posts page. Deal with this with a better UX in 3.2. see #15513, fixes #15945.
git-svn-id: http://svn.automattic.com/wordpress/trunk@17123 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-12-23 17:05:47 +00:00
ryan
587ea006b5 Translations in title attributes require esc_attr().
git-svn-id: http://svn.automattic.com/wordpress/trunk@17102 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-12-21 17:17:58 +00:00
westi
8a261e59e2 -- bad white space part deux
git-svn-id: http://svn.automattic.com/wordpress/trunk@17023 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-12-17 08:42:37 +00:00
westi
c1b7a3ef59 If we are previewing don't show the admin bar. See #15856
git-svn-id: http://svn.automattic.com/wordpress/trunk@17020 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-12-17 08:32:53 +00:00
nacin
4cc8f440e4 Add theme_mods option if is_admin. props MarkJaquith, fixes #14828.
git-svn-id: http://svn.automattic.com/wordpress/trunk@16958 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-12-15 17:39:00 +00:00
nacin
e4698ba1be Revert to WP_DEFAULT_THEME if a child theme is in use and no style.css is present. fixes #15712, props greuben.
git-svn-id: http://svn.automattic.com/wordpress/trunk@16925 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-12-14 19:19:47 +00:00
nacin
3efc0738b6 Revert to WP_DEFAULT_THEME if a child theme is in use and no style.css is present. fixes #15712.
git-svn-id: http://svn.automattic.com/wordpress/trunk@16924 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-12-14 19:17:49 +00:00
ryan
14b8509961 Honor the page template when a page is the home page but not also the front page. Props filosofo. fixes #15513
git-svn-id: http://svn.automattic.com/wordpress/trunk@16915 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-12-14 15:45:19 +00:00
ryan
3949ce12d0 Pink trailing whites.
git-svn-id: http://svn.automattic.com/wordpress/trunk@16900 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-12-13 21:21:50 +00:00
nacin
0036c52101 Make get_header_image() ssl-aware. fixes #14835.
git-svn-id: http://svn.automattic.com/wordpress/trunk@16846 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-12-09 17:59:35 +00:00
nacin
4e2fb85913 Introduce remove_editor_styles(). fixes #14903.
git-svn-id: http://svn.automattic.com/wordpress/trunk@16721 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-12-04 10:09:00 +00:00
nacin
373a66db0f Introduce remove_custom_background(). see #14903.
git-svn-id: http://svn.automattic.com/wordpress/trunk@16720 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-12-04 09:59:35 +00:00
nacin
72958d1c53 Make sure get_themes() returns the proper template and stylesheet directory paths. Use the correct variables. fixes #15671.
git-svn-id: http://svn.automattic.com/wordpress/trunk@16711 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-12-03 22:53:01 +00:00
markjaquith
74f17e9850 Fix typo in PHPdoc. props PeteMall.
git-svn-id: http://svn.automattic.com/wordpress/trunk@16697 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-12-02 22:56:55 +00:00
nacin
831ffc5483 Return true if not is_admin. Tidy. see #14903.
git-svn-id: http://svn.automattic.com/wordpress/trunk@16677 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-12-02 00:50:23 +00:00
nacin
efe850aa42 Introduce remove_custom_image_header(). see #14903.
git-svn-id: http://svn.automattic.com/wordpress/trunk@16674 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-12-02 00:16:35 +00:00
ryan
3f72e340d6 Update since phpdoc. Props demetris. fixes #15445
git-svn-id: http://svn.automattic.com/wordpress/trunk@16660 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-12-01 19:24:38 +00:00
ryan
a6cdc2dea4 Register the default theme dir in wp-settings.php so that it is registered even when get_themes() doesn't run. Fix counting of theme dirs. Add option to get_raw_theme_root() to disregard the current theme root cache. see #14911
git-svn-id: http://svn.automattic.com/wordpress/trunk@16424 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-11-17 16:11:44 +00:00
nacin
81a8f2d3ce Use square brackets instead of braces for string access. props hakre, fixes #13900.
git-svn-id: http://svn.automattic.com/wordpress/trunk@16340 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-11-13 09:53:55 +00:00
markjaquith
17fbb0e123 add_theme_support( 'post-formats', array( 'aside', 'image', 'etc' ) ); Add UI for choosing a post format, and save the choice. see #14746
git-svn-id: http://svn.automattic.com/wordpress/trunk@16174 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-11-04 07:41:07 +00:00
scribu
b890848aaa Use get_queried_object() in more get_*_template() functions. Fixes #15263
git-svn-id: http://svn.automattic.com/wordpress/trunk@16115 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-10-31 11:23:10 +00:00
scribu
e2efa78154 use get_queried_object() wrappers throughout. See #14015
git-svn-id: http://svn.automattic.com/wordpress/trunk@16114 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-10-31 11:02:17 +00:00
nacin
16d0878544 Remove unnecessary wp_cache_delete calls. props shidouhikari, fixes #14080.
git-svn-id: http://svn.automattic.com/wordpress/trunk@16029 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-10-28 05:22:45 +00:00
nacin
d91842f870 Allow disabling of custom header uploads via remove_theme_support. props jorbin, fixes #14837.
git-svn-id: http://svn.automattic.com/wordpress/trunk@15828 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-10-17 07:12:34 +00:00
nacin
eb8762d626 Custom post type archives. see #13818.
git-svn-id: http://svn.automattic.com/wordpress/trunk@15803 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-10-14 10:39:47 +00:00
scribu
f0d8d094e2 Allow string as first parameter to locate_template(). Props chrisbliss18 for initial patch. Fixes #15061
git-svn-id: http://svn.automattic.com/wordpress/trunk@15771 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-10-10 22:10:36 +00:00
nacin
5f0bc55c0b Some doc updates. see #15048.
git-svn-id: http://svn.automattic.com/wordpress/trunk@15739 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-10-07 05:59:50 +00:00
nacin
50120d23da Shift theme mods to be reliant on the theme slug instead of name. fixes #15048.
git-svn-id: http://svn.automattic.com/wordpress/trunk@15736 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-10-06 21:00:17 +00:00
nacin
7ee6aecd1b Account for Twenty Ten in theme name collisions and properly fall back to TT in get_current_theme(). fixes #15719, props tonyf12.
git-svn-id: http://svn.automattic.com/wordpress/trunk@15720 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-10-04 19:50:13 +00:00
ryan
f3d45472d2 Don't fetch theme_roots transient on every page load. Avoid it altogether if there is only one theme dir. fixes #14911
git-svn-id: http://svn.automattic.com/wordpress/trunk@15641 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-09-21 19:41:35 +00:00
scribu
2030231f66 Clean up taxonomy queries in WP_Query. See #12891
git-svn-id: http://svn.automattic.com/wordpress/trunk@15613 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-09-13 16:44:14 +00:00
scribu
4c7deb41e7 Apply filters consistently in get_*_template() functions. Fixes #14310
git-svn-id: http://svn.automattic.com/wordpress/trunk@15611 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-09-12 18:46:18 +00:00
nacin
5a20c05d27 Phpdoc argument/@param cleanups. props duck_, see #14783.
git-svn-id: http://svn.automattic.com/wordpress/trunk@15590 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-09-07 11:21:11 +00:00
westi
4a037313e3 Remove debug cruft. See #14315 props scribu.
git-svn-id: http://svn.automattic.com/wordpress/trunk@15435 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-07-17 11:13:35 +00:00
westi
64100e8783 Fix the theme compat file require paths to be fully absolute so they don't rely on a particular php path to work. Fixes #14315 for trunk props dougal.
git-svn-id: http://svn.automattic.com/wordpress/trunk@15433 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-07-16 09:40:09 +00:00
nacin
194181c6e5 Blacklist remove_theme_support('menus'), used internally. fixes #13935 for trunk.
git-svn-id: http://svn.automattic.com/wordpress/trunk@15277 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-06-18 05:37:45 +00:00
ryan
5ecd1f31f2 Trim trailing whitespace.
git-svn-id: http://svn.automattic.com/wordpress/trunk@15235 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-06-11 20:19:35 +00:00
nacin
69164abe07 Improve the custom background front-end callback. Also, background-attachment should default to scroll, not fixed. fixes #13751.
git-svn-id: http://svn.automattic.com/wordpress/trunk@15196 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-06-10 18:28:25 +00:00
dd32
ebe57d5b69 Use the correct variable name. See #13778
git-svn-id: http://svn.automattic.com/wordpress/trunk@15167 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-06-08 11:04:51 +00:00
dd32
a0729014b8 Use the correct variable name. Props ScottMac. Fixes #13778
git-svn-id: http://svn.automattic.com/wordpress/trunk@15166 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-06-08 11:02:17 +00:00
ryan
1a552dd029 Strip trailing whitespace
git-svn-id: http://svn.automattic.com/wordpress/trunk@14924 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-05-26 02:42:15 +00:00