How to allow free audio file downloads ONLY to logged in members
Installation and Configuration
mattbrady:Wonderful! That worked!
Now if I could figure out how to hide the streaming button for only logged in users.
Glad that worked!
99% of our users WANT the streaming option to show - if you want to hide it for logged in users you'll need to go into the ACP -> Media -> Audio Support -> Templates and customize the "item_detail.tpl" file - change this:
{assign var="ap" value="`$_conf.jrCore_active_skin`_auto_play"}
<br>{jrCore_media_player module="jrAudio" field="audio_file" item=$item autoplay=$_conf.$ap}<br>
To this:
{if !jrUser_is_logged_in()}
{assign var="ap" value="`$_conf.jrCore_active_skin`_auto_play"}
<br>{jrCore_media_player module="jrAudio" field="audio_file" item=$item autoplay=$_conf.$ap}<br>
{/if}
Then the streaming player on the detail page will only show to users that are NOT logged in. You can then repeat this for the item_list.tpl file as well.
After you've made your changes make sure to put a checkmark in the "active" column for those templates, save, then reset caches.
Hope this helps!