Welcome to TheCredence.com - You may like to subscribe to our RSS feed to stay updated.
Let’s say you want to leverage the amazing RSS feed technology for your ezine, but you still want to somehow build a profit off of it. This day in age, this is a simple thing to accomplish. All you need is some PHP knowledge, some XML knowledge and a PayPal account.
Step 1: The Basic Idea
You want to build your RSS feed so that it only shows the first paragraph of the work, and then beneath it a link to allow people to pay to see the rest of the article’s content.
So, first, you need to go into your paypal account and create a new item for people to purchase, that would allow them access. Don’t over do it by asking for too much money for each article- keep it small, and build on micropayments.
With that done, have Paypal generate a button for you to use in your feed. Now comes the interesting part.
Step 2: The Feed
In your feed generation script in PHP you need to limit the article to the first paragraph (you could just use substring to do this), and then after the paragraph a link to your purchasing system. I find it easiest to use a state based machine for this task, that way you can keep your code separate from the actual content.
Step 3: Purchasing
You need to grab the article information that the user wants to read and store it in the user’s cookies. That way, when he is done paying we can redirect him to the correct article.
Next, you need a way to redirect the user after they click on paypal. You can use a simple script generator like http://paypaltech.com/SG2/ to do this. After the user verifies this is correct, pull the article data out of the cookie and give them the article that they paid for.
Links you may find interesting -
