Closed emmtre closed 8 years ago
Could you please enumerate which elements you are still seeing? That would help narrow down missing checks. :)
All of them plus the SEO columns and SEO scores filter. There are several threads about this in the support forum.
At what point do you add the return to filter? It seems it needs to be very early to affect columns (work for me from mu-plugin for them).
Still doesn't affect new meta box UI in that case, looking into.
For my context this is what I did last time on it https://github.com/Yoast/wordpress-seo/pull/2939/files
Things seems to have shifted with new metabox UI, which probably got the relevant checks lost around there.
I usually add the filter in a plugin with a condition (depending on user roles and who should be able to edit the SEO info) since I try to avoid to change the function file. All my sites are running the Genesis framework with child themes and the Genesis Extender plugin. And it has always worked until now with the Yoast SEO 3.x release. I did a quick test and added the filter directly to the function file and played around with a lower and higher priority without success.
From the internal discussion this filter (and ability to disable analysis overall) might be going away altogether.
Are you kidding? This is a big game changer! We need a function to limit usage based on user and user role. And this is a must requirement for many organizations.
Not up to me.
If you elaborate on your specifics and requirements it would be helpful to factor in.
I had been using this filter too. It was a clean way to disable to the scores and columns (which I don't use -- I use the plugin mostly for setting page titles and for the <head>
tags it generates).
My theme's functions.php
file is where I'd been adding the filter. (I also use Genesis.)
@Rarst In larger organizations and companies where you have many users with different roles (authors, editors, designers, etc) there is a must that you can limit and disable the page analysis to only the people who are working with search optimization. Only this case must be a very good reason to keep the filter in there for developers who also are involved in the workflow if you care about larger customers. I think its a big mistake to remove this filter just because you made some changes in 3.x so it broke instead of trying to fix it.
Hi Please, leave the filters. It should be in the capable developers hands and decision how clean the UI of the admin tool is. I use your plugin in all my projects but found that I often hide a lot of functionality to ease the cognitive load for my clients. Maintaining the content of their websites is for many of my clients just one of the many things they have to do to run their businesses and any additional functionality in the WP admin tool proves to be a strain. I'm concerned about SEO and therefore value the functionality of your plugin and found that so far I could configure it very well to fit into my "automatize as much as possible philosophy". The more complex your plugin becomes the more difficult it is to train people to use it.
Think the problem that the filter doesn't work anymore is due to the fact that you're calling the filter in the constructor of WPSEO_Meta_Columns
in class-meta-colums.php
. This constructor is executed before wordpress had the chance to read the themes functions.php
which is the customary place to add filters
public function __construct() {
if ( apply_filters( 'wpseo_use_page_analysis', true ) === true ) {
add_action( 'admin_init', array( $this, 'setup_hooks' ) );
}
}
Thanks for your great work!
This is definitely causing headaches on a lot of Client sites. Please reinstate the filters. In our case we have it set up so that only certain content editors, who know what they are doing, can change and alter the SEO. Now everyone has access to this and clients are confused by all the additional information.
I would very much like to see this filter working too.
1) I have set up several custom post types and have customized the admin post screens to display custom taxonomy filters. My clients do not use the page analysis feature, so the unnecessary SEO dropdown filters are causing visual clutter and taking up valuable screen space.
I had previously been using this code to remove the dropdown filters, but it stopped working after the update to 3.x:
add_action( 'admin_init', 'wpse151723_remove_yoast_seo_posts_filter', 20 );
function wpse151723_remove_yoast_seo_posts_filter() {
global $wpseo_metabox;
if ( $wpseo_metabox ) {
remove_action( 'restrict_manage_posts', array( $wpseo_metabox, 'posts_filter_dropdown' ) );
}
}
2) In addition to the unneeded dropdown filters, I would now like to be able to disable page analysis all together. I do not use page analysis on several of my sites (or do not wish for clients to have access to something they do not understand). The new page analysis feature has become much too prominent to ignore now, making the "wpseo_use_page_analysis" filter all the more necessary.
Please don't do away with this filter! I understand that you feel that page analysis is at the core of your product, but many, like me, have grown reliant on this plugin without using this feature, and removing the option for customization results in a poorer user experience. :(
Any updates on this issue? Have you tested the idea from @novazembla?
The idea from @novazembla didn't work for me I have a temporary workaround, which is hiding these via CSS as I couldn't get unset
on the columns to work either, but this is not the same as restoring the filter
// Hide admin columns via CSS
function hide_admin_columns_css() {
echo '<style type="text/css">';
echo '.column-wpseo-score { display: none; }';
echo '.column-wpseo-title { display: none; }';
echo '.column-wpseo-metadesc { display: none; }';
echo '.column-wpseo-focuskw { display: none; }';
echo '</style>';
}
add_action('admin_head', 'hide_admin_columns_css');
@Rarst you asked for specifics of why this might be useful, on several client sites we have added custom columns to the WP admin for clients that are far more useful to their day to day business than SEO, unfortunately this space is at a premium.
Thanks for all your work.
Sort of interesting that you have updated the knowledge base article.
http://kb.yoast.com/article/285-can-i-disable-the-page-analysis
"Version 3.X.X and newer: This feature was removed in version 3"
This is a BUG and the filter has NOT been removed by purpose!
We are moving all sites and clients back to version 2.3.5 now.
Please fix!
Hi, I built on the approach from @themightyant to hide the seo metabox for all non-admins.
function hide_seo_metabox_non_admins_css() {
if ( ! current_user_can( 'activate_plugins' ) ) {
echo '<style type="text/css">';
echo '#wpseo_meta { display: none !important; }';
echo '</style>'; }
}
add_action('admin_head', 'hide_seo_metabox_non_admins_css');
Seems to work fine as a workaround. Cheers.
Any comments to this?
https://wordpress.org/support/topic/hide-seo-columns?replies=12#post-7861125
This filter doesn't work anymore because it's located in the class constructor - too early for any actions taken in functions.php. You have to call the global var directly:
remove_action( 'admin_init', array( $GLOBALS['wpseo_meta_columns'], 'setup_hooks' ) );
Even if this filter specifically is not going to work ever again, there should be an option to disable the page analysis. I’m looking forward to it.
@Rarst Is there a firm decision that the 'wpseo_use_page_analysis' filter is not coming back and if so is there a best practice way of controlling or disabling the output.
I also find this annoying. There should be an easy way to disable undesired functionality that clutters up the admin. Well, there was a way... now there's not. Please reinstate.
Can we please get this fixed? We, as developers, need the ability to remove the bloat that the plugin adds to the interface. Most of my clients have no idea what's going on and are now finding the interface difficult to use, or going and messing with stuff they shouldn't be.
I'm very confused as to who exactly benefits from the removal of this filter.
+1
I want to add my voice to this. Yoast SEO is in general a great plugin, but I know that the writers on an upcoming project that I'm going to work on will not accept being kvetched at by the computer over their post length, word complexity, etc.
+1 to all this. This is ridiculous how cluttered V3 interface is and removing the ability for developers to unhook things like Page Analysis is very developer unfriendly and honestly very not-WordPress friendly.
Based on @mweber37's solution, I've resorted to using CSS to hide anything that can't be unhooked.
/**
* Hides some of the Yoast bloat, which can no longer be removed by hooks
* https://github.com/Yoast/wordpress-seo/issues/3464
* https://wordpress.org/support/topic/please-remove-your-invasive-update-message
*
*/
function prefix_remove_yeost_bloat() {
echo '<style>
#wp-admin-bar-wpseo-menu,
#major-publishing-actions #wpseo-score,
.yoast-notice {
display: none !important;
}
</style>';
}
add_action('admin_head', 'prefix_remove_yeost_bloat');
Columns can still be unhooked, so these don't have to be hidden via CSS:
/**
* Removes the Yoast columns from pages & postss
*
*/
function prefix_remove_yoast_columns( $columns ) {
unset( $columns['wpseo-score'] );
unset( $columns['wpseo-title'] );
unset( $columns['wpseo-metadesc'] );
unset( $columns['wpseo-focuskw'] );
return $columns;
}
add_filter ( 'manage_edit-post_columns', 'prefix_remove_yoast_columns' );
add_filter ( 'manage_edit-page_columns', 'prefix_remove_yoast_columns' );
// add_filter ( 'manage_edit-{post_type}_columns', 'prefix_remove_yoast_columns' );
If all you're looking to do is get rid of the post filter dropdown, try adding this somewhere:
wp_add_inline_style( 'list-tables', 'select[name="seo_filter"] { display: none !important; }' );
I must agree with the other sentiments. Most or all of my clients simply are looking for the ability to edit page metadata rather than receive consult from the plugin. This is also troubling because as of now wpseo_use_page_analysis is still listed as a filter that accepts 'return false' on Yoast's API docs page: https://yoast.com/wordpress/plugins/seo/api/#filters
I too am reverting to CSS to hide the analysis section of the Yoast meta box, with a selector along the lines of:
#wpseo_content > table tr:last-child
It's too bad this needs to be done in a hacky way. I greatly appreciate this plugin, but I don't fully understand the decision making of Yoast's team in this matter.
Speaking of version 3.3.1: I would definitely like an easy setting to disable all content analysis as well. Just because there are a few extra words in a paragraph, or too few, it labels all my content as a big red "bad" on every page. As a webmaster that deals with multiple writers it doesn't fly very well to have the website tell them their content is BAD. lol
I'm sorry. We'll update the API page, which is sorely outdated I noticed as it is, but the answer is no, it's not coming back.
FWIW this plugin seems to be very dev friendly and not forcing users into anything they dont want/need. https://wordpress.org/plugins/autodescription/ I've started migrating my client sites over to this.
@sethrubenstein Great suggestion, I'm switching to that as well.
@sethrubenstein it's also way slower than ours :)
we've decided to make a user option and sitewide option to disable both SEO and Content analysis. Issue for that coming up.
I really appreciate the concession. Some users on a site may have permission to edit content, but also might not have any business in content analysis.
@jdevalk great! it would be really cool if would disable both SEO and/or content analysis for all user/roles :)
Any news on the able/disable settings?
Any news on the option to disable SEO/Content analysis by role? I get asked for it all the time...
I would recommend to open a new issue on per-role controls. I would guess it's possible with filters somewhere, but won't be able to say for sure without looking.
It looks like the 'wpseo_use_page_analysis' filter is broken in the 3.x version. http://kb.yoast.com/article/285-can-i-disable-the-page-analysis