New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Version 0.5.0 #51
Merged
Merged
Version 0.5.0 #51
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
per support forum post, these admin pages are still accessible in some cases
the url filter can be used to disable specific redirects without another filter
… before redirecting
bool value can be passed via filter
…ess-plugin-deploy
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
New:
dwpb_disable_author_archives
filter. Passtrue
to disable author archives entirely. Default does not disable author archives because numerous other plugins use author archives for other purposes. (A future settings page will provide more flexibility here).dwpb_author_archive_post_types
filter to provide author archive support for custom post types. Pass an array of post type slugs to this filter to modify the post types queried on author archives, if not removed by filter above.wp_safe_redirect_fallback
on redirects to set the front-end fallback tohome_url
(WordPress defaults toadmin_url
).dwpb_redirect_status_code
filter to allow for custom status codes for redirects. Defaults to 301 and will set the default if the filter returns a non-300 code.dwpb_pass_query_string_on_redirect
filter, returningtrue
enables all valid url query params to be passed during redirects. Use thedwpb_allowed_query_vars
to limit the vars passed in the redirect by passing an array of keys (e.g. returnarray( 'utm' )
to only passutm
query variables in the query string). Closes #52Fixes:
dwpb_xmlrpc_methods_to_remove
filter to extend the methods being disabled by the plugin. Passfalse
to remove the functionality entirely. Closes #50post.php
,post-new.php
, etc occur. Closes #45.post
type) with a matching function using thepage
endpoint instead. This was throwing an error with thepost
type REST endpoints are disabled. Closes #46dwpb_menu_subpages_to_remove
param has been updated to support an array of subpages in the format of$remove_subpages['parent-page-slug.php'] = array( 'subpage-1.php', 'subpage-2.php' );
, though it still supports subpages as strings for backwards compatibility. Fixes bugs wereoptions-writing.php
andoptions-discussion.php
were conflicting.Improvements/Updates:
dwpb_redirect_admin_url
filters the final url used in admin redirects.dwpb_redirect_admin
only accepts 1 parameter, the previous version accepted 3 (dropping$redirect_url
&$current_url
).dwpb_redirect_admin_edit_post
is nowdwpb_redirect_admin_edit
.dwpb_redirect_single_post_edit
is nowdwpb_redirect_admin_post
.dwpb_redirect_admin_edit_single_post
is nowdwpb_redirect_admin_edit
.dwpb_redirect_edit_tax
has been removed. Usedwpb_redirect_admin_edit_tags
ordwpb_redirect_admin_term
instead, depending on the context.dwpb_redirect_edit_comments
has been removed. usedwpb_redirect_admin_edit_comments
instead.dwpb_redirect_options_discussion
has been removed. Usedwpb_redirect_admin_options_discussion
instead.dwpb_redirect_admin_options_writing
that would pass a boolean to toggle off the options writing page has been remaneddwpb_remove_options_writing
and must be passed withtrue
in order to have the page redirect and the admin menu item removed. By default the value filtered is false and the options Writing page does not go away, as numerous other plugins use this page for non-blog related settings. Nowdwpb_redirect_admin_options_writing
is used to filter the redirect url itself, replacing the previously nameddwpb_redirect_options_writing
filter.dwpb_redirect_options_tools
has been removed. Usedwpb_redirect_admin_options_tools
instead.dwpb_xmlrpc_methods_to_remove
(see above).dwpb_author_archive_post_types
(see above).dwpb_disable_author_archives
(see above).dwpb_front_end_redirect_url
filters the final url used in front end redirects.dwpb_redirect_author_archive
to change the redirect used on author archives, if they are disabled.dwpb_disable_user_sitemap
to change the user sitemap default, passtrue
to keep disable the sitmap. Note that if author archives are disabled by the above filter, user sitemps will be also be disabled regardless of this filter.dwpb_redirect_posts
is nowdwpb_redirect_post
.dwpb_redirect_post_{$post->ID}
filter has been removed. Usedwpb_redirect_post
and check for the post id to target a specific post.dwpb_redirect_front_end
only accepts 1 parameter, the previous version accepted 3 (dropping$redirect_url
&$current_url
).