Haypenny JavaScript Examples

Haypenny is unique in that it allows a pure client-side payment solution for paywalls and donation buttons. This example is meant to be extremely simple (hence the lack of fancier styles) so you can easily incorporate the ideas here into your own code. The code to run these examples is just a few lines long (view the page source to see).

Unlike other payment solutions for paywalls and donation buttons, your users will never leave your page and will not need to sign up for absolutely anything in order to make their payment if they already have a a Haypenny block--and they can do so safely (for you too, since you don't have to worry about storing their personal information).

Donation Button

Please donate a Haypenny block of any amount to help me keep giving you this great content!






Paywall Example

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nulla condimentum nec libero vel viverra. Vivamus sem sapien, malesuada euismod viverra nec, finibus in mi. Proin eget leo id ante laoreet scelerisque ac id lacus. Maecenas ultricies vel nisl a efficitur. Duis vel elit ex. Duis dolor justo, vehicula vitae tincidunt vitae, suscipit at justo. Sed viverra tincidunt orci in porttitor. Proin risus erat, scelerisque vel mattis ac, consequat eu dolor. Integer ultricies ante id diam ullamcorper posuere. Sed faucibus tortor at rhoncus vehicula. Sed auctor in ligula sed tempus. Curabitur porta interdum tristique. Quisque quis metus magna.

Please pay fifty cents ($0.50) with Haypenny currency to see the rest of this story.

Anonymous payment. No sign up necessary.






Penny Tray

Although they say different above in order to make the demo more realistic, the paywall here just charges one penny (and the donation takes whatever block its given). You can use the "penny tray" below to get a block so you can run this demo.

Your free penny tray block:
click to get a block