Commit Graph

10721 Commits

Author SHA1 Message Date
Mark Jaquith
08e68c1ec4 When receiving a HEAD request, die() right before we start outputting content.
* Content doesn't make sense for HEAD requests
* Saves wear and tear on the server
* Introduces a filter: exit_on_http_head (we send TRUE through it)

fixes #14348. props mbijon, mitchoyoshitaka.

git-svn-id: http://core.svn.wordpress.org/trunk@22347 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-31 21:39:23 +00:00
Dion Hulse
57785c7fea Theme Translations: Allow for theme pomo files to be loaded from WP_LANG_DIR/themes/{$domain}-{$locale}.(p|m)o.
This directory format is what we have chosen for Language Packs (See #18200), but which is currently delayed.

By making this change, we can ship localised theme files within core for bundled themes, and avoid the issues associated with Theme Updates overwriting/removing the language files.

Fixes #18960



git-svn-id: http://core.svn.wordpress.org/trunk@22346 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-31 21:30:33 +00:00
Daryl Koopersmith
41c2935278 Media: Reduce button size for the link gallery setting. see #21390.
git-svn-id: http://core.svn.wordpress.org/trunk@22345 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-31 21:03:27 +00:00
Daryl Koopersmith
d16ba6ac18 Media JS: When editing a gallery, prevent attachments from being selected as they are removed. see #21390.
git-svn-id: http://core.svn.wordpress.org/trunk@22344 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-31 20:51:34 +00:00
Daryl Koopersmith
c419700f93 Fix positioning of attachment thumbnail overlays.
Prevents the overlay from blocking buttons inside the attachment preview, such as the remove button in the gallery editor.

see #21390.


git-svn-id: http://core.svn.wordpress.org/trunk@22343 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-31 20:34:50 +00:00
Daryl Koopersmith
9b1ac05bc0 Remove dead gallery settings code. see #21390.
git-svn-id: http://core.svn.wordpress.org/trunk@22342 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-31 20:00:39 +00:00
Daryl Koopersmith
665fadb7bd Make gallery columns fallback a string, as the accepted values are strings. see #21390.
git-svn-id: http://core.svn.wordpress.org/trunk@22341 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-31 20:00:02 +00:00
Daryl Koopersmith
632cc5ced6 Add gallery settings to the media modal.
* Abstracts `wp.media.view.AttachmentDisplaySettings` into `wp.media.view.Settings` for managing lists of settings with button groups and select boxes. Settings can optionally be tied to a user setting (i.e. using `getUserSetting`).
* Adds `wp.media.view.Settings.AttachmentDisplay`.
* Adds `wp.media.view.Settings.Gallery`.

see #21390, #21815.


git-svn-id: http://core.svn.wordpress.org/trunk@22340 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-31 19:22:25 +00:00
Daryl Koopersmith
f3c673558a Media JS: Several improvements to the Attachment views.
* Bind Attachment details updates to the Attachments initialize method.
* Improve Attachment view unbinding.
* Re-render Attachment views when titles and captions are updated.

see #21390.


git-svn-id: http://core.svn.wordpress.org/trunk@22339 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-30 23:59:57 +00:00
Daryl Koopersmith
fcde71fd77 Media JS: Properly fire the Attachment view details method on render. see #21390.
git-svn-id: http://core.svn.wordpress.org/trunk@22338 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-30 23:41:13 +00:00
Daryl Koopersmith
efea572e91 Media JS: Properly build detail views when the selection's single model changes. see #21390.
git-svn-id: http://core.svn.wordpress.org/trunk@22337 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-30 23:36:38 +00:00
Daryl Koopersmith
6670666b27 Media CSS: Remove inner shadow when attachment is selected. see #21390.
git-svn-id: http://core.svn.wordpress.org/trunk@22336 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-30 23:16:28 +00:00
Daryl Koopersmith
640edbdfbc Media JS: Improve handling of single attachments in selections.
* Adds `wp.media.model.Selection.single()` to specify a single item used in a multi-item selection.
* Fixes a bug where the `details` class would not be removed when "Clear Selection" was clicked.

see #21390.


git-svn-id: http://core.svn.wordpress.org/trunk@22335 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-30 23:15:16 +00:00
Bot (Assets)
b502e1e0c2 Compress scripts/styles: 3.5-beta2-22334.
git-svn-id: http://core.svn.wordpress.org/trunk@22334 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-30 22:58:31 +00:00
Daryl Koopersmith
faf00687d4 Media JS: Remove unused Attachment view events. see #21390.
git-svn-id: http://core.svn.wordpress.org/trunk@22333 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-30 21:15:46 +00:00
Daryl Koopersmith
097cb6117d Improve selection UI/behavior in the media modal.
* Moves handling which models are in the selection into the `Library` state.
* Adds highlight for the last-selected view in a multi-view state.
* A view must be the last-selected view before it can be deselected.

see #21390.


git-svn-id: http://core.svn.wordpress.org/trunk@22332 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-30 21:09:45 +00:00
Dion Hulse
a24d651e0e Prevent an issue on windows systems which can cause the temporary directory from get_temp_dir() from returning a path containing \/. Props to SergeyBiryukov for the initial patch. Fixes #20778
git-svn-id: http://core.svn.wordpress.org/trunk@22331 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-30 20:58:35 +00:00
Dion Hulse
3417e0245a When reading local feeds from disk, check that the file exists first to avoid a PHP Warning in WP_SimplePie_File. Props SergeyBiryukov. Fixes #17756
git-svn-id: http://core.svn.wordpress.org/trunk@22330 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-30 20:48:35 +00:00
Andrew Ozz
24537164ff Buttons: make install.css depend on buttons.css (so button styles are always loaded), see #21598
git-svn-id: http://core.svn.wordpress.org/trunk@22327 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-30 16:28:13 +00:00
Bot (Assets)
2e1aaeb2c5 Compress scripts/styles: 3.5-beta2-22326.
git-svn-id: http://core.svn.wordpress.org/trunk@22326 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-29 22:58:31 +00:00
Daryl Koopersmith
01f3ca5a6c Improve attachment detailed preview styling. see #21390.
git-svn-id: http://core.svn.wordpress.org/trunk@22325 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-29 18:16:12 +00:00
Daryl Koopersmith
c0bc7a7903 Add dynamic attachment view sizing. Removes the attachment view zooming in the process. see #21390.
git-svn-id: http://core.svn.wordpress.org/trunk@22324 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-29 18:05:03 +00:00
Daryl Koopersmith
16c1011cdb Add attachment details to the media sidebar.
* Also moves most of the `Frame` view's `createSelection` method to a real `Selection` model (which inherits from the `Attachments` model).
* Properly assigns the library within the `Gallery` state, allowing for the `Gallery` state to inherit from the `Library` state.

see #21390.


git-svn-id: http://core.svn.wordpress.org/trunk@22323 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-29 15:13:02 +00:00
Daryl Koopersmith
aa52a02dd1 Add inline uploader UI to media modal sidebar. see #21390.
git-svn-id: http://core.svn.wordpress.org/trunk@22322 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-29 07:38:13 +00:00
Daryl Koopersmith
f7c1aaf26d Add a sidebar to the media modal.
* Adds `wp.media.view.Sidebar`, to aid in rendering the sidebar.
* Removes the `directions` from the `Attachments` view and shifts search into a separate view (`wp.mce.view.Search`) that can be relocated at will. This also serves to simplify the `Attachments` view by removing the nested `list` and `$list` parameters.
* Show the toolbar on the featured image workflow, effectively requiring confirmation before closing the dialog.

see #21390, #21776, #21808.


git-svn-id: http://core.svn.wordpress.org/trunk@22321 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-29 06:56:23 +00:00
Daryl Koopersmith
53ccb09bce Give media a heart transplant.
Revises the concept of the media controller and workspace views (i.e. two central points of control) to be more granular. The main media object is now the `Frame`, which is a hybrid view and state machine.

The state machine is a collection of states, which are just generic instances of `Backbone.Model`. This circumvents the problem of juggling global parameters when changing states. Each state contains its own event loop. All events are also forwarded to the frame itself (as is the case in all model/collection relationships).

The frame view contains several regions, each of which can be overridden without harming or re-rendering the other regions. These work well when used in conjunction with the state machine events.

This removes the upload sidebar (don't worry, visible upload UI will return). Drag and drop uploading still works. The ability to upload has been abstracted into its own view (instead of being attached to the central workspace view).

Editing galleries is temporarily broken — the gallery creation and editing experiences will be unified in a future patch.

Adds events to detect dragging changes in `wp.Uploader` and adds methods to detect and leverage browser support for CSS3 transitions.

see #21390, #21809.


git-svn-id: http://core.svn.wordpress.org/trunk@22320 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-28 23:29:17 +00:00
Bot (Assets)
4681d3b3e3 Compress scripts/styles: 3.5-beta2-22315.
git-svn-id: http://core.svn.wordpress.org/trunk@22315 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-26 22:58:34 +00:00
Andrew Ozz
efbc9d2336 Buttons:
- Update the install/initial configuration/repair screens buttons, props DrewAPicture
- Fix the welcome screen buttons and fine-tune the buttons css, props lessbloat

fixes #21598


git-svn-id: http://core.svn.wordpress.org/trunk@22314 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-26 19:40:39 +00:00
Andrew Nacin
2677205fba If we have not yet initialized the custom header/background, do not do extra removal in _remove_theme_support(). fixes #22246.
git-svn-id: http://core.svn.wordpress.org/trunk@22313 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-26 04:17:25 +00:00
Andrew Nacin
602dd1a738 Revert [22274]. see #22246.
git-svn-id: http://core.svn.wordpress.org/trunk@22312 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-26 04:16:49 +00:00
Bot (Assets)
3ff4a47f36 Compress scripts/styles: 3.5-beta2-22311.
git-svn-id: http://core.svn.wordpress.org/trunk@22311 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-25 22:58:32 +00:00
Ryan Boren
21d6dbc4a8 Fix wp_basename() for Windows by replacing %5C with /.
Props SergeyBiryukov
fixes #22138


git-svn-id: http://core.svn.wordpress.org/trunk@22310 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-25 22:31:17 +00:00
Jon Cave
391ff2f639 Fix documentation typo: s/WP_Erorr/WP_Error/. See #21593.
git-svn-id: http://core.svn.wordpress.org/trunk@22309 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-25 22:29:37 +00:00
Ryan Boren
04a1ea0b39 Consolidate some transalted strings. Remove unnecessary trailing newlines. Props pavelevap. fixes #22274
git-svn-id: http://core.svn.wordpress.org/trunk@22308 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-25 22:21:15 +00:00
Ryan Boren
28461df188 Return WP_Error when registering a taxonomy that exceeds 32 characters.
Props ocean90.
fixes #21593


git-svn-id: http://core.svn.wordpress.org/trunk@22307 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-25 22:12:02 +00:00
Andrew Ozz
bcb040f1e0 Hide the "You are using the multi-file uploader. Problems? Try the browser uploader instead." when Plupload falls back to "html4" runtime, fixes #19496
git-svn-id: http://core.svn.wordpress.org/trunk@22305 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-25 20:53:38 +00:00
Andrew Nacin
d85554c5f1 When replacing floats in wpdb::prepare(), avoid escaped placeholders (%%f). props SergeyBiryukov. fixes #19861.
git-svn-id: http://core.svn.wordpress.org/trunk@22304 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-25 20:52:50 +00:00
Andrew Nacin
1773a06874 Avoid 'headers already sent' messages for header_remove() the same way we currently do with header(). props ryan. fixes #22258.
git-svn-id: http://core.svn.wordpress.org/trunk@22303 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-25 20:38:55 +00:00
Andrew Nacin
f8becb79f7 Confirm that the nav menu's underlying object is in the proper taxonomy before adding the current-menu-item class. props SergeyBiryukov. fixes #21369.
git-svn-id: http://core.svn.wordpress.org/trunk@22302 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-25 20:32:01 +00:00
Andrew Nacin
6346dfe407 When stripping off a pathinfo home root (/index.php/) do it with case insensitivity. props SergeyBiryukov. fixes #13164. see #8847.
git-svn-id: http://core.svn.wordpress.org/trunk@22298 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-25 20:09:54 +00:00
Ryan Boren
5c713162f1 Avoid notices in get_*_template() functions that use get_queried_object(), which can return null. Props wonderboymusic. fixes #20519
git-svn-id: http://core.svn.wordpress.org/trunk@22293 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-25 12:54:50 +00:00
Bot (Assets)
c7f18926e6 Compress scripts/styles: 3.5-beta2-22292.
git-svn-id: http://core.svn.wordpress.org/trunk@22292 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-24 22:58:36 +00:00
Ryan Boren
a550a6d489 Use the create_posts capability in more places.
In get_post_type_capabilities(), make sure create_posts reflects customizations to the edit_posts capability when create_posts is not specifically set.


git-svn-id: http://core.svn.wordpress.org/trunk@22291 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-24 22:15:43 +00:00
Andrew Ozz
239650f87a Fix the buttons in IE, make them better in IE7, remove the default padding in Firefox, make all .button <a> and <input> look the same, fixes #21598
git-svn-id: http://core.svn.wordpress.org/trunk@22289 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-24 01:33:59 +00:00
Andrew Ozz
8c4d96b05a Buttons: slightly bolder :focus styles, make the "Log In" button '.button-large', props lessbloat, see #21598
git-svn-id: http://core.svn.wordpress.org/trunk@22288 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-24 01:27:56 +00:00
Bot (Assets)
852f080ef2 Compress scripts/styles: 3.5-beta2-22287.
git-svn-id: http://core.svn.wordpress.org/trunk@22287 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-23 22:58:40 +00:00
Ryan Boren
02d584b4c7 Revert [21420] and [21481]. Accepting a string caused back compat problems including the possibility of revealing previously hidden circular dependencies resulting in infinite loops.
fixes #20683 #22111
see #21520


git-svn-id: http://core.svn.wordpress.org/trunk@22286 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-23 20:32:12 +00:00
Andrew Nacin
a88114dd92 Do not issue a Last-Modified header when issuing no-cache headers to avoid aggressive (webkit) caching. Serve a blank header when header_remove() is not available (PHP < 5.3). props andy. fixes #22258.
git-svn-id: http://core.svn.wordpress.org/trunk@22283 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-23 15:45:44 +00:00
Andrew Nacin
62156e8ad3 Reset box-sizing to toolbar CSS to avoid conflicts with themes. props betzster, fixes #21863.
git-svn-id: http://core.svn.wordpress.org/trunk@22280 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-23 14:30:03 +00:00
Andrew Nacin
fb2c9e7e4f Prime post caches for the Recent Comments widget. props mitchoyoshitaka. see #15400.
git-svn-id: http://core.svn.wordpress.org/trunk@22278 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-10-23 14:18:37 +00:00