latest stable versions: v150827 (changelog)

Old Forums (READ-ONLY): The community now lives at WP Sharks™. If you have an s2Member® Pro question, please use our new Support System.

About: Carl Carvalho

Sorry, I've not written a description yet. I'll get to it soon!


Topics I'm Subscribed To

Viewing 3 topics - 1 through 3 (of 3 total)
Topic Count Last Reply
PayPal Recurring Billing on 1st of Month

By:  Carl Carvalho in: Community Forum

voices: 2
replies: 5

4 years ago  Cristián Lávaque

Trouble Using Variables in Pro Form Shortcode

By:  Carl Carvalho in: Community Forum

voices: 2
replies: 2

4 years ago  Cristián Lávaque

import/export of users and custom fields

By:  Wayne Hedlund in: Community Forum

voices: 4
replies: 4

4 years ago  Carl Carvalho

Viewing 3 topics - 1 through 3 (of 3 total)

Topics I've Started

Viewing 2 topics - 1 through 2 (of 2 total)
Topic Count Last Reply
PayPal Recurring Billing on 1st of Month

By:  Carl Carvalho in: Community Forum

voices: 2
replies: 5

4 years ago  Cristián Lávaque

Trouble Using Variables in Pro Form Shortcode

By:  Carl Carvalho in: Community Forum

voices: 2
replies: 2

4 years ago  Cristián Lávaque

Viewing 2 topics - 1 through 2 (of 2 total)

My Latest Replies (From Various Topics)

Viewing 4 replies - 1 through 4 (of 4 total)
Author Replies
Author Replies
Posted: Sunday Jan 6th, 2013 at 11:00 am #36383

Brilliant, Cristian! I works! Thank you!

Thank you for streamlining my PHP, too.

Posted: Thursday Jan 3rd, 2013 at 8:52 am #36105

Hi Cristian,

Thanks for your response. Here is the PHP and shortcode I am currently testing. PayPal charges the 1st month’s prorated payment, but I think the next payment date is on the anniversary of the day the member signed up (a month has not gone by, so I can’t test the next billing cycle).

This PHP:

date_default_timezone_set('America/New_York');
$days_in_month = date("t");
$price_per_day = round(10/$days_in_month, 2);
$days_left = date('t') - date('j');
$prorated_payment = round($days_left * $price_per_day, 2);
echo do_shortcode('[s2Member-Pro-PayPal-Form level="1" ccaps="" desc="1A Membership: This month prorated @ $' . number_format($prorated_payment,2) . ', then $10.00/Month (recurring charge, for ongoing access)" ps="paypal" lc="" cc="USD" dg="0" ns="1" custom="www.healthsuccesscenter.com" ta="' . number_format($prorated_payment,2) . '" tp="1" tt="M" ra="10.00" rp="1" rt="M" rr="1" rrt="" rra="2" accept="paypal,visa,mastercard,amex,discover,maestro,solo" accept_via_paypal="paypal" coupon="" accept_coupons="0" default_country_code="" captcha="clean" /]');

Generates this shortcode:

[s2Member-Pro-PayPal-Form level="1" ccaps="" desc="1A Membership: This month prorated @ $8.96, then $10.00/Month (recurring charge, for ongoing access)" ps="paypal" lc="" cc="USD" dg="0" ns="1" custom="www.healthsuccesscenter.com" ta="8.96" tp="1" tt="M" ra="10.00" rp="1" rt="M" rr="1" rrt="" rra="2" accept="paypal,visa,mastercard,amex,discover,maestro,solo" accept_via_paypal="paypal" coupon="" accept_coupons="0" default_country_code="" captcha="clean" /]

…….
The next shortcode has us charging a fee per day for the remaining days in the month, which will get us to the monthly billing on the 1st of the next month, but PayPal is making charges DAILY to the member’s card (which will be annoying to the member and VERY expensive for me).

[s2Member-Pro-PayPal-Form level="1" ccaps="" desc="1A Membership: 28 Days @ $0.32 / then $10.00 USD / Monthly ( recurring charge, for ongoing access )" ps="paypal" lc="" cc="USD" dg="0" ns="1" custom="www.healthsuccesscenter.com" ta="0.32" tp="28" tt="D" ra="10.00" rp="1" rt="M" rr="1" rrt="" rra="2" accept="paypal,visa,mastercard,amex,discover,maestro,solo" accept_via_paypal="paypal" coupon="" accept_coupons="0" default_country_code="" captcha="0" /]

I need the best of both versions for it to work for me: charge a flat fee for the remaining number of days in the month, then start the regular monthly billing cycle on the 1st of the months going forward.

What I need is for PayPal to charge a flat fee today, then start the regular monthly billing cycle on the 1st of the next month.

Posted: Tuesday Jan 1st, 2013 at 7:18 pm #35939

Ok, I figured it out. Here is the solution.

date_default_timezone_set('America/New_York');
$days_in_month = date("t");
$price_per_day = round(10/$days_in_month, 2);
$days_left = date('t') - date('j');
$prorated_payment = round($days_left * $price_per_day, 2);
echo do_shortcode('[s2Member-Pro-PayPal-Form level="1" ccaps="" desc="1A Membership: This month prorated @ $' . number_format($prorated_payment,2) . ', then $10.00/Month (recurring charge, for ongoing access)" ps="paypal" lc="" cc="USD" dg="0" ns="1" custom="www.healthsuccesscenter.com" ta="' . number_format($prorated_payment,2) . '" tp="1" tt="M" ra="10.00" rp="1" rt="M" rr="1" rrt="" rra="2" accept="paypal,visa,mastercard,amex,discover,maestro,solo" accept_via_paypal="paypal" coupon="" accept_coupons="0" default_country_code="" captcha="clean" /]');

The key is the do_shortcode command.

Happy New Year Everyone!

Posted: Saturday Dec 29th, 2012 at 6:55 pm #35763

I am having the same issue with custom profile fields not exporting properly: headers and columns don’t line up, headers are next to data.

Jacob, I am interested in the hack solution you came up with.

Thanks.

Viewing 4 replies - 1 through 4 (of 4 total)

Old Forums (READ-ONLY): The community now lives at WP Sharks™. If you have an s2Member® Pro question, please use our new Support System.

Contacting s2Member: Please use our Support Center for bug reports, pre-sale questions & technical assistance.