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.

Authnet Pro Form Saving Address Fields

Home Forums Community Forum Authnet Pro Form Saving Address Fields

This topic contains 3 replies, has 2 voices. Last updated by  Cristián Lávaque 4 years, 7 months ago.

Topic Author Topic
Posted: Wednesday May 23rd, 2012 at 2:52 am #14289

Hi,

Is there a way to save Address information as a custom field? Also, I can’t find a way to modify custom field’s html output. I do not want to modify s2member pro’s source code, I prefer using hooks and filters coz last time my mod was overwritten when I updated to the new version.

$custom_fields = '<div id="s2member-pro-authnet-registration-form-custom-fields-section" class="s2member-pro-authnet-form-section s2member-pro-authnet-registration-form-section s2member-pro-authnet-form-custom-fields-section s2member-pro-authnet-registration-form-custom-fields-section">' . "\n";
/**/
$custom_fields .= '<div id="s2member-pro-authnet-registration-form-custom-fields-section-title" class="s2member-pro-authnet-form-section-title s2member-pro-authnet-registration-form-section-title s2member-pro-authnet-form-custom-fields-section-title s2member-pro-authnet-registration-form-custom-fields-section-title">' . "\n";
$custom_fields .= _x ("Additional Info", "s2member-front", "s2member") . "\n";
$custom_fields .= '</div>' . "\n";

I need to save Address, Zipcode, State, City and Country as a custom field. So that the user / member can modify them using the edit profile page.

List Of Topic Replies

Viewing 3 replies - 1 through 3 (of 3 total)
Author Replies
Author Replies
Posted: Wednesday May 23rd, 2012 at 3:37 am #14296

Hi Randy.

You can create custom profile fields for those. [hilite path]Dashboard -› s2Member® -› General Options -› Registration/Profile Fields[/hilite]

The payment section of the pro-form is not stored by s2Member, it’s just forwarded to the gateway.

About the hack having been overwritten on update, one thing you can do is put the customized copy of the file in the mu-plugins. The s2Member classes first check if the class exists, so yours will be there first and it won’t be changed by the update. Just make sure you apply to your modified file, any important changes that come with the new releases.

I hope that helps. :)

Posted: Wednesday May 23rd, 2012 at 8:28 pm #14369

Great Support! I will try it out.

**EDIT*: How will I name the class? and should I place it to the same folder and file structure inside mu-plugins?.

Works Great!

Posted: Thursday May 24th, 2012 at 7:03 am #14459

Thanks for the kudos. :)

Just copy the file into the mu-plugins, no directory structure. The file can be named the same as the original. Leave the class’ name as it is or s2 won’t know about it. There won’t be a namespace conflict because s2 checks if it exists before defining it.

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

This topic is closed to new replies. Topics with no replies for 2 weeks are closed automatically.

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.