What would be the easiest way to block a URL being loaded after being entered in the URL bar?? It is for an html site that has a download page of an e book. I don’t want people downloaded it if they don’t pay.
How do you verify if they have paid or not? Do they get the link to the file after paying? You could give out unique download codes to each user to access the file... but please provide more information about your current system.
Couple of simple options: - integrate semantic wikis - enable rss-capable networking - integrate A-list life-hacks - remix standards-compliant tagclouds Courtesy of Empty Bottle. Second time today I say this... Mad4 is spot on.
Another solution I sometimes use is to use fpdf to generate a personalised copy of the pdf ebook and then auto email it to the customer. That way its not published on the web and if it is then you can trace the culprit pretty easily.
Thanks for the suggestions. FPDF looks good mad4 but it is for a clients website and don’t fancy teaching them to use it. I will be using paypal - I thought there is an easy method to block a url being loaded in the url bar?
Yes, by having a unique reference in the URL which links to a database which tells you whether they paid or not.
It all depends how sensitive and valuable your ebook is. If you have a randomly generated reference in a database with a 24 hour expiry then you should be safe for most purposes.
Although the suggestions already made are the best way to achieve what you need (although I'm not sure about TOPS30s' suggestion about semantic wikis and the like - that went over my head) to approach the problem slightly differently and address the question I think you are actually asking you can prevent a user typing in a link to your pdf (most of the time but it isn't 100%) by looking at the http referrer and only allowing access when the value is a page on your site.
LOL I just got that. People who use Norton block referrer headers by default so this may not be a good idea.
Where's the downside? Seriously though I agree that it isn't a good way of implementing what is needed in this situation. It does however answer the specific question asked. It's one of those situations where I think what Alan Murray thought he needed is different to what he actually needs.
Well yes because I expected it to a simple line of code! Not sure best way because this is a small website with a client that has a very basic I.T skill level.