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™

Drip content for different pricing options

s2Member Plugin. A Membership plugin for WordPress®.

Re: Drip content for different pricing options

Postby drawingsecretsrevealed » October 31st, 2011, 10:23 am

So I just need to figure out the PayPal button code problem and I can put this code for each page/post that is dripped to level #1? Got any ideas about that PayPal message I was receiving?
User avatar
drawingsecretsrevealed
Registered User
Registered User
 
Posts: 61
Joined: June 15, 2011

Re: Drip content for different pricing options

Postby drawingsecretsrevealed » October 31st, 2011, 10:57 am

Do you have any idea why I got that error PayPal message? Once I get that figured out, I can just generate a button for Level #2 and use your snippet!
User avatar
drawingsecretsrevealed
Registered User
Registered User
 
Posts: 61
Joined: June 15, 2011

Re: Drip content for different pricing options

Postby Cristián Lávaque » October 31st, 2011, 11:43 pm

What error is that?
Cristián Lávaque http://s2member.net
Is s2Member working for you? Please rate it Image at WordPress.org. Thanks! :)
User avatar
Cristián Lávaque
Developer
Developer
 
Posts: 6836
Joined: December 22, 2010

Re: Drip content for different pricing options

Postby drawingsecretsrevealed » November 1st, 2011, 9:59 am

The error message I posted earlier in the thread. I've attached it again here.
Attachments
Screen%20shot%202011-10-25%20at%202.43.57%20PM.png
Screen%20shot%202011-10-25%20at%202.43.57%20PM.png (142.36 KiB) Viewed 585 times
User avatar
drawingsecretsrevealed
Registered User
Registered User
 
Posts: 61
Joined: June 15, 2011

Re: Drip content for different pricing options

Postby Cristián Lávaque » November 2nd, 2011, 1:53 am

Got it. I forgot about that and didn't notice we're on page two of the thread, I just read the previous posts in this page and didn't see the error mentioned, so I asked again. Sorry about that.

Could you post the related log entries please? x'ing out any private info. WP Admin -> s2Member -> PayPal Options -> Account Details -> Enable Logging
Cristián Lávaque http://s2member.net
Is s2Member working for you? Please rate it Image at WordPress.org. Thanks! :)
User avatar
Cristián Lávaque
Developer
Developer
 
Posts: 6836
Joined: December 22, 2010

Re: Drip content for different pricing options

Postby drawingsecretsrevealed » November 2nd, 2011, 9:52 am

I went there and logging was disabled. I enabled it and found the s2member-logs file. There were two: paypalipn.log and paypalrtn.log. Which one do I post? And there is so much text here - what sort of private info would I be looking for?
User avatar
drawingsecretsrevealed
Registered User
Registered User
 
Posts: 61
Joined: June 15, 2011

Re: Drip content for different pricing options

Postby Eduan » November 2nd, 2011, 10:07 am

@drawingsecretsrevealed
You should put both, paypalipn.log and paypalrtn.log (just in case).

About the private info, x out any email address, PayPal account number, your website address etc. Anything that only you should know, or anything that not everyone should know.
Now officially accepting Professional s2Member installations along with Bruce C (a.k.a. Ace).

If you're interested in a Professional s2Member Installation, or a Custom Coding Job, you can send your request here.
User avatar
Eduan
Experienced User
Experienced User
 
Posts: 1154
Joined: August 27, 2011
Location: Taxco de Alarcón, Guerrero, México.

Re: Drip content for different pricing options

Postby Eduan » November 2nd, 2011, 11:52 am

I checked it and I found something:
2 => 'Unable to verify _SERVER[HTTP_HOST]. Possibly caused by a fraudulent request. If this error continues, please check the `custom` value in your Form and/or Button Code. It MUST always start with your domain name.',

That may be the cause, check your button and make sure your URL is correct. Mine doesn't have the "http://www.mysite.com/", mine is only "www.mysite.com" without anything else. In other words the custom value should be like this:
custom="www.yoursite.com"

P.S. Take into account that if your site doesn't have www then you don't have to include it.
Now officially accepting Professional s2Member installations along with Bruce C (a.k.a. Ace).

If you're interested in a Professional s2Member Installation, or a Custom Coding Job, you can send your request here.
User avatar
Eduan
Experienced User
Experienced User
 
Posts: 1154
Joined: August 27, 2011
Location: Taxco de Alarcón, Guerrero, México.

Re: Drip content for different pricing options

Postby drawingsecretsrevealed » November 2nd, 2011, 12:50 pm

How do I know if my site doesn't have the "www" or whether or not it should?
User avatar
drawingsecretsrevealed
Registered User
Registered User
 
Posts: 61
Joined: June 15, 2011

Re: Drip content for different pricing options

Postby Eduan » November 2nd, 2011, 12:53 pm

Try this post:
viewtopic.php?f=36&t=1066

Oh and I know because I registered my website without the www.
Now officially accepting Professional s2Member installations along with Bruce C (a.k.a. Ace).

If you're interested in a Professional s2Member Installation, or a Custom Coding Job, you can send your request here.
User avatar
Eduan
Experienced User
Experienced User
 
Posts: 1154
Joined: August 27, 2011
Location: Taxco de Alarcón, Guerrero, México.

Re: Drip content for different pricing options

Postby Cristián Lávaque » November 2nd, 2011, 10:42 pm

drawingsecretsrevealed wrote:I went there and logging was disabled. I enabled it and found the s2member-logs file. There were two: paypalipn.log and paypalrtn.log. Which one do I post? And there is so much text here - what sort of private info would I be looking for?


I checked the logs you posted. The IPN one was mostly old entries and had some personal info, and the RTN one looked like a file from your Mac OS system. I removed both posts to avoid confusion. :|

Could you please keep logging on, wait for a transaction to give you that error and then post here, only the related entries to the transaction with the error? Thanks! :)
Cristián Lávaque http://s2member.net
Is s2Member working for you? Please rate it Image at WordPress.org. Thanks! :)
User avatar
Cristián Lávaque
Developer
Developer
 
Posts: 6836
Joined: December 22, 2010

Re: Drip content for different pricing options

Postby drawingsecretsrevealed » November 15th, 2011, 5:31 pm

Cristián Lávaque wrote:Great! It's pretty simple to do with conditionals. Something like this:

Code: Select all
<?php if (current_user_can('access_s2member_level2') || (current_user_can('access_s2member_level1') && S2MEMBER_CURRENT_USER_PAID_REGISTRATION_DAYS >= 30)) { ?>
Show the content.
<?php } else { ?>
Sell him the access to it.
<?php } ?>


I hope that helps. :)


Okay, I have a question about this PHP script. Would this replace the current conditional snippet I have, which I have pasted below? Can I just use the script you gave to give (1) weekly dripped access to Level #1 members and (2) immediate access to all content to Level #2 members?

Current PHP script:

<?php if(S2MEMBER_CURRENT_USER_PAID_REGISTRATION_DAYS >= 7){ ?>
(the day changes for each week's video lesson)

CONTENT

<?php } else { ?>

This lesson will be available for viewing one week after the previous lesson became available, to give you the chance to watch the previous lessons and practice the concepts presented there.

<?php } ?>
User avatar
drawingsecretsrevealed
Registered User
Registered User
 
Posts: 61
Joined: June 15, 2011

Re: Drip content for different pricing options

Postby drawingsecretsrevealed » November 15th, 2011, 5:34 pm

And I tried generating a Level #2 button again and got the same long error message. It kept referencing $_POST variables. What are these?
User avatar
drawingsecretsrevealed
Registered User
Registered User
 
Posts: 61
Joined: June 15, 2011

Re: Drip content for different pricing options

Postby Cristián Lávaque » November 17th, 2011, 12:04 am

My conditional would give instant access to all content for Level 2 users, and the dripped access to content for Level 1 users. Actually, I think this'd be better:

Code: Select all
<?php if (current_user_can('access_s2member_level2') || (current_user_can('access_s2member_level1') && S2MEMBER_CURRENT_USER_PAID_REGISTRATION_DAYS >= 30)) { ?>
Show the content.
<?php } elseif (current_user_can('access_s2member_level1')) { ?>
Available in <?php echo (30 S2MEMBER_CURRENT_USER_PAID_REGISTRATION_DAYS); ?> days.
<?php } else { ?>
Sell him the access to it.
<?php ?>


About the error, please post the log entries (from all the log files) related to the transaction that gave the error, x'ing out any private info, please. WP Admin -> s2Member -> PayPal Options -> Account Details -> Enable Logging
Cristián Lávaque http://s2member.net
Is s2Member working for you? Please rate it Image at WordPress.org. Thanks! :)
User avatar
Cristián Lávaque
Developer
Developer
 
Posts: 6836
Joined: December 22, 2010

Re: Drip content for different pricing options

Postby drawingsecretsrevealed » November 17th, 2011, 11:29 am

Here's the ipn log info:


PHP v5.2.17 :: WordPress® v3.2.1 :: s2Member® v111105
Memory 28.73 MB :: Real Memory 30.00 MB :: Peak Memory 29.20 MB :: Real Peak Memory 30.00 MB
XXX.com/?s2member_paypal_notify=1
User-Agent:
array (
'txn_type' => 'subscr_eot',
'subscr_id' => 'I-147N0RK9LGRD',
'last_name' => 'XXX',
'option_selection1' => '1',
'option_selection2' => '---.--.---.---',
'residence_country' => 'US',
'item_name' => 'Bronze Member / 1 cent for 1 day access',
'mc_currency' => 'USD',
'business' => 'XXX@XXX.com',
'verify_sign' => 'A19KZgRoW0dLb4lJxEgc4bQBFixcA6SbMSm7Xej2x8uANaE5nJKV4JxK',
'payer_status' => 'verified',
'payer_email' => 'XXX@XXX.com',
'first_name' => 'XXX',
'receiver_email' => 'XXX@XXX.com',
'option_name1' => 'Referencing Customer ID',
'payer_id' => 'H6MFMH7AWJD4L',
'invoice' => '4ec53423bacd1~108.11.166.162',
'option_name2' => 'Customer IP Address',
'item_number' => '1',
'custom' => 'XXX.com',
'charset' => 'windows-1252',
'notify_version' => '3.4',
'ipn_track_id' => 'mDdnjYX86DGQ0ARAd1ubtw',
's2member_log' =>
array (
0 => 'IPN received on: Thu Nov 17, 2011 4:20:13 pm UTC',
1 => 's2Member POST vars verified through a POST back to PayPal®.',
2 => 's2Member originating domain ( `$_SERVER["HTTP_HOST"]` ) validated.',
3 => 's2Member `txn_type` identified as ( `subscr_eot|recurring_payment_expired|recurring_payment_suspended_due_to_max_failed_payment` ) - or - `recurring_payment_profile_cancel` w/ `initial_payment_status` ( `failed` ).',
4 => 'Sleeping for 5 seconds. Waiting for a possible ( `subscr_signup|subscr_modify|recurring_payment_profile_created` ).',
5 => 'Awake. It\'s Thu Nov 17, 2011 4:20:18 pm UTC. s2Member `txn_type` identified as ( `subscr_eot|recurring_payment_expired|recurring_payment_suspended_due_to_max_failed_payment` ) - or - `recurring_payment_profile_cancel` w/ `initial_payment_status` ( `failed` ).',
6 => 'Skipping this IPN response, for now. The Subscr. ID is not associated with a registered Member.',
7 => 'Re-generating. This IPN will go into a Transient Queue; and be re-processed during registration.',
),
'subscr_gateway' => 'paypal',
'period1' => '0 D',
'period3' => '1 D',
'ip' => '---.--.---.---',
User avatar
drawingsecretsrevealed
Registered User
Registered User
 
Posts: 61
Joined: June 15, 2011

Re: Drip content for different pricing options

Postby Cristián Lávaque » November 20th, 2011, 10:36 pm

Thanks. That log entry shows the payment wasn't successful. Not sure if it's related to the error you saw. Was it the same error you showed earlier or a different one?
Cristián Lávaque http://s2member.net
Is s2Member working for you? Please rate it Image at WordPress.org. Thanks! :)
User avatar
Cristián Lávaque
Developer
Developer
 
Posts: 6836
Joined: December 22, 2010

Re: Drip content for different pricing options

Postby drawingsecretsrevealed » November 21st, 2011, 11:26 am

Yes, the exact same message.
User avatar
drawingsecretsrevealed
Registered User
Registered User
 
Posts: 61
Joined: June 15, 2011

Re: Drip content for different pricing options

Postby Cristián Lávaque » November 25th, 2011, 3:05 am

Odd. The log doesn't show a problem with $_POST vars and you're saying that log entry is related to a transaction that showed that error. Did you follow the instructions in the error regarding cURL and allow_url_fopen? I'm not sure what thread it's linking to, but this one is realted to cURL and allow_url_fopen: viewtopic.php?f=36&t=2636#p7577
Cristián Lávaque http://s2member.net
Is s2Member working for you? Please rate it Image at WordPress.org. Thanks! :)
User avatar
Cristián Lávaque
Developer
Developer
 
Posts: 6836
Joined: December 22, 2010

Re: Drip content for different pricing options

Postby drawingsecretsrevealed » November 28th, 2011, 12:21 pm

Cristián Lávaque wrote:Did you follow the instructions in the error regarding cURL and allow_url_fopen? I'm not sure what thread it's linking to, but this one is realted to cURL and allow_url_fopen: viewtopic.php?f=36&t=2636#p7577


I'm afraid I have no idea what you meant there. None of that is familiar. What does that mean??
User avatar
drawingsecretsrevealed
Registered User
Registered User
 
Posts: 61
Joined: June 15, 2011

Re: Drip content for different pricing options

Postby Cristián Lávaque » November 29th, 2011, 1:15 am

In the error you posted earlier it mentions those things:

Image

The post I linked to has a test you can run to check if they're working in your server.
Cristián Lávaque http://s2member.net
Is s2Member working for you? Please rate it Image at WordPress.org. Thanks! :)
User avatar
Cristián Lávaque
Developer
Developer
 
Posts: 6836
Joined: December 22, 2010

Re: Drip content for different pricing options

Postby drawingsecretsrevealed » November 29th, 2011, 11:09 am

I explored PayPal further and do you know what it was? The return URL was wrong, that was all. The domain had changed but I hadn't changed the return URL! Problem fixed! I guess keep that in mind in case another customer has a similar problem. :)
User avatar
drawingsecretsrevealed
Registered User
Registered User
 
Posts: 61
Joined: June 15, 2011

Re: Drip content for different pricing options

Postby Cristián Lávaque » December 1st, 2011, 1:46 am

lol... Thanks for reporting back. I should kick myself for assuming your PayPal settings were right and not asking you to double check the PayPal settings. Sorry for not thinking of that sooner.

I'm very glad you solved it. :)
Cristián Lávaque http://s2member.net
Is s2Member working for you? Please rate it Image at WordPress.org. Thanks! :)
User avatar
Cristián Lávaque
Developer
Developer
 
Posts: 6836
Joined: December 22, 2010

Previous

Return to s2Member Plugin

Who is online

Users browsing this forum: Yahoo [Bot] and 2 guests

cron