Ready to get started?Download WordPress


Akismet Key Config No Longer Hidden When Using WPCOM_API_KEY (5 posts)

  1. mgburns
    Posted 9 months ago #

    We are in the process of upgrading our WordPress install from 3.1.4 -> 3.6.1, and updated Akismet from 2.5.6 to 2.5.9 in the process.

    We run a large multisite install, and as a result are relying on the WPCOM_API_KEY constant:

    /** If you hardcode a WP.com API key here, all key config screens will be hidden */
    if ( defined('WPCOM_API_KEY') )
    	$wpcom_api_key = constant('WPCOM_API_KEY');
    	$wpcom_api_key = '';

    It appears the comment above is no longer valid. We're noticing after this upgrade that the Key Configuration page is still displaying the "Akismet API Key" text field with an empty value.

    This is caused by new conditional logic within akismet_conf(), and a mixture of methods to retrieve the API key -- get_option( 'wordpress_api_key' ) vs. akismet_get_key().

    Any chance this function can be revisited? We don't want site admin seeing that field.


  2. Jason Lemahieu (MadtownLems)
    Posted 9 months ago #

    Sadly, this has been a known and reported issue for a long time (several months). I've pointed it out to listed developers, and there are multiple forum posts about it.


  3. alexphelps3
    Posted 6 months ago #

    Having the same problem here.

    Is there any update to this or a known work around?

  4. agreda
    Posted 3 months ago #

    Has anyone figured out where to hardcode in the Akismet key on a multisite install? Is it even possible anymore?

    I wonder if it goes here, in akismet/wrapper.php ...

    $wpcom_api_key = defined( 'WPCOM_API_KEY' ) ? constant( 'WPCOM_API_KEY' ) : 'DOES-KEY-GO-HERE?';

    Any thoughts are greatly appreciated. Thank you!

  5. agreda
    Posted 3 months ago #

    PS: I ask because I read in another topic that this wp-config edit no longer works...

    /** Define WordPress.com API Key */



You must log in to post.

About this Plugin

About this Topic