latest stable versions: v150827 (changelog)

Old Forums (READ-ONLY): The community now lives at WP Sharks™. If you have an s2Member® Pro question, please use our new Support System.

Cloudfront and Advanced Mod-Rewrite

Home Forums Community Forum Cloudfront and Advanced Mod-Rewrite

This topic contains 5 replies, has 3 voices. Last updated by  Jason (Lead Developer) 4 years, 10 months ago.

Topic Author Topic
Posted: Friday Feb 10th, 2012 at 6:00 pm #4782

Using WordPress 3.3.1
S2 Member Pro v111220

I think I’m writing my Advanced Mod-Rewrite code incorrectly.

I have a pdf file in my Cloudfront bucket that I want to serve inline. I’ve configured the metatags accordingly. If I use the standard code with a query string, it works correctly. But if I use Advanced Mod-Rewrite, I get a server error.

The filename is “howtopresentourlessons.pdf” and for the purpose of this test, I’ve put it on the root level of my bucket, not in a folder. There are no protections on the page containing the link.

And here are the two code samples:

This link uses a query string, and it works (opens the pdf file inline):
<a href="http://rockitscience.com/wordpress/?s2member_file_download=howtopresentourlessons.pdf">How to Present a Rock-it Science Lesson</a>

This link uses Advanced Mod-Rewrite Linkage and doesn't work (server error):
<a href="http://rockitscience.com/wordpress//wp-content/plugins/s2member-files/howtopresentourlessons.pdf">How to Present a Rock-it Science Lesson</a>

List Of Topic Replies

Viewing 5 replies - 1 through 5 (of 5 total)
Author Replies
Author Replies
Posted: Saturday Feb 11th, 2012 at 4:01 am #4804
Bendix
Username: benchefe

Hey,
maybe this causes the problem?

…wordpress//wp-content….

Greetings

Posted: Monday Feb 13th, 2012 at 5:08 pm #4962

Thanks for catching that, Bendix. However, even after I removed the extra slash, I still get a server error.

Posted: Tuesday Feb 14th, 2012 at 5:19 pm #5061
Staff Member

Hi there. Thanks for your inquiry.
Try it like this please, with the inline specification. Does this help?

http://rockitscience.com/wordpress/wp-content/plugins/s2member-files/s2member-file-inline/howtopresentourlessons.pdf

* Please test in the latest release of s2Member v120213, which resolved some issues with GZIP conflicts, related to protected file downloads.

Changelog here: http://www.s2member.com/changelog/

If problems persist, please let me know what web server you’re running. Is it Apache?

Posted: Wednesday Feb 15th, 2012 at 12:02 am #5165

Thanks, Jason. I just tested this in v120213. As I mentioned in another post, the update had crashed my site (yes, it’s Apache/1.3.42). But I found your reply to another post where you suggested alternate code for the .htaccess file, and I pasted that in and got the site back up.

The new code for my file download looked like it was going to work. I got the “confirm file download” dialogue box, but when I clicked Okay, I got a “500 Internal Server Error.”

Posted: Thursday Feb 23rd, 2012 at 1:25 am #6056
Staff Member

So sorry for abandoning you here.
It was not intentional. Some of my threads got buried during the new site launch by mistake.

Yes, that’s correct. Also, s2Member v120219 was released shorter thereafter to improve compatibility with the Apache 1.x series. If these issues remain after upgrading to s2Member v120219, I would still recommend that you move into Apache 2.0 or higher.

Okay, I got a “500 Internal Server Error.”

Check your PHP error log. Anything there to tell the tale?

Viewing 5 replies - 1 through 5 (of 5 total)

This topic is closed to new replies. Topics with no replies for 2 weeks are closed automatically.

Old Forums (READ-ONLY): The community now lives at WP Sharks™. If you have an s2Member® Pro question, please use our new Support System.

Contacting s2Member: Please use our Support Center for bug reports, pre-sale questions & technical assistance.