• I’m using the latest version of PodPress. I can’t seem to figure out how to restrict download only. I want users to be able to view and use the player but restrict the download unless they’re logged in. I’ve tried using ‘Members’, ‘Role Manager’, and a couple of others but can’t seem to do the trick. They either disable everything alltogether or not at all.

Viewing 6 replies - 1 through 6 (of 6 total)
  • Please, install the current Development Version (at the end of the list of the other versions).
    Download the zip file and install it via the plugins page of your blog or via FTP.
    Afterwards save the general settings of podPress again. if the Premium Content function was activated then the podPress box below the WP post editor will offer another option besides “Free”. Saving the general settings will create a new role Premium Subscriber which is basically the same as a subscriber. But a member with such a role can view or listen to the premium episodes. The administrator will also be capable of listening or viewing the premium content.

    Thread Starter Imp3rfections

    (@imp3rfections)

    Still have the same issue. I want them to still be able to play the media. When either option is enabled it says “(protected content)” and doesn’t allow the media to be played. I’ve seen other pages that have it setup this way. The download displays that you must be logged in but it gives them the option to play still. Download becomes available after login.

    ntm actually helped me with this 7 months ago & I found the old post (http://wordpress.org/support/topic/plugin-podpress-audio-player-messed-up-in-ie-8-a-login-before-download-question?replies=5) because I’m in the process of upgrading to the latest WP and podpress. He wrote this for my website personally so you will have to edit it so it works with your site but this gives you an idea. Might not be what you’re looking for but it won’t hurt to post it. I just tried it on a clone site with the latest wp and podpress and it still work. The code is:

    <?php
    /*
    Plugin Name: podPress filter
    Plugin URI:
    Description: diplays custom code instead of the podPress line with the download button if a visitor is not logged in
    Author: ntm
    Version: 1.0
    Author URI:
    */
    
    add_filter('podpress_downloadlinks', 'customize_podpress_downloadlinks');
    function customize_podpress_downloadlinks($podPressDownloadlinks) {
    	if ( is_user_logged_in() ) {
    		return $podPressDownloadlinks;
    	} else {
    		return '<span id="podPressPlayerSpace_'.$GLOBALS['podPressPlayer'].'_PlayLink" style="display:none">'.$hideplayerplaynow_divider.__('Play Now', 'podpress').'</span>'.'<i><a href="http://www.rockitpro.com/wp-login.php">Log in</a> <font color="black">to download the MP3. It\'s free and instant to <a href="http://www.rockitpro.com/wp-login.php?action=register">register</a>!</font></i><br />';
    	}
    }
    ?>

    Put that code in a .php file and store it in the plugins folder of your blog (e.g. /wp-content/plugins/podpress_filter/podpress_filter.php) and it will appear in the list of the plugins in the backend of your blog where you activate and deactivate it.

    What that code does (as you can see on my website rockitpro.com) is hide the download icon until the visitor logs in or registers, then it reveals the download icon once they log in.

    @sho-down: Good idea! Thanks for helping out!

    I have took a further look at the code and made a few minor tweaks:

    <?php
    /*
    Plugin Name: podPress filter
    Plugin URI:
    Description: diplays custom code instead of the podPress line with the download button if a visitor is not logged in
    Author: ntm
    Version: 1.1
    Author URI:
    */
    
    add_filter('podpress_downloadlinks', 'customize_podpress_downloadlinks');
    function customize_podpress_downloadlinks($podPressDownloadlinks) {
    	if ( is_user_logged_in() ) {
    		return $podPressDownloadlinks;
    	} else {
    		$siteurl = get_site_url();
    		return '<div class="podPress_downloadlinks"><span id="podPressPlayerSpace_'.$GLOBALS['podPressPlayer'].'_PlayLink" style="display:none">'.$hideplayerplaynow_divider.__('Play Now', 'podpress').'</span>'.'<a href="'.$siteurl.'/wp-login.php">Log in</a> to download the file. It\'s free and instant to <a href="'.$siteurl.'/wp-login.php?action=register">register</a>!</div>';
    	}
    }
    ?>

    This way it is not necessary modify the site URL manually and the HTML structure is more like the original line.

    @imp3rfections:
    This little Add-On plugin works if you want to restrict the access to all of your episodes. Furthermore if use this plugin then don’t use the Premium Content function of podPress.

    Thanks for the updated code, works fine.

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘[Plugin: PodPress] Restrict only download’ is closed to new replies.