Page 1 of 1

Gift specific page access

PostPosted: December 20th, 2011, 7:25 pm
by Michelle
HI! I'm loving s2Member - what a powerful plugin.

Can anyone advise if this scenario is possible?

I sell a digital product that you can buy for yourself for $15, or you can buy a 2 pack (one for you and one for a friend) for $25. For the 2 pack when payment is completed you are taken to a specific page with a link to download the pdf for yourself and then I need a method to securely provide free access to the download for the friend.

So... I'm thinking one of these approaches:
1. when buyer is directed to specific page to download their copy they enter friends email into a field and then click "Send Free Copy" which emails the friend access information. Like using the Specific Post/Page Link Generator, but without me having to do it manually. I also saw this post by Jason that may be related:
viewtopic.php?f=4&t=14187&p=32287&hilit=gift+specific+page#p29665

OR

2. after payment is completed the buyer receives an email with a unique, generated discount/coupon code that they forward to their friend. Friend then buys access to specific page, enters code and gets access for free. Coupon code could be entered at s2Member step or at Paypal payment step.

Is any of this possible? Without me needed to be a php/coding guru - which I'm not, and I don't have the funds at the moment to pay for one.

Thanks, any advice will be greatly appreciated!!

Re: Gift specific page access

PostPosted: December 20th, 2011, 8:27 pm
by cassel
I'll be watching for this thread but i know already that you cannot use a coupon that will make something free (or a coupon for 100% off). It was mentioned in another thread as i am looking at selling some access to my site through someone else's zencart. I still have to figure out how. This thread might help me too.

Re: Gift specific page access

PostPosted: December 20th, 2011, 11:25 pm
by Raam Dev
Hi Cassel,

Glad to hear you're loving s2Member! Thank you for the kudos! :)

Your first approach sounds like the best solution to me. Based on Jason's code in this post, you could install the PHP Execution plugin and then add some PHP code to your product page that looks like this:

Code: Select all
<?php
$post_or_page_id 
= $post->ID; // This assumes the current page is the page you want an access link for
$access_link = c_ws_plugin__s2member_sp_access::sp_access_link_gen($post_or_page_id);
?>

Please email this link to your friend access to this product:
<?php echo $access_link; ?>


Then, when your customer purchases a 2-pack and arrives at the product page, they'll see that note with the fresh access link to copy, page, and send to their friend.

As you mentioned, you could also get a little more elaborate and generate an HTML form that includes a pre-defined message with the access link included in the text box. Then your customer would only need to fill in the email address and press send. However, this would require a little coding.

Re: Gift specific page access

PostPosted: December 21st, 2011, 7:13 am
by Michelle
Raam,

thank you so much for your help. I've tested this and I can get the link to generate.

But now I have more questions!!

How do I limit the time the link is valid for? Is this just some extra code to add to your sample?

My main concern now is locking this down so the links can't be shared indiscriminately (I know we can't completely stop sharing, but I'd like to limit it).

I have setup in ejunkie exactly how I want this to work , but I'd rather be doing it with s2Member.

In ejunkie: person buys 2 pack, payment is processed by Paypal and then they are sent back to ejunkie to my custom thankyou/download page (limited to 3 downloads or 5 days) and they download their copy. They also receive an email with a discount code for the full value of a single copy, plus sample text for an email to send to their friend, the recipient of the free copy. Discount code is only good for 1 use.

Friend clicks link in this email to go to my website and purchase single copy. They then enter the discount code which zeros the price, they continue to ejunkie's free checkout where they have to enter name and email details (which I can capture if required for mailing list, etc). They are then redirected to my custom thankyou/download page (also limited to 3 downloads or 5 days) where they download their free copy.

So, I'm thinking to implement a similar scenario in s2Member I would have:
- specific page buy now button on my shop page that is limited to 5 days
- this provides access to a specific page #1 that has their download link so they can get their copy, sample email text plus the code from Raam for a specific page #2 that they copy and paste into email to a friend
- friend clicks generated link and is taken to specific page #2 that only has download link, no option to generate another link.
- all download links are done using Advanced Download Restrictions to provide access to secure files to non-members.

Issues I see with this is that the buyer could forward the access link to an unlimited number of people who will be able to access the page so long as they do it within the time frame. Also, I have no way of capturing the email address of the friend to add to my mailing list, or to confirm that they are entitled to a copy of the download.

Is that right? Am I missing any other issues I should be considering?

And does anyone know of a way to get around these issues?

Can I require they submit an email address prior to displaying the download link? How would I do this?

And, I'm thinking of offering a 5 pack - one for the buyer and 4 to give as gifts. How would I handle this?

Thank you again!

Re: Gift specific page access

PostPosted: December 21st, 2011, 4:30 pm
by Raam Dev
For the 5-pack, you can simply generate 4 access links (each time you run the generate code, it will generate a unique link) and then share those 4 links as described above. You could also write some PHP/HTML code that generates a form with 4 text boxes so that your customer can enter 4 email addresses and then press Send. Again, this is a bit more complicated and you'll need to write the necessary code.

Regarding sharing the links, s2Member has built-in Unique IP Restriction options to help prevent this. Please see the options under WP Admin -> s2Member -> Restriction Options -> Unique IP Access Restrictions.