Community Support Forums — WordPress® ( Users Helping Users ) — 2011-12-20T09:52:07-05:00 http://www.primothemes.com/forums/feed.php?f=40&t=13260 2011-12-20T09:52:07-05:00 http://www.primothemes.com/forums/viewtopic.php?t=13260&p=58019#p58019 <![CDATA[s2Member v111220 / Source Code: s2member-p...]]>
s2Member v111220
Source Code: s2member-pro\includes\classes\gateways\paypal\paypal-registration-in.inc.php
Docs updated: December 20, 2011, 9:52 am

Open for public discussion.
(!-- s-words :: --)n/a(!-- :: s-words --)

Statistics: Posted by System Robot — December 20th, 2011, 9:52 am


]]>
2011-12-07T01:05:23-05:00 http://www.primothemes.com/forums/viewtopic.php?t=13260&p=55701#p55701 <![CDATA[s2Member v111206 / Source Code: s2member-p...]]>
s2Member v111206
Source Code: s2member-pro\includes\classes\gateways\paypal\paypal-registration-in.inc.php
Docs updated: December 7, 2011, 1:05 am

Open for public discussion.
(!-- s-words :: --)n/a(!-- :: s-words --)

Statistics: Posted by System Robot — December 7th, 2011, 1:05 am


]]>
2011-11-05T19:27:57-05:00 http://www.primothemes.com/forums/viewtopic.php?t=13260&p=52075#p52075 <![CDATA[s2Member v111105 / Source Code: s2member-p...]]>
s2Member v111105
Source Code: s2member-pro\includes\classes\gateways\paypal\paypal-registration-in.inc.php
Docs updated: November 5, 2011, 8:28 pm

Open for public discussion.
(!-- s-words :: --)n/a(!-- :: s-words --)

Statistics: Posted by System Robot — November 5th, 2011, 7:27 pm


]]>
2011-10-29T20:37:30-05:00 http://www.primothemes.com/forums/viewtopic.php?t=13260&p=50171#p50171 <![CDATA[s2Member v111029 / Source Code: s2member-p...]]>
s2Member v111029
Source Code: s2member-pro\includes\classes\gateways\paypal\paypal-registration-in.inc.php
Docs updated: October 29, 2011, 9:37 pm

Open for public discussion.
(!-- s-words :: --)n/a(!-- :: s-words --)

Statistics: Posted by System Robot — October 29th, 2011, 8:37 pm


]]>
2011-10-17T15:41:50-05:00 http://www.primothemes.com/forums/viewtopic.php?t=13260&p=47965#p47965 <![CDATA[s2Member v111017 / Source Code: s2member-p...]]>
s2Member v111017
Source Code: s2member-pro\includes\classes\gateways\paypal\paypal-registration-in.inc.php
Docs updated: October 17, 2011, 1:41 pm

Open for public discussion.
(!-- s-words :: --)n/a(!-- :: s-words --)

Statistics: Posted by System Robot — October 17th, 2011, 3:41 pm


]]>
2011-10-11T14:37:41-05:00 http://www.primothemes.com/forums/viewtopic.php?t=13260&p=46367#p46367 <![CDATA[s2Member v111011 / Source Code: s2member-p...]]>
s2Member v111011
Source Code: s2member-pro\includes\classes\gateways\paypal\paypal-registration-in.inc.php
Docs updated: October 11, 2011, 12:37 pm

Open for public discussion.
(!-- s-words :: --)n/a(!-- :: s-words --)

Statistics: Posted by System Robot — October 11th, 2011, 2:37 pm


]]>
2011-10-03T15:50:06-05:00 http://www.primothemes.com/forums/viewtopic.php?t=13260&p=44496#p44496 <![CDATA[s2Member v111003 / Source Code: s2member-p...]]>
s2Member v111003
Source Code: s2member-pro\includes\classes\gateways\paypal\paypal-registration-in.inc.php
Docs updated: October 3, 2011, 1:50 pm

Open for public discussion.
(!-- s-words :: --)n/a(!-- :: s-words --)

Statistics: Posted by System Robot — October 3rd, 2011, 3:50 pm


]]>
2011-10-03T03:43:51-05:00 http://www.primothemes.com/forums/viewtopic.php?t=13260&p=43203#p43203 <![CDATA[s2Member v111002 / Source Code: s2member-p...]]>
s2Member v111002
Source Code: s2member-pro\includes\classes\gateways\paypal\paypal-registration-in.inc.php
Docs updated: October 3, 2011, 1:43 am

Open for public discussion.
(!-- s-words :: --)n/a(!-- :: s-words --)

Statistics: Posted by System Robot — October 3rd, 2011, 3:43 am


]]>
2011-09-27T05:28:36-05:00 http://www.primothemes.com/forums/viewtopic.php?t=13260&p=41445#p41445 <![CDATA[s2Member v110927 / Source Code: s2member-p...]]>
s2Member v110927
Source Code: s2member-pro\includes\classes\gateways\paypal\paypal-registration-in.inc.php
Docs updated: September 27, 2011, 3:28 am

Open for public discussion.
(!-- s-words :: --)n/a(!-- :: s-words --)

Statistics: Posted by System Robot — September 27th, 2011, 5:28 am


]]>
2011-09-26T21:05:09-05:00 http://www.primothemes.com/forums/viewtopic.php?t=13260&p=40201#p40201 <![CDATA[s2Member v110926 / Source Code: s2member-p...]]>
s2Member v110926
Source Code: s2member-pro\includes\classes\gateways\paypal\paypal-registration-in.inc.php
Docs updated: September 26, 2011, 7:05 pm

Open for public discussion.
(!-- s-words :: --)n/a(!-- :: s-words --)

Statistics: Posted by System Robot — September 26th, 2011, 9:05 pm


]]>
2011-09-17T17:04:23-05:00 http://www.primothemes.com/forums/viewtopic.php?t=13260&p=38345#p38345 <![CDATA[s2Member v110915 / Source Code: s2member-p...]]>
s2Member v110915
Source Code: s2member-pro\includes\classes\gateways\paypal\paypal-registration-in.inc.php
Docs updated: September 17, 2011, 3:04 pm

Open for public discussion.
(!-- s-words :: --)n/a(!-- :: s-words --)

Statistics: Posted by System Robot — September 17th, 2011, 5:04 pm


]]>
2011-09-14T01:29:39-05:00 http://www.primothemes.com/forums/viewtopic.php?t=13260&p=36923#p36923 <![CDATA[s2Member v110913 / Source Code: s2member-p...]]>
s2Member v110913
Source Code: s2member-pro\includes\classes\gateways\paypal\paypal-registration-in.inc.php
Docs updated: September 13, 2011, 11:29 pm

Open for public discussion.
(!-- s-words :: --)n/a(!-- :: s-words --)

Statistics: Posted by System Robot — September 14th, 2011, 1:29 am


]]>
2011-09-13T12:04:29-05:00 http://www.primothemes.com/forums/viewtopic.php?t=13260&p=35651#p35651 <![CDATA[s2Member v110912 / Source Code: s2member-p...]]>
s2Member v110912
Source Code: s2member-pro\includes\classes\gateways\paypal\paypal-registration-in.inc.php
Docs updated: September 13, 2011, 10:04 am

Open for public discussion.
(!-- s-words :: --)n/a(!-- :: s-words --)

Statistics: Posted by System Robot — September 13th, 2011, 12:04 pm


]]>
2011-08-15T15:17:42-05:00 http://www.primothemes.com/forums/viewtopic.php?t=13260&p=31759#p31759 <![CDATA[s2Member v110815 / Source Code: s2member-p...]]>
s2Member v110815
Source Code: s2member-pro\includes\classes\gateways\paypal\paypal-registration-in.inc.php
Docs updated: August 15, 2011, 4:17 pm

Open for public discussion.
(!-- s-words :: --)Source Code Documentation Packages ( Overview ) Classes Deprecated Todo Index Source Code jQuery(window).load(function(){ if(typeof location.hash === 'string' && location.hash.match(/^#/)) jQuery('olli'+location.hash).addClass('hilite'); }); jQuery(window).bind('hashchange', function(){ if(typeof location.hash === 'string' && location.hash.match(/^#/)) jQuery('olli').removeClass('hilite'); jQuery('olli'+location.hash).addClass('hilite'); }); [ full view ]s2member-pro\includes\classes\gateways\paypal\paypal-registration-in.inc.php ?php /** * PayPal® Registration Form ( inner processing routines ). * * Copyright: © 2009-2011 * {@link http://www.websharks-inc.com/ WebSharks, Inc.} * ( coded in the USA ) * * This WordPress® plugin ( s2Member Pro ) is comprised of two parts: * * o (1) Its PHP code is licensed under the GPL license, as is WordPress®. * You should have received a copy of the GNU General Public License, * along with this software. In the main directory, see: /licensing/ * If not, see: {@link http://www.gnu.org/licenses/}. * * o (2) All other parts of ( s2Member Pro ); including, but not limited to: * the CSS code, some JavaScript code, images, and design; * are licensed according to the license purchased. * See: {@link http://www.s2member.com/prices/} * * Unless you have our prior written consent, you must NOT directly or indirectly license, * sub-license, sell, resell, or provide for free; part (2) of the s2Member Pro Module; * or make an offer to do any of these things. All of these things are strictly * prohibited with part (2) of the s2Member Pro Module. * * Your purchase of s2Member Pro includes free lifetime upgrades via s2Member.com * ( i.e. new features, bug fixes, updates, improvements ); along with full access * to our video tutorial library: {@link http://www.s2member.com/videos/} * * @package s2Member\PayPal * @since 1.5 */ if ( realpath ( __FILE__ ) === realpath ( $_SERVER [ "SCRIPT_FILENAME" ] ) ) exit ( "Do not access this file directly." ) ; /**/ if ( ! class_exists ( "c_ws_plugin__s2member_pro_paypal_registration_in" ) ) { /** * PayPal® Registration Form ( inner processing routines ). * * @package s2Member\PayPal * @since 1.5 */ class c_ws_plugin__s2member_pro_paypal_registration_in { /** * Handles processing of Pro Form registrations. * * @package s2Member\PayPal * @since 1.5 * * @attaches-to ``add_action("init");`` * * @return null Or exits script execution after a custom URL redirection. */ public static function paypal_registration ( ) { if ( ! empty ( $_POST [ "s2member_pro_paypal_registration" ] [ "nonce" ] ) && ( $nonce = $_POST [ "s2member_pro_paypal_registration" ] [ "nonce" ] ) && wp_verify_nonce ( $nonce , "s2member-pro-paypal-registration" ) ) { $GLOBALS [ "ws_plugin__s2member_pro_paypal_registration_response" ] = array ( ) ; /* This holds the global response details. */ $global_response = & $GLOBALS [ "ws_plugin__s2member_pro_paypal_registration_response" ] ; /* This is a shorter reference. */ /**/ $post_vars = c_ws_plugin__s2member_utils_strings:: trim_deep ( stripslashes_deep ( $_POST [ "s2member_pro_paypal_registration" ] ) ) ; $post_vars [ "attr" ] = unserialize (c_ws_plugin__s2member_utils_encryption:: decrypt ( $post_vars [ "attr" ] ) ) ; /* And run a Filter. */ $post_vars [ "attr" ] = apply_filters ( "ws_plugin__s2member_pro_paypal_registration_post_attr" , $post_vars [ "attr" ] , get_defined_vars ( ) ) ; /**/ $post_vars [ "recaptcha_challenge_field" ] = ( ! $post_vars [ "recaptcha_challenge_field" ] ) ? trim ( stripslashes ( $_POST [ "recaptcha_challenge_field" ] ) ) : $post_vars [ "recaptcha_challenge_field" ] ; $post_vars [ "recaptcha_response_field" ] = ( ! $post_vars [ "recaptcha_response_field" ] ) ? trim ( stripslashes ( $_POST [ "recaptcha_response_field" ] ) ) : $post_vars [ "recaptcha_response_field" ] ; /**/ $post_vars [ "email" ] = apply_filters ( "user_registration_email" , sanitize_email ( $post_vars [ "email" ] ) , get_defined_vars ( ) ) ; $post_vars [ "username" ] = preg_replace ( "/\s+/" , "" , sanitize_user ( $post_vars [ "username" ] , is_multisite ( ) ) ) ; /**/ if ( !c_ws_plugin__s2member_pro_paypal_responses:: paypal_form_attr_validation_errors ( $post_vars [ "attr" ] ) ) /* Must NOT have any attr errors. */ { if ( ! ( $error = c_ws_plugin__s2member_pro_paypal_responses:: paypal_form_submission_validation_errors ( "registration" , $post_vars ) ) ) { if ( ! ( $create_user = array ( ) ) ) /* Build post fields for registration configuration, and then the creation array. */ { $_POST [ "ws_plugin__s2member_custom_reg_field_user_pass1" ] = $post_vars [ "password1" ] ; /* Fake this for registration configuration. */ $_POST [ "ws_plugin__s2member_custom_reg_field_first_name" ] = $post_vars [ "first_name" ] ; /* Fake this for registration configuration. */ $_POST [ "ws_plugin__s2member_custom_reg_field_last_name" ] = $post_vars [ "last_name" ] ; /* Fake this for registration configuration. */ $_POST [ "ws_plugin__s2member_custom_reg_field_opt_in" ] = $post_vars [ "custom_fields" ] [ "opt_in" ] ; /* Fake this too. */ /**/ if ( $GLOBALS [ "WS_PLUGIN__" ] [ "s2member" ] [ "o" ] [ "custom_reg_fields" ] ) foreach ( json_decode ( $GLOBALS [ "WS_PLUGIN__" ] [ "s2member" ] [ "o" ] [ "custom_reg_fields" ] , true ) as $field ) { $field_var = preg_replace ( "/[^a-z0-9]/i" , "_" , strtolower ( $field [ "id" ] ) ) ; $field_id_class = preg_replace ( "/_/" , "-" , $field_var ) ; /**/ if ( isset ( $post_vars [ "custom_fields" ] [ $field_var ] ) ) $_POST [ "ws_plugin__s2member_custom_reg_field_" . $field_var ] = $post_vars [ "custom_fields" ] [ $field_var ] ; } /**/ $GLOBALS [ "ws_plugin__s2member_registration_vars" ] [ "ws_plugin__s2member_custom_reg_field_s2member_level" ] = $post_vars [ "attr" ] [ "level" ] ; $GLOBALS [ "ws_plugin__s2member_registration_vars" ] [ "ws_plugin__s2member_custom_reg_field_s2member_ccaps" ] = $post_vars [ "attr" ] [ "ccaps" ] ; $GLOBALS [ "ws_plugin__s2member_registration_vars" ] [ "ws_plugin__s2member_custom_reg_field_s2member_auto_eot_time" ] = $post_vars [ "attr" ] [ "tp" ] . " " . $post_vars [ "attr" ] [ "tt" ] ; $_EOT_ = & $GLOBALS [ "ws_plugin__s2member_registration_vars" ] [ "ws_plugin__s2member_custom_reg_field_s2member_auto_eot_time" ] ; /* Quick/shorter reference to this var. */ $_EOT_ = ( $post_vars [ "attr" ] [ "tp" ] && $post_vars [ "attr" ] [ "tt" ] ) ? date ( "Y-m-d H:i:s" , c_ws_plugin__s2member_utils_time:: auto_eot_time ( "" , "" , "" , $_EOT_ ) ) : "" ; $GLOBALS [ "ws_plugin__s2member_registration_vars" ] [ "ws_plugin__s2member_custom_reg_field_s2member_custom" ] = $post_vars [ "attr" ] [ "custom" ] ; unset ( $_EOT_ ) ; /* We can unset this shorter/reference variable now. */ /**/ $GLOBALS [ "ws_plugin__s2member_registration_return_url" ] = $post_vars [ "attr" ] [ "success" ] ; /* Custom success return. */ /**/ $create_user [ "user_login" ] = $post_vars [ "username" ] ; /* Copy this into a separate array for `wp_create_user()`. */ $create_user [ "user_pass" ] = wp_generate_password ( ) ; /* Which may fire `c_ws_plugin__s2member_registrations::generate_password()`. */ $create_user [ "user_email" ] = $post_vars [ "email" ] ; /* Copy this into a separate array for `wp_create_user()`. */ } /**/ if ( $post_vars [ "password1" ] && $post_vars [ "password1" ] === $create_user [ "user_pass" ] ) /* A custom Password is being used? */ { if ( ( ( is_multisite ( ) && ( $new__user_id = c_ws_plugin__s2member_registrations:: ms_create_existing_user ( $create_user [ "user_login" ] , $create_user [ "user_email" ] , $create_user [ "user_pass" ] ) ) ) || ( $new__user_id = wp_create_user ( $create_user [ "user_login" ] , $create_user [ "user_pass" ] , $create_user [ "user_email" ] ) ) ) && ! is_wp_error ( $new__user_id ) ) { update_user_option ( $new__user_id , "default_password_nag" , false , true ) ; wp_new_user_notification ( $new__user_id , $create_user [ "user_pass" ] ) ; /**/ $global_response = array ( "response" = 'strongThank you./strong Please a href="' . esc_attr ( wp_login_url ( ) ) . '" rel="nofollow"login/a.' ) ; /**/ if ( $post_vars [ "attr" ] [ "success" ] && substr ( $GLOBALS [ "ws_plugin__s2member_registration_return_url" ] , 0 , 2 ) === substr ( $post_vars [ "attr" ] [ "success" ] , 0 , 2 ) /* In case the registration routine returns something weird. */ && ( $custom_success_url = preg_replace ( "/%%response%%/i" , urlencode ( $global_response [ "response" ] ) , $GLOBALS [ "ws_plugin__s2member_registration_return_url" ] ) ) /* Response message that would have been displayed. */ && ( $custom_success_url = trim ( preg_replace ( "/%%(.+?)%%/i" , "" , $custom_success_url ) ) ) /* Now we clean up any remaining Replacement Codes. We need to do this here; the registration handler expects this. */ && wp_redirect (c_ws_plugin__s2member_pro_paypal_utilities:: paypal_s2p_v_generate ( $custom_success_url ) ) !== "nill" ) /* Also generate an s2p-v variable; used for verification of query string vars. */ exit ( ) ; } else /* Else, an error reponse should be given. */ { $global_response = array ( "response" = 'Oops. A slight problem. Please contact Support for assistance.' , "error" = true ) ; } } else /* Otherwise, they'll need to check their email for the auto-generated Password. */ { if ( ( ( is_multisite ( ) && ( $new__user_id = c_ws_plugin__s2member_registrations:: ms_create_existing_user ( $create_user [ "user_login" ] , $create_user [ "user_email" ] , $create_user [ "user_pass" ] ) ) ) || ( $new__user_id = wp_create_user ( $create_user [ "user_login" ] , $create_user [ "user_pass" ] , $create_user [ "user_email" ] ) ) ) && ! is_wp_error ( $new__user_id ) ) { update_user_option ( $new__user_id , "default_password_nag" , true , true ) ; wp_new_user_notification ( $new__user_id , $create_user [ "user_pass" ] ) ; /**/ $global_response = array ( "response" = 'strongThank you./strong You\'ll receive an email momentarily.' ) ; /**/ if ( $post_vars [ "attr" ] [ "success" ] && substr ( $GLOBALS [ "ws_plugin__s2member_registration_return_url" ] , 0 , 2 ) === substr ( $post_vars [ "attr" ] [ "success" ] , 0 , 2 ) /* In case the registration routine returns something weird. */ && ( $custom_success_url = preg_replace ( "/%%response%%/i" , urlencode ( $global_response [ "response" ] ) , $GLOBALS [ "ws_plugin__s2member_registration_return_url" ] ) ) /* Response message that would have been displayed. */ && ( $custom_success_url = trim ( preg_replace ( "/%%(.+?)%%/i" , "" , $custom_success_url ) ) ) /* Now we clean up any remaining Replacement Codes. We need to do this here; the registration handler expects this. */ && wp_redirect (c_ws_plugin__s2member_pro_paypal_utilities:: paypal_s2p_v_generate ( $custom_success_url ) ) !== "nill" ) /* Also generate an s2p-v variable; used for verification of query string vars. */ exit ( ) ; } else /* Else, an error reponse should be given. */ { $global_response = array ( "response" = 'Oops. A slight problem. Please contact Support for assistance.' , "error" = true ) ; } } } else /* Else, an error. */ { $global_response = $error ; } } } } } } ? [ full view ]s2member-pro\includes\classes\gateways\paypal\paypal-registration-in.inc.php Source Code Documentation Packages ( Overview ) Classes Deprecated Todo Index Source Code(!-- :: s-words --)

Statistics: Posted by System Robot — August 15th, 2011, 3:17 pm


]]>
2011-07-11T17:35:40-05:00 http://www.primothemes.com/forums/viewtopic.php?t=13260&p=27925#p27925 <![CDATA[s2Member v110710 / Source Code: s2member-p...]]>
s2Member v110710
Source Code: s2member-pro\includes\classes\gateways\paypal\paypal-registration-in.inc.php
Docs updated: July 11, 2011, 6:35 pm

Open for public discussion.
(!-- s-words :: --)Source Code Documentation Packages ( Overview ) Classes Deprecated Todo Index Source Code jQuery(window).load(function(){ if(typeof location.hash === 'string' && location.hash.match(/^#/)) jQuery('olli'+location.hash).addClass('hilite'); }); jQuery(window).bind('hashchange', function(){ if(typeof location.hash === 'string' && location.hash.match(/^#/)) jQuery('olli').removeClass('hilite'); jQuery('olli'+location.hash).addClass('hilite'); }); [ full view ]s2member-pro\includes\classes\gateways\paypal\paypal-registration-in.inc.php ?php /** * PayPal® Registration Form ( inner processing routines ). * * Copyright: © 2009-2011 * {@link http://www.websharks-inc.com/ WebSharks, Inc.} * ( coded in the USA ) * * This WordPress® plugin ( s2Member Pro ) is comprised of two parts: * * o (1) Its PHP code is licensed under the GPL license, as is WordPress®. * You should have received a copy of the GNU General Public License, * along with this software. In the main directory, see: /licensing/ * If not, see: {@link http://www.gnu.org/licenses/}. * * o (2) All other parts of ( s2Member Pro ); including, but not limited to: * the CSS code, some JavaScript code, images, and design; * are licensed according to the license purchased. * See: {@link http://www.s2member.com/prices/} * * Unless you have our prior written consent, you must NOT directly or indirectly license, * sub-license, sell, resell, or provide for free; part (2) of the s2Member Pro Module; * or make an offer to do any of these things. All of these things are strictly * prohibited with part (2) of the s2Member Pro Module. * * Your purchase of s2Member Pro includes free lifetime upgrades via s2Member.com * ( i.e. new features, bug fixes, updates, improvements ); along with full access * to our video tutorial library: {@link http://www.s2member.com/videos/} * * @package s2Member\PayPal * @since 1.5 */ if ( realpath ( __FILE__ ) === realpath ( $_SERVER [ "SCRIPT_FILENAME" ] ) ) exit ( "Do not access this file directly." ) ; /**/ if ( ! class_exists ( "c_ws_plugin__s2member_pro_paypal_registration_in" ) ) { /** * PayPal® Registration Form ( inner processing routines ). * * @package s2Member\PayPal * @since 1.5 */ class c_ws_plugin__s2member_pro_paypal_registration_in { /** * Handles processing of Pro Form registrations. * * @package s2Member\PayPal * @since 1.5 * * @attaches-to ``add_action("init");`` * * @return null Or exits script execution after a custom URL redirection. */ public static function paypal_registration ( ) { if ( ! empty ( $_POST [ "s2member_pro_paypal_registration" ] [ "nonce" ] ) && ( $nonce = $_POST [ "s2member_pro_paypal_registration" ] [ "nonce" ] ) && wp_verify_nonce ( $nonce , "s2member-pro-paypal-registration" ) ) { $GLOBALS [ "ws_plugin__s2member_pro_paypal_registration_response" ] = array ( ) ; /* This holds the global response details. */ $global_response = & $GLOBALS [ "ws_plugin__s2member_pro_paypal_registration_response" ] ; /* This is a shorter reference. */ /**/ $post_vars = c_ws_plugin__s2member_utils_strings:: trim_deep ( stripslashes_deep ( $_POST [ "s2member_pro_paypal_registration" ] ) ) ; $post_vars [ "attr" ] = unserialize (c_ws_plugin__s2member_utils_encryption:: decrypt ( $post_vars [ "attr" ] ) ) ; /* And run a Filter. */ $post_vars [ "attr" ] = apply_filters ( "ws_plugin__s2member_pro_paypal_registration_post_attr" , $post_vars [ "attr" ] , get_defined_vars ( ) ) ; /**/ $post_vars [ "recaptcha_challenge_field" ] = ( ! $post_vars [ "recaptcha_challenge_field" ] ) ? trim ( stripslashes ( $_POST [ "recaptcha_challenge_field" ] ) ) : $post_vars [ "recaptcha_challenge_field" ] ; $post_vars [ "recaptcha_response_field" ] = ( ! $post_vars [ "recaptcha_response_field" ] ) ? trim ( stripslashes ( $_POST [ "recaptcha_response_field" ] ) ) : $post_vars [ "recaptcha_response_field" ] ; /**/ $post_vars [ "email" ] = apply_filters ( "user_registration_email" , sanitize_email ( $post_vars [ "email" ] ) , get_defined_vars ( ) ) ; $post_vars [ "username" ] = preg_replace ( "/\s+/" , "" , sanitize_user ( $post_vars [ "username" ] , is_multisite ( ) ) ) ; /**/ if ( !c_ws_plugin__s2member_pro_paypal_responses:: paypal_form_attr_validation_errors ( $post_vars [ "attr" ] ) ) /* Must NOT have any attr errors. */ { if ( ! ( $error = c_ws_plugin__s2member_pro_paypal_responses:: paypal_form_submission_validation_errors ( "registration" , $post_vars ) ) ) { if ( ! ( $create_user = array ( ) ) ) /* Build post fields for registration configuration, and then the creation array. */ { $_POST [ "ws_plugin__s2member_custom_reg_field_user_pass1" ] = $post_vars [ "password1" ] ; /* Fake this for registration configuration. */ $_POST [ "ws_plugin__s2member_custom_reg_field_first_name" ] = $post_vars [ "first_name" ] ; /* Fake this for registration configuration. */ $_POST [ "ws_plugin__s2member_custom_reg_field_last_name" ] = $post_vars [ "last_name" ] ; /* Fake this for registration configuration. */ $_POST [ "ws_plugin__s2member_custom_reg_field_opt_in" ] = $post_vars [ "custom_fields" ] [ "opt_in" ] ; /* Fake this too. */ /**/ if ( $GLOBALS [ "WS_PLUGIN__" ] [ "s2member" ] [ "o" ] [ "custom_reg_fields" ] ) foreach ( json_decode ( $GLOBALS [ "WS_PLUGIN__" ] [ "s2member" ] [ "o" ] [ "custom_reg_fields" ] , true ) as $field ) { $field_var = preg_replace ( "/[^a-z0-9]/i" , "_" , strtolower ( $field [ "id" ] ) ) ; $field_id_class = preg_replace ( "/_/" , "-" , $field_var ) ; /**/ if ( isset ( $post_vars [ "custom_fields" ] [ $field_var ] ) ) $_POST [ "ws_plugin__s2member_custom_reg_field_" . $field_var ] = $post_vars [ "custom_fields" ] [ $field_var ] ; } /**/ $GLOBALS [ "ws_plugin__s2member_registration_vars" ] [ "ws_plugin__s2member_custom_reg_field_s2member_level" ] = $post_vars [ "attr" ] [ "level" ] ; $GLOBALS [ "ws_plugin__s2member_registration_vars" ] [ "ws_plugin__s2member_custom_reg_field_s2member_ccaps" ] = $post_vars [ "attr" ] [ "ccaps" ] ; $GLOBALS [ "ws_plugin__s2member_registration_vars" ] [ "ws_plugin__s2member_custom_reg_field_s2member_auto_eot_time" ] = $post_vars [ "attr" ] [ "tp" ] . " " . $post_vars [ "attr" ] [ "tt" ] ; $_EOT_ = & $GLOBALS [ "ws_plugin__s2member_registration_vars" ] [ "ws_plugin__s2member_custom_reg_field_s2member_auto_eot_time" ] ; /* Quick/shorter reference to this var. */ $_EOT_ = ( $post_vars [ "attr" ] [ "tp" ] && $post_vars [ "attr" ] [ "tt" ] ) ? date ( "Y-m-d H:i:s" , c_ws_plugin__s2member_utils_time:: auto_eot_time ( "" , "" , "" , $_EOT_ ) ) : "" ; $GLOBALS [ "ws_plugin__s2member_registration_vars" ] [ "ws_plugin__s2member_custom_reg_field_s2member_custom" ] = $post_vars [ "attr" ] [ "custom" ] ; unset ( $_EOT_ ) ; /* We can unset this shorter/reference variable now. */ /**/ $GLOBALS [ "ws_plugin__s2member_registration_return_url" ] = $post_vars [ "attr" ] [ "success" ] ; /* Custom success return. */ /**/ $create_user [ "user_login" ] = $post_vars [ "username" ] ; /* Copy this into a separate array for `wp_create_user()`. */ $create_user [ "user_pass" ] = wp_generate_password ( ) ; /* Which may fire `c_ws_plugin__s2member_registrations::generate_password()`. */ $create_user [ "user_email" ] = $post_vars [ "email" ] ; /* Copy this into a separate array for `wp_create_user()`. */ } /**/ if ( $post_vars [ "password1" ] && $post_vars [ "password1" ] === $create_user [ "user_pass" ] ) /* A custom Password is being used? */ { if ( ( is_multisite ( ) && ( $new__user_id = c_ws_plugin__s2member_registrations:: ms_create_existing_user ( $create_user [ "user_login" ] , $create_user [ "user_email" ] , $create_user [ "user_pass" ] ) ) ) || ( $new__user_id = wp_create_user ( $create_user [ "user_login" ] , $create_user [ "user_pass" ] , $create_user [ "user_email" ] ) ) ) { update_user_option ( $new__user_id , "default_password_nag" , false , true ) ; wp_new_user_notification ( $new__user_id , $create_user [ "user_pass" ] ) ; /**/ $global_response = array ( "response" = 'strongThank you./strong Please a href="' . esc_attr ( wp_login_url ( ) ) . '" rel="nofollow"login/a.' ) ; /**/ if ( $post_vars [ "attr" ] [ "success" ] && substr ( $GLOBALS [ "ws_plugin__s2member_registration_return_url" ] , 0 , 2 ) === substr ( $post_vars [ "attr" ] [ "success" ] , 0 , 2 ) /* In case the registration routine returns something weird. */ && ( $custom_success_url = preg_replace ( "/%%response%%/i" , urlencode ( $global_response [ "response" ] ) , $GLOBALS [ "ws_plugin__s2member_registration_return_url" ] ) ) /* Response message that would have been displayed. */ && ( $custom_success_url = trim ( preg_replace ( "/%%(.+?)%%/i" , "" , $custom_success_url ) ) ) /* Now we clean up any remaining Replacement Codes. We need to do this here; the registration handler expects this. */ && wp_redirect (c_ws_plugin__s2member_pro_paypal_utilities:: paypal_s2p_v_generate ( $custom_success_url ) ) !== "nill" ) /* Also generate an s2p-v variable; used for verification of query string vars. */ exit ( ) ; } else /* Else, an error reponse should be given. */ { $global_response = array ( "response" = 'Oops. A slight problem. Please contact Support for assistance.' , "error" = true ) ; } } else /* Otherwise, they'll need to check their email for the auto-generated Password. */ { if ( ( is_multisite ( ) && ( $new__user_id = c_ws_plugin__s2member_registrations:: ms_create_existing_user ( $create_user [ "user_login" ] , $create_user [ "user_email" ] , $create_user [ "user_pass" ] ) ) ) || ( $new__user_id = wp_create_user ( $create_user [ "user_login" ] , $create_user [ "user_pass" ] , $create_user [ "user_email" ] ) ) ) { update_user_option ( $new__user_id , "default_password_nag" , true , true ) ; wp_new_user_notification ( $new__user_id , $create_user [ "user_pass" ] ) ; /**/ $global_response = array ( "response" = 'strongThank you./strong You\'ll receive an email momentarily.' ) ; /**/ if ( $post_vars [ "attr" ] [ "success" ] && substr ( $GLOBALS [ "ws_plugin__s2member_registration_return_url" ] , 0 , 2 ) === substr ( $post_vars [ "attr" ] [ "success" ] , 0 , 2 ) /* In case the registration routine returns something weird. */ && ( $custom_success_url = preg_replace ( "/%%response%%/i" , urlencode ( $global_response [ "response" ] ) , $GLOBALS [ "ws_plugin__s2member_registration_return_url" ] ) ) /* Response message that would have been displayed. */ && ( $custom_success_url = trim ( preg_replace ( "/%%(.+?)%%/i" , "" , $custom_success_url ) ) ) /* Now we clean up any remaining Replacement Codes. We need to do this here; the registration handler expects this. */ && wp_redirect (c_ws_plugin__s2member_pro_paypal_utilities:: paypal_s2p_v_generate ( $custom_success_url ) ) !== "nill" ) /* Also generate an s2p-v variable; used for verification of query string vars. */ exit ( ) ; } else /* Else, an error reponse should be given. */ { $global_response = array ( "response" = 'Oops. A slight problem. Please contact Support for assistance.' , "error" = true ) ; } } } else /* Else, an error. */ { $global_response = $error ; } } } } } } ? [ full view ]s2member-pro\includes\classes\gateways\paypal\paypal-registration-in.inc.php Source Code Documentation Packages ( Overview ) Classes Deprecated Todo Index Source Code(!-- :: s-words --)

Statistics: Posted by System Robot — July 11th, 2011, 5:35 pm


]]>
2011-07-09T06:15:56-05:00 http://www.primothemes.com/forums/viewtopic.php?t=13260&p=25555#p25555 <![CDATA[s2Member v111220 / Source Code: s2member-p...]]>
s2Member v111220
Source Code: s2member-pro\includes\classes\gateways\paypal\paypal-registration-in.inc.php
Docs updated: December 20, 2011, 9:52 am

Open for public discussion.
(!-- s-words :: --)n/a(!-- :: s-words --)

Statistics: Posted by System Robot — July 9th, 2011, 6:15 am


]]>