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™

Blank web page instead of inline PDF

s2Member Plugin. A Membership plugin for WordPress®.

Blank web page instead of inline PDF

Postby Harty » December 22nd, 2011, 6:54 pm

As above, I click on the link to read a PDF inline, but get a blank browser page.

The PDF is for level one people, I am signed in as an admin. There is no error message.

PDF is specified as inline only on the Download options/Inline file extensions panel ( I watched Jason's videos three times on the subject of inline PDFs).

This is my URL

<a href="http://www.website.com/wp-content/plugins/?s2member-files/access-s2member-level1=Movie-making_Basics.pdf">Movie making basics</a>.

This is my default inline file extensions list: htm,html,pdf,jpg,jpeg,jpe,gif,png,mp3,mp4,flv,ogg,webm

Web pages etc open fine. But my first inline PDF is turning into a nightmare.

Suggestions welcome.

:-)
User avatar
Harty
Registered User
Registered User
 
Posts: 104
Joined: April 27, 2011
Location: New Zealand

Re: Blank web page instead of inline PDF

Postby Philly » December 22nd, 2011, 7:13 pm

Is it because you have ? sign

/wp-content/plugins/?s2member-files/access-s2member-level1=Movie-making_Basics.pdf

try

/wp-content/plugins/s2member-files/access-s2member-level1=Movie-making_Basics.pdf
User avatar
Philly
Experienced User
Experienced User
 
Posts: 48
Joined: December 19, 2011

Re: Blank web page instead of inline PDF

Postby Harty » December 22nd, 2011, 7:26 pm

Hi and thanks for your reply.
the '?' features in Jason's video. No matter.
I removed it as you suggest and now get a 404 error.

/wp-content/plugins/s2member-files/access-s2member-level1=Movie-making_Basics.pdf">Movie making basics</a>.


404: Sorry, file not found. Please contact Support for assistance.
User avatar
Harty
Registered User
Registered User
 
Posts: 104
Joined: April 27, 2011
Location: New Zealand

Re: Blank web page instead of inline PDF

Postby Philly » December 22nd, 2011, 8:03 pm

I just had a go at this:
first in /s2member-files/ I created a folder called 'access-s2member-level1'
so in /wp-content/plugins/s2member-files/access-s2member-level1/
I put Movie-making_Basics.pdf
/wp-content/plugins/s2member-files/access-s2member-level1/Movie-making_Basics.pdf
then linked to it like this
<a href="http://www.website.com/?s2member_file_download=access-s2member-level1/Movie-making_Basics.pdf">Movie making basics</a>.
User avatar
Philly
Experienced User
Experienced User
 
Posts: 48
Joined: December 19, 2011

Re: Blank web page instead of inline PDF

Postby Harty » December 22nd, 2011, 8:06 pm

Hi Philly.

Thanks for your time on this - much appreciated.

Did you get a file download or were you able to read the PDF in your browser?

Harty
User avatar
Harty
Registered User
Registered User
 
Posts: 104
Joined: April 27, 2011
Location: New Zealand

Re: Blank web page instead of inline PDF

Postby Philly » December 22nd, 2011, 8:13 pm

Hi Harty ,

Yes it reads in the browser. I hope you understand what I wrote it looks a bit sloppy reading it back
User avatar
Philly
Experienced User
Experienced User
 
Posts: 48
Joined: December 19, 2011

Re: Blank web page instead of inline PDF

Postby Harty » December 22nd, 2011, 8:16 pm

This is really strange then, because using your code, I get an option to download the file. Even though I have specified that a PDF be read inline.

Must be a glitch in my system somewhere.

Thanks again for your time. I'll play around and see where the problem is and report back.

Harty
User avatar
Harty
Registered User
Registered User
 
Posts: 104
Joined: April 27, 2011
Location: New Zealand

Re: Blank web page instead of inline PDF

Postby Philly » December 22nd, 2011, 8:23 pm

Try adding this to the end of the link &s2member_file_inline=yes
so its <a href="http://www.website.com/?s2member_file_download=access-s2member-level1/Movie-making_Basics.pdf&s2member_file_inline=yes">Movie making basics</a>
If that does not work perhaps your browser is not allowing it?
User avatar
Philly
Experienced User
Experienced User
 
Posts: 48
Joined: December 19, 2011

Re: Blank web page instead of inline PDF

Postby Harty » December 22nd, 2011, 8:42 pm

Hi,

Thanks, I had seen that code but not used it.

I just gave it a try.

I still only get an option to download the file.

I'm using the latest Firefox, but even if it was my browser causing the inline instruction to be ignored, if my customers have the same browser issue [if that's what it is] then they effectively circumvent the system and get the PDF.

Perhaps Jason or the team can chip in...

Cheers again.

Harty
User avatar
Harty
Registered User
Registered User
 
Posts: 104
Joined: April 27, 2011
Location: New Zealand

Re: Blank web page instead of inline PDF

Postby Philly » December 22nd, 2011, 9:09 pm

Are you able to open your local copy of Movie-making_Basics.pdf in firefox?

Not every browser supports inline pdf viewing, thats why the customer will be given the option to download, even so they would not be able to download or view unless they were logged in and level 1 or above.

Hope that helps
Philly
User avatar
Philly
Experienced User
Experienced User
 
Posts: 48
Joined: December 19, 2011

Re: Blank web page instead of inline PDF

Postby Harty » December 22nd, 2011, 9:40 pm

Hi.
You are correct.
I just checked my prefs in firefox, and PDF was set to download only.
I can change it to read only - and then an inline PDF opens as I want it to.

For me, this throws a spanner in the works, as I didn't want my password protected PDFs being downloaded and copied.

Copyright counts for nothing nowadays. I shall have to rethink how to present content and stop it being copied without permission.

Cheers again.

Harty
User avatar
Harty
Registered User
Registered User
 
Posts: 104
Joined: April 27, 2011
Location: New Zealand

Jason - Re: Blank web page instead of inline PDF

Postby Harty » December 23rd, 2011, 1:40 pm

Hi there Jason and the team.
Is it correct that the inline presentation of PDFs is reliant on the end user's browser settings?
Please advise.
Thanks.

Hartty
User avatar
Harty
Registered User
Registered User
 
Posts: 104
Joined: April 27, 2011
Location: New Zealand

Re: Blank web page instead of inline PDF

Postby Raam Dev » December 23rd, 2011, 3:08 pm

Hey Hartty,

Yes, to some degree that is correct. There's really no way to control how the user's browser deals with the content. All s2Member can do is provide standardized methods of presenting the file (in this case, inline, which "normally" means the browser will display it instead of presenting it as a download).

If you're using the inline feature to prevent people from downloading the PDF, that's actually not going to work. On almost any web browser, you can simply go to File -> Save File As when viewing the PDF and then save it to your computer.

Some web browsers, such as Google Chrome on the Mac, even offer a Save button right on the PDF when viewing it in the browser.
Raam Dev || Wherever you are, be there. || Please rate s2Member!
User avatar
Raam Dev
Developer
Developer
 
Posts: 810
Joined: October 26, 2011

Re: Blank web page instead of inline PDF

Postby Harty » December 23rd, 2011, 5:04 pm

Oh well, thanks for the clarification.
I'll stop making PDFs and simply present my content as restricted web pages for paid members only.
Many thanks and a merry Xmas to you.
Harty.
User avatar
Harty
Registered User
Registered User
 
Posts: 104
Joined: April 27, 2011
Location: New Zealand

Re: Blank web page instead of inline PDF

Postby Raam Dev » December 23rd, 2011, 11:43 pm

You're most welcome, Harty! Happy holidays! :)
Raam Dev || Wherever you are, be there. || Please rate s2Member!
User avatar
Raam Dev
Developer
Developer
 
Posts: 810
Joined: October 26, 2011


Return to s2Member Plugin

Who is online

Users browsing this forum: Majestic-12 [Bot] and 1 guest

cron