WordPress.org

Ready to get started?Download WordPress

Forums

WooCommerce Extra Checkout Fields for Brazil
[resolved] Trying to put fields on myaccount/form-login.php (14 posts)

  1. adrianovarlotta
    Member
    Posted 6 months ago #

    Hello,

    Im trying to put Name and Last Name on form-login.php, so the user need put name and last name to register, not only email and password...

    I tried this code but does not work.

    <div class="form-row form-row-first">
    <label for="billing_first_name"> <strong><?php _e('Nome', 'woocommerce'); ?><span class="required">*</span></strong></label>
    <input type="text" class="input-text" name="billing_first_name" id="billing_first_name" size="30" value="<?php if (isset($_POST['billing_first_name'])) echo esc_attr($_POST['billing_first_name']); ?>" />
    </div>
    <div class="form-row form-row-last">
    <label for="billing_last_name"> <strong><?php _e('Sobrenome', 'woocommerce'); ?><span class="required">*</span></strong></label>
    <input type="text" class="input-text" name="billing_last_name" id="billing_last_name" size="30" value="<?php if (isset($_POST['billing_last_name'])) echo esc_attr($_POST['billing_last_name']); ?>" />
    </div>

    can you help me?

    Thanks so much, your plugins are awsome

    http://wordpress.org/plugins/woocommerce-extra-checkout-fields-for-brazil/

  2. Claudio Sanches
    Member
    Plugin Author

    Posted 6 months ago #

    This is beyond the scope of the plugin.
    Proposal to change the plugin is only at checkout.

  3. adrianovarlotta
    Member
    Posted 6 months ago #

    But i can put the name and last name(billing) on form-login.php ?
    I thought it was right to put ... :/

    I ll try more, thanks

  4. Claudio Sanches
    Member
    Plugin Author

    Posted 6 months ago #

    Yes it is possible.
    Are all user profile fields.

  5. adrianovarlotta
    Member
    Posted 6 months ago #

    I'm trying without success,

    sorry the question outside the scope of the plugin, but you have to help me with this?

    What did is wrong with this code I'm putting? Why is not working?

    Thanks so much

  6. adrianovarlotta
    Member
    Posted 6 months ago #

    I tried this too, but does not work at all :(

    <div class="form-row form-row-first">
    <label for="billing_first_name"><?php _e('First Name', 'woocommerce-extra-checkout-fields-for-brasil'); ?><span class="required">*</span></strong></label>
    <input type="text" class="input-text" name="billing_first_name" id="billing_first_name" size="30" value="<?php if (isset($_POST['billing_first_name'])) echo esc_attr($_POST['billing_first_name']); ?>" />
    </div>
    <div class="form-row form-row-last">
    <label for="billing_last_name"><?php _e('Last Name', 'woocommerce-extra-checkout-fields-for-brasil'); ?><span class="required">*</span></strong></label>
    <input type="text" class="input-text" name="billing_last_name" id="billing_last_name" size="30" value="<?php if (isset($_POST['billing_last_name'])) echo esc_attr($_POST['billing_last_name']); ?>" />
    </div>
  7. Claudio Sanches
    Member
    Plugin Author

    Posted 6 months ago #

    Lucky for you I'm good today xD

    Use this: https://gist.github.com/claudiosmweb/8337185

    I will appreciate any contribution back!

  8. adrianovarlotta
    Member
    Posted 6 months ago #

    Thanks you so much Claudio, you contribuite so much for this community.

    How can i contribute to you ? Im glad to pay a beer for you ;)

    I put this on functions.php but didnt work, i need put something on form-login.php?

    Thanks so much

    site link: http://migre.me/hmvcO

  9. Claudio Sanches
    Member
    Plugin Author

    Posted 6 months ago #

    Sorry.
    Now I saw that this only works on WooCommerce 2.1 up.
    For WooCommerce 2.0.20 is different.

  10. adrianovarlotta
    Member
    Posted 6 months ago #

    Hmmmm, but i cant update to 2.1, its not available.
    If i can only update i can do that ....

    And how can i pay a beer for you bro?

    Thanks

  11. Claudio Sanches
    Member
    Plugin Author

    Posted 6 months ago #

    I'm just testing everything on my machine with the latest version coming out later this month.
    If I have time later, I install the WooCommerce 2.0.20 and see what needs to be done.

  12. Claudio Sanches
    Member
    Plugin Author

    Posted 6 months ago #

  13. adrianovarlotta
    Member
    Posted 6 months ago #

    Works well buddy, thanks so much!

    pvt me with bank account, you helped me, i wanna return this favor!

    Tks so much!

  14. Claudio Sanches
    Member
    Plugin Author

    Posted 6 months ago #

Reply

You must log in to post.

About this Plugin

About this Topic

Tags

No tags yet.