Astoundify/wc-simple-registration

Allow WooCommerce Simple Registration to be output on the register shortcode.

Closed this issue · 10 comments

It's a limitation of the actual Social Login plugin, not this. You can only choose from 3 pages:

array(
                'name'     => __( 'Display Social Login buttons on:', 'woocommerce-social-login' ),
                'desc_tip' => __( 'Control where Social Login buttons are displayed.', 'woocommerce-social-login' ),
                'id'       => 'wc_social_login_display',
                'type'     => 'multiselect',
                'class'    => 'wc-enhanced-select',
                'options' => array(
                    'checkout'        => __( 'Checkout', 'woocommerce-social-login' ),
                    'my_account'      => __( 'My Account', 'woocommerce-social-login' ),
                    'checkout_notice' => __( 'Checkout Notice', 'woocommerce-social-login' ),
                ),
                'default'  => array(
                    'checkout',
                    'my_account',
                ),

If we hook into the widget, woocommerce_social_login_buttons() it would output them @spencerfinnell

There are very specific checks before outputting it:

/**
     * Render social login buttons on frontend
     *
     * @since 1.0
     */
    public function render_social_login_buttons() {
        if ( ! is_checkout() && ! is_account_page() ) {
            return;
        }
        if ( is_checkout() && ! $this->is_displayed_on( 'checkout' ) ) {
            return;
        }
        if ( is_account_page() && ! $this->is_displayed_on( 'my_account' ) ) {
            return;
        }
        $return_url = is_checkout() ? WC()->cart->get_checkout_url() : wc_get_page_permalink( 'myaccount' );
        woocommerce_social_login_buttons( $return_url );
    }

It could be called directly but there has to be a reason they set it up like this.

There is a built in shortcode though:

[woocommerce_social_login_buttons return_url="https://mystore.com/my-account"]

So maybe it doesn't matter. This plugin would need to introduce a new option to show/hide it though.

So just add it to the page? then we need to style it a bit?

screen shot 2016-09-16 at 1 24 32 pm

Yes but could also be integrated in the plugin to output automatically as well.

I don't understand this task. This plugin output is using the register shortcode [woocommerce_simple_registration].

Allow WooCommerce Simple Registration to be output on the register shortcode.

Do you want to integrate social login? Is it using this plugin?
https://woocommerce.com/products/woocommerce-social-login/

Do you have the latest version available?

Do you want to integrate social login? Is it using this plugin?

Yes.

Do you have the latest version available?

Yes, I sent you a copy.

@turtlepod