Title: Append language code to registration URL
Last modified: August 21, 2016

---

# Append language code to registration URL

 *  [pascal.riendeau](https://wordpress.org/support/users/pascalriendeau/)
 * (@pascalriendeau)
 * [12 years, 1 month ago](https://wordpress.org/support/topic/append-language-code-to-registration-url/)
 * We have s2members Pro, but we’re using Paypal buttons (we only have Paypal standard).
 * Our site is multilingual (we us WPML). We’ve created separate pages for paid 
   membership in each language, and used the “success” attribute in the Paypal buttons
   to redirect the new members to a custom page in their language on payment success.
   From there, they are invited to go to the registration form, and we’ve appended
   the proper language to the URL, like this:
 * [http://www.mysite.com](http://www.mysite.com)\wp-login.php?lang=fr&action=register
 * However, the registration button on this form submits the form to itself without
   our added language variable to the URL, so after registration the member lands
   on the default language login form. It also reverts back to the default language
   if the member forgets to fill a required field.
 * Is there any way at all, be it hooks or whatnot, to alter the form’s submit button
   so that it keeps the language variable?
 * Thanks!
 * [https://wordpress.org/plugins/s2member/](https://wordpress.org/plugins/s2member/)

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

 *  [Cristián Lávaque](https://wordpress.org/support/users/anguz/)
 * (@anguz)
 * [12 years ago](https://wordpress.org/support/topic/append-language-code-to-registration-url/#post-5042229)
 * This seems to be a WordPress or WPML question rather than s2Member, right? I’m
   not familiar with WPML, so can’t help much there.
 * > we’ve appended the proper language to the URL, like this:
    > [http://www.mysite.com](http://www.mysite.com)\
   wp-login.php?lang=fr&action=register
 * That link seems wrong with the back-slash, looks like it should be:
 * [http://www.mysite.com/wp-login.php?lang=fr&action=register](http://www.mysite.com/wp-login.php?lang=fr&action=register)
 *  Thread Starter [pascal.riendeau](https://wordpress.org/support/users/pascalriendeau/)
 * (@pascalriendeau)
 * [12 years ago](https://wordpress.org/support/topic/append-language-code-to-registration-url/#post-5042233)
 * That was a typo, sorry 🙂
 * So I get it that the code that generates the URL for the registration button 
   is untouched by s2Member, it comes straight from WP? I’ll look on that end and
   post back!
 *  [Cristián Lávaque](https://wordpress.org/support/users/anguz/)
 * (@anguz)
 * [12 years ago](https://wordpress.org/support/topic/append-language-code-to-registration-url/#post-5042244)
 * Where is that registration link that doesn’t include the language variable? Could
   you show me a screenshot or the page where it is?

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

The topic ‘Append language code to registration URL’ is closed to new replies.

 * ![](https://ps.w.org/s2member/assets/icon-256x256.png?rev=980067)
 * [s2Member – Excellent for All Kinds of Memberships, Content Restriction Paywalls & Member Access Subscriptions](https://wordpress.org/plugins/s2member/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/s2member/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/s2member/)
 * [Active Topics](https://wordpress.org/support/plugin/s2member/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/s2member/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/s2member/reviews/)

## Tags

 * [Registration](https://wordpress.org/support/topic-tag/registration/)
 * [url](https://wordpress.org/support/topic-tag/url/)

 * 3 replies
 * 2 participants
 * Last reply from: [Cristián Lávaque](https://wordpress.org/support/users/anguz/)
 * Last activity: [12 years ago](https://wordpress.org/support/topic/append-language-code-to-registration-url/#post-5042244)
 * Status: not a support question