Adds a shortcode to display a short subscription status description for recurring payments.
<?php
/**
 * Plugin Name: Easy Digital Downloads - Subscription Status Shortcode
 * Plugin URI: http://themeofthecrop.com
 * Description: Adds a shortcode to display a short subscription status description for recurring payments.
 * Version: 0.0.1
 * Author: NateWr
 * Author URI: https://github.com/NateWr
 * License:     GNU General Public License v2.0 or later
 * License URI: http://www.gnu.org/licenses/gpl-2.0.html
 *
 * Text Domain: edd-subscription-status
 * Domain Path: /languages/
 *
 * This program is free software; you can redistribute it and/or modify it under the terms of the GNU
 * General Public License as published by the Free Software Foundation; either version 2 of the License,
 * or (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without
 * even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
 *
 * You should have received a copy of the GNU General Public License along with this program; if not, write
 * to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
 */
if ( ! defined( 'ABSPATH' ) )
	exit;

/**
 * Add a shortcode which prints a small status description for
 * subscriptions that are active through Easy Digital Downloads Recurring
 * Payments platform.
 */
if ( !function_exists( 'eddsss_subscription_status_shortcode' ) ) {
function eddsss_subscription_status_shortcode() {

	if ( !is_user_logged_in() || !class_exists( 'EDD_Recurring_Customer' ) ) {
		return;
	}

	$user_id = get_current_user_id();

	$status = EDD_Recurring_Customer::get_customer_status( $user_id );

	if ( $status !== 'active' && $status !== 'cancelled' && $status !== 'expired' ) {
		return;
	}

	// Check if expired and set to expired if so
	if( EDD_Recurring_Customer::is_customer_expired( $user_id ) ) {
		$status = 'expired';
		EDD_Recurring_Customer::set_customer_status( $user_id, $status );
	}

	$message = '';

	switch( $status ) {
		
		case 'active' :
			$message = sprintf( __( 'Your subscription is active and will renew on %s.', 'edd' ), date_i18n( get_option( 'date_format' ), EDD_Recurring_Customer::get_customer_expiration( $user_id ) ) );
			break;
			
		case 'cancelled' :
			$message = sprintf( __( 'Your subscription is cancelled and expires on %s.', 'edd' ), date_i18n( get_option( 'date_format' ), EDD_Recurring_Customer::get_customer_expiration( $user_id ) ) );
			break;

		case 'expired' :
			$message = sprintf( __( 'Your subscription expired on %s.', 'edd' ), date_i18n( get_option( 'date_format' ), EDD_Recurring_Customer::get_customer_expiration( $user_id ) ) );
			break;
	}

	if ( !empty( $message ) ) {
		return '<div id="edd-subscription-status" class="' . esc_attr( $status ) . '">' . $message . '</div>';
	}

}
add_shortcode( 'edd_subscription_status', 'eddsss_subscription_status_shortcode' );
} // endif;
To implement this snippet on your site, create a brand new, empty WordPress plugin and paste the above code inside.