Page 1 of 1

File Download Redirects to Log-in page .. already logged in

PostPosted: November 19th, 2010, 11:46 am
by PorridgePot
I have installed the S2member plugin and got everything set up. Version 3.2.9

I have uploaded a file to the s2member-files directory
When I am logged in with an account, even one with unlimited downloads - when I click on the file download link I get the 'warning' that I will be using up one download spot (like should happen) but am then redirected to the login page at this address
Code: Select all
http://mysite.com/my-membership-options-page/?s2member_level_req=0&s2member_file_download_req=Untitled.wma


instead of letting me download the file.

am I missing something??

thanks

Re: File Download Redirects to Log-in page .. already logged

PostPosted: November 19th, 2010, 12:07 pm
by crushthenet
I think your link may be wrong........

This is the only link structure that works as far as I know....

Code: Select all
http://mysite.com/?s2member_file_download=example-file.zip


I don't think there is any way to check for membership level in the URL.

Only the ability to show or not show links based on level, like example below.

Code: Select all
<?php if (current_user_is("s2member_level1")){ ?>
    Download Links for Members at exactly Level# 1.
<?php } else if(is_user_not_logged_in()) { ?>
    Some public content.
<?php } ?>

Re: File Download Redirects to Log-in page .. already logged

PostPosted: November 19th, 2010, 12:46 pm
by PorridgePot
yeah, that is the code I am using .. my download link is

Code: Select all
http://www.mysite.com/?s2member_file_download=Untitled.wma

Re: File Download Redirects to Log-in page .. already logged

PostPosted: November 19th, 2010, 1:16 pm
by willieg
PorridgePot wrote:I have installed the S2member plugin and got everything set up. Version 3.2.9

I have uploaded a file to the s2member-files directory
When I am logged in with an account, even one with unlimited downloads - when I click on the file download link I get the 'warning' that I will be using up one download spot (like should happen) but am then redirected to the login page
Code: Select all
http://mysite.com/my-membership-options-page/?s2member_level_req=0&s2member_file_download_req=Untitled.wma

am I missing something??

thanks


I had a the same problem and if my memory serves me correctly...I had changed the name of the "protected-page" and the permalink didn't change, I tried to edit but no success, I think I had to change the name of the protected page in the general options - Login Welcome Page.
I have had a few brain f**ts along the way and made some simple mistakes, so check that you have the right pages set in the general options tabs.(simple mistakes-no fault of the script...it is great)

Good Luck

Re: File Download Redirects to Log-in page .. already logged

PostPosted: November 19th, 2010, 5:43 pm
by PorridgePot
I don't think I am having that same problem. I can log in alright, and view the blog post alright, it is just when I try and download the file that i am redirected to the 'create an account' page. The fact that I am told I have X number of downloads left makes it look like things are working but instead of loading the file download window (where would you like to save this file...) I just get redirected :(

Re: File Download Redirects to Log-in page .. already logged

PostPosted: November 19th, 2010, 6:04 pm
by PorridgePot
Thanks for the help everyone. I finally figure it out.

On the Settings page in wordpress I had my blog address set as http://mysite.com
I was linking to the files at http://www.mysite.com/?s2member_file_download=test.mov

So the difference was, I had www in one spot and not in the other - that is what made the problem.

Re: File Download Redirects to Log-in page .. already logged

PostPosted: November 20th, 2010, 7:40 am
by willieg
I thought about this last night and remembered it was NOT what I explained above, but simply as another suggested - the URL - was the problem.
I read a post somewhere in this forum about the www or without www, being consistant.
Anyway, glad to hear you got the issue fixed.

I got all my issues resolved yesterday thanks to help I got here in the forum...'crushthenet' is very reliable and there are others here that have helped me 'drdave' (I think is his UN).