PriMoThemes — now s2Member® (official notice)

This is now a very OLD forum system. It's in READ-ONLY mode.
All community interaction now occurs at WP Sharks™. See: new forums @ WP Sharks™

503 error using the s2member key url

s2Member Plugin. A Membership plugin for WordPress®.

503 error using the s2member key url

Postby coloradoflyfisherman » May 22nd, 2011, 2:12 pm

I have a file in the s2member file folder and am using this link.

Code: Select all
<a href='http://www.successfulflyfishing.com/?s2member_file_download=successfulflyfishing-expire.zip&s2member_file_download_key=<?php echo s2member_file_download_key("successfulflyfishing-expire.zip"); ?>'>DOWNLOAD DEMO eBOOK</a>


This is the 503 error I get when clicking the link.
503 ( Invalid Key ): Sorry, your access to this file has expired. Please contact Support for assistance.

I have the download limit set to 10 in 365 days so that should not be it.

Any help appreciated.
Last edited by Cristián Lávaque on May 22nd, 2011, 6:21 pm, edited 3 times in total.
Reason: Improve code readability. http://www.primothemes.com/forums/viewtopic.php?f=36&t=2780
User avatar
coloradoflyfisherman
Registered User
Registered User
 
Posts: 14
Joined: May 12, 2011

Re: 503 error using the s2member key url

Postby Jason Caldwell » May 23rd, 2011, 4:41 am

Thanks for reporting this important issue.

Did you use this code inside a Post/Page?
If so, make sure you've got a PHP Execution plugin installed first:
http://wordpress.org/extend/plugins/php ... on-plugin/
~ Jason Caldwell / Lead Developer
& Zeitgeist Movie Advocate: http://www.zeitgeistmovie.com/

Is the s2Member plugin working for you? Please rate s2Member at WordPress.org.
You'll need a WordPress.org account ( comes in handy ). Then rate s2Member here Image
.
User avatar
Jason Caldwell
Lead Developer
Lead Developer
 
Posts: 4045
Joined: May 3, 2010
Location: Georgia / USA

Re: 503 error using the s2member key url

Postby coloradoflyfisherman » May 23rd, 2011, 9:26 am

Jason,

1st thanks for wp-show-id plugin. This plugin works great.
2nd I installed the php plugin you recommended and activated it. Then tried the s2member key link in a post and in a page with the same 503 error returned.

Since I had a WP blog get hacked badly in Jan, I am much more careful about php being executed. I am running some code in my .htaccess file that may be causing the problem.

If you wish to see the code I will send directly to you. Is there a way to send you a private email on the forum?
User avatar
coloradoflyfisherman
Registered User
Registered User
 
Posts: 14
Joined: May 12, 2011

Re: 503 error using the s2member key url

Postby Cristián Lávaque » May 23rd, 2011, 1:18 pm

You can email him private info using this form http://s2member.com/contact
Cristián Lávaque http://s2member.net
Is s2Member working for you? Please rate it Image at WordPress.org. Thanks! :)
User avatar
Cristián Lávaque
Developer
Developer
 
Posts: 6836
Joined: December 22, 2010

Re: 503 error using the s2member key url

Postby Jason Caldwell » May 23rd, 2011, 5:38 pm

Sure, please send that over using the form Cristián provided.

This code snippet:
Code: Select all
 <a href='http://www.successfulflyfishing.com/?s2member_file_download=successfulflyfishing-expire.zip&s2member_file_download_key=<?php echo s2member_file_download_key("successfulflyfishing-expire.zip"); ?>'>DOWNLOAD DEMO eBOOK</a>

... should ultimately produce a clickable link that looks something like this:
Code: Select all
http://www.successfulflyfishing.com/?s2member_file_download=successfulflyfishing-expire.zip&s2member_file_download_key=98234kljsdf9234sssf9wruw
* If your "Key" on the end, doesn't look something like this, I suspect there is a problem with the PHP tag not being evaluated. You might also try placing the code snippet directly into a PHP template file for your theme. This code will not work inside a Post/Page unless you have a PHP execution plugin installed/configured properly.
~ Jason Caldwell / Lead Developer
& Zeitgeist Movie Advocate: http://www.zeitgeistmovie.com/

Is the s2Member plugin working for you? Please rate s2Member at WordPress.org.
You'll need a WordPress.org account ( comes in handy ). Then rate s2Member here Image
.
User avatar
Jason Caldwell
Lead Developer
Lead Developer
 
Posts: 4045
Joined: May 3, 2010
Location: Georgia / USA

Re: 503 error using the s2member key url

Postby coloradoflyfisherman » May 24th, 2011, 5:38 am

this is what I get from inputting the link using the html side of the visual editor. I have changed the name of the download file is all. I think in the S2 download advanced instructions, it said that the ending php tag had to be of the format shown here ?&gt; for the link to work. Maybe the issue is in the conversion of the rest of the UTC8 character coding.

Code: Select all
<a href="http://www.successfulflyfishing.com/?s2member_file_download=successfulflyfishing-demoebook.zip&amp;s2member_file_download_key=&lt;?php echo s2member_file_download_key('successfulflyfishing-demoebook.zip'); ?&gt;">DOWNLOAD DEMO eBOOK</a> 
Last edited by Cristián Lávaque on May 24th, 2011, 11:18 am, edited 1 time in total.
Reason: Improve code readability. http://www.primothemes.com/forums/viewtopic.php?f=36&t=2780
User avatar
coloradoflyfisherman
Registered User
Registered User
 
Posts: 14
Joined: May 12, 2011

Re: 503 error using the s2member key url

Postby Cristián Lávaque » May 24th, 2011, 11:37 am

No, you should enter the PHP in the HTML tab of the editor, not Visual, and you'll need Exec PHP for it to work, too.

Jason, wouldn't it be good to have a shortcode for the key? E.g.
Code: Select all
[s2Get download_key="example.zip" /]


Or even a full URL version like
Code: Select all
<a href="[s2Get download_key_url="example.zip" /]">download</a>
Cristián Lávaque http://s2member.net
Is s2Member working for you? Please rate it Image at WordPress.org. Thanks! :)
User avatar
Cristián Lávaque
Developer
Developer
 
Posts: 6836
Joined: December 22, 2010

Re: 503 error using the s2member key url

Postby Jason Caldwell » May 24th, 2011, 7:46 pm

Yes, that's a great idea. I think that came up in the past but never made it on our TODO list.

I'm putting it back on the list now. Thank you!
@TODO: Shortcode for Download Links with Keys.
~ Jason Caldwell / Lead Developer
& Zeitgeist Movie Advocate: http://www.zeitgeistmovie.com/

Is the s2Member plugin working for you? Please rate s2Member at WordPress.org.
You'll need a WordPress.org account ( comes in handy ). Then rate s2Member here Image
.
User avatar
Jason Caldwell
Lead Developer
Lead Developer
 
Posts: 4045
Joined: May 3, 2010
Location: Georgia / USA

Re: 503 error using the s2member key url

Postby Cristián Lávaque » May 24th, 2011, 8:32 pm

Cool!
Cristián Lávaque http://s2member.net
Is s2Member working for you? Please rate it Image at WordPress.org. Thanks! :)
User avatar
Cristián Lávaque
Developer
Developer
 
Posts: 6836
Joined: December 22, 2010


Return to s2Member Plugin

Who is online

Users browsing this forum: Yahoo [Bot] and 1 guest

cron