A no-hack dashboard removal plugin
I don't know why this wasn't discovered (or a better action put in by the WP folks to begin with that could be disabled) but I was able to find a way to disable the feeds from loading on the WordPress admin dashboard without any need for customized index.php files (which would need to be updated/re-uploaded every time WP is updated.)
I'm not sure why this isn't just a stock WP configuration option. It seems enough people have looked for ways around it. My biggest issue was that it requires connectivity directly with each RSS feed, which does not work very well behind our firewall at work. I'll be damned if I hack up some proxy-capable solution too for the feeds that we don't really even look at.
I knew that there had to be a way to mess with the actions being called to disable them from loading the Javascript, or make the fetch_rss() calls return nothing, or make the index-extras.php script return nothing... the easiest and apparently effective way was making a simple action trigger and finding the right order in which it was effective.
In the end, this is all the code that was required:
function remove_dashboard_feeds() { remove_action('admin_head', 'index_js'); } add_action('admin_head', 'remove_dashboard_feeds', 1);
To make a long story short, I give you the "Remove Dashboard Feeds" plugin, located here. Just download, remove the .txt extension, throw it in the plugin directory and activate it. Simple enough. Works on WP 2.2, and probably 2.1. Not sure about earlier versions, but nobody should be running those anyway (keep up with the times as much as you can! Stay secure and optimized!)
I successfully installed them on 4 different copies of WP 2.2. And get this, it works in the mu-plugins folder of WPMU. Thanks, Mike!
Had some trouble with this in 2.1... Guess I'll have to get off my lazy a** and upgrade. Thx for the plugin.
Thanks for the feedback. Depending on your WP setup the upgrade should be quite seamless. I did it on a production server without testing it first... all my old custom plugins worked fine and this one does too (although I made this one post upgrade.)
It works just fine on MU
thanks
Tks a lot for this. I think this is a feature that have to be installed on WordPress options.
"Error 404 - Not Found
You have landed on an invalid URL."
source not found...:(
doh. fixed! changing webservers can be annoying 🙂
thanks! it just works, and so simple, I like it! big thx for it.
I'm not getting this. I go to your download link but just get code. Is there a plug in to download and upload to my hosting environment? What am I missing?
By the way, I think this is a great plugin idea.
plugins are just php code.
this can be put it its own .php file, or put into an existing .php file in the plugins directory. it requires no special configuration or activation (unless you make its own file, then you have to click activate)
you can download the .txt, rename it to .php, upload it to plugins dir, and activate it.
or if you have shell access, to go the plugins directory and do this:
then go into wordpress admin and activate it.
does this work with WP 2.3.x?
I have not tested it yet in WP 2.3, although I am running it with an upgraded-to-WP2.3-install at work and it appears to be functioning properly. I haven't actually tried it officially though 🙂 It appears my multiple attempts to subscribe to WP release notifications is still not working, so I am not being notified when a new version of WP comes out. I missed the 2.3 launch by a couple weeks! If it works for anyone else please post. I will report my findings when I upgrade this WP install at least.
Update: disabled/enabled it on WP 2.3 and it works fine. When disabled, the feeds show up again as expected.
You could also add this code to the functions.php of your chosen theme. I am doing that on 2.3.x and it work great. Thanks for the code.
Yeah that's why I pasted the code by itself too. It can go anywhere.
thanks for this great and very easy to use plugin!!
cheers 🙂
Thanks. Simply fantastic. Now my WP dashboard is much cleaner and easier to read. Thanks again
Hi, I tried to download your plugin but the server answers with:
"
Fatal error: Call to undefined function add_action() in /mnt/nfs/mike/web/michaelshadle.com/files/wordpress/remove-dashboard-feeds.php.txt on line 17"
I'd be happy to get your plugin. So maybe if there is some time...
Thank you
Thanks for pointing that out. When I switched to nginx I forgot how I had it setup. The link is fixed now, it will not execute it as PHP, it is purely .txt now.
Just upgraded from 2.3.1 to 2.5.1 and this doesn't seem to work any longer. Any chance you might have time to tweak it? Thanks!
I was hoping that by 2.5 part of their dashboard enhancements would render this useless, because they'd offer the feeds/etc. as an option. Apparently not!
I'll make sure it works when I get around to upgrading to 2.5.1 myself, and I'll post an update.
It should definitely be a stock WordPress option. Not sure why it isn't. I guess they may be thinking of just making it well known in a later version or something. Interesting enough, that's for sure. I'm going to be experimenting with this and seeing if this might solve another problem I'm experiencing at the moment.
Hi There,
It only works partially for me.
I use WP 2.6 and i still have those boxes in my dashboard, the are empty, except from that one line: Loading…
Yeah. It doesn't work in 2.6. I should make an update.
However I thought I saw they were planning on shipping with an option to turn it off. But I don't remember actually seeing that in my installation. I don't think it made the cut.
From what I gleaned from the WP 2.7 wireframes/etc. the feeds won't be there anymore (or they won't be activated by default or on the dashboard at least)
I would like to disable the dashboard only for authors. Is this possible?
At this point - I am probably not going to do anything until WP 2.7 comes out. They keep releasing newer versions faster than my laziness allows, and they change some things that require reverse engineering the changes...
I think in WP 2.7 they have redone the admin interface anyway; this plugin might not be needed.
Doesn't work on 2.8.3
@Joe
Yeah, this is not guaranteed to work on anything past 2.2.x or whatever. If I get around to it, I'll look into 2.8 (I need to upgrade myself anyway) - however, I swore they were going to make it an option to turn off the feeds.
@mike is turning off in the dashboard the same as not publishing? Or will they still be published, but just made invisible?
@Anonymous
No, this was to disable the feeds from loading automatically using background calls to WordPress and a couple other places. It was actually loaded via AJAX to the PHP script than then called the feeds, if I recall. All this did was disable that from running. Pretty simple. I'll have to work on 2.8.x at some point here.