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: Jesus Altuve

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


Topics I'm Subscribed To

Viewing topic 1 (of 1 total)
Topic Count Last Reply
Translation of Custom Registration Fields

By:  Cord in: Translations

voices: 5
replies: 9

3 years, 9 months ago  Natasha Bernal

Viewing topic 1 (of 1 total)

My Latest Replies (From Various Topics)

Viewing 1 replies (of 1 total)
Author Replies
Author Replies
Posted: Saturday Oct 27th, 2012 at 5:45 pm #29938
Jesus Altuve
Username: jaltuve

Hi!

I found your question looking for an answer myself, so I decided to figure it out. You simply need to add this to your theme functions.php:

function translate_custom_field($rec) {
        $label = $rec['field']['label'];
        $rec['field']['label'] = _x($label, "s2member-front", "s2member");
        return $rec;
}
add_action("ws_plugin__s2member_during_custom_registration_fields_before_custom_fields", "translate_custom_field");
add_action("ws_plugin__s2member_during_profile_during_fields_during_custom_fields_before", "translate_custom_field");

Obviously, make sure you DO have the entry in your .po file. The above fix assumes you are using
getext po/mo files and that the file is properly named (s2member-xx_YY.mo) and is in the plugins root directory and NOT inside the s2member plugin directory.

xx_YY is the locale, as in es_ES or en_US

Viewing 1 replies (of 1 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.