I found what was my problem is priority. Some other plugin was using a 1000 priority, so I had to boost my priority when declaring the hook. That way:
add_filter( 'woocommerce_login_redirect', 'share_login_redirect', 1100, 2 );
instead of
add_filter( 'woocommerce_login_redirect', 'share_login_redirect', 10, 2 );
Related Posts:
- Remember page before login page, redirect to that page after login
- Redirect user after login through woocommerce login page to page with his/her username?
- How to check if is in cart page? [closed]
- WooCommerce lost password reset flow not working with SendGrid (redirect loop)
- Custom Redirect after registration in WooCommerce
- Import products to WooCommerce by CSV page won’t open [closed]
- Woocommerce login not working on the first try
- Redirect customer to login page (with other signup plugin) if user not logged in when proceeding to checkout
- Woocommerce – Want to block a user agent from accessing specific product pages
- How to – proper WordPress 301 redirects?
- WooCommerce – Redirect to a product after login
- Woocommerce, prevent login after registration and redirect to custom URL
- Woocommerce Login Redirect to old domain
- Redirect no product url’s to static url
- WooCommerce Registration redirect based on page ID
- wordpress/woocommerce login url not redirecting correctly
- WooCommerce get_author_posts_url() – Author URL redirecting to shop base
- Anonymous users can not access website
- Is it ok to 301 redirect product-category pages to custom pages?
- WooCommerce and ACF: How to Redirect Upon Add to Cart – Partially Working Example
- wordpress site auto redirect to another site when I enable woocommerce
- How to use woo commerce login to authenticate code php pages?
- mydomain.com/wp-login redirects to wordpress.com/wp-login
- Woocommerce login to specific page or referrer
- WooCommerce shop, my account, cart every page redirect to home page [closed]
- How to change redirect code? [duplicate]
- Login page so wide [closed]
- Remove login fields from /customer-account page [closed]
- Account Status/Login on Main Menu with Avatar Pictures
- Getting the gallery images from products in woocommerce?
- add_filter to modify woocommerce_cart_item_name hyperlink
- How to get rid of the hover zoom in WooCommerce single products
- How do I display certain products via their category on a section of a page using PHP?
- Using `auth_redirect` : keeps asking me to login even when I’m logged in
- Programmatically change Payment Methods WooCommerce
- pre_get_posts with WooCommerce Shortcode Query
- Use WooCommerce function in other WordPress plugin
- Add product description (content) to WooCommerce customer processing order email
- Firing a function AFTER redirect
- Woocommerce Product Image and Thumbnails custom function
- Create WooCommerce new order with specific ID
- woocommerce change order statuses count for specific role
- Auto Redirect after login
- is_user_logged_in() always returns false for woocommerce_login_redirect
- WordPress ‘on behalf of’ email
- Display description on cart page
- Which hook should I use to capture $_POST(‘password’) via profile update and password reset
- display first sale product in shop
- Keep getting Notice: Trying to get property of non-object in …\wp-includes\post.php on line 4153 when generating woocommerce coupon
- How to subscribe free subscription on user registration in woocommerce subscription plugin?
- WooCommerce Product URL re-writing
- Woocommerce cart page – Add “Free” to the shipping label when shipping is 0
- Change product in cart when billing country is changed
- Calculate tax on sales price excluding discount [closed]
- Additional fields on Woocommerce’s rating system
- Woocommerce product image [closed]
- WordPress directing to Posts page (edit.php) instead of saving post
- Question on WooCommerce Syntax
- woocommerce_new_product action doesn’t fire
- Change The Woocommerce Product Categories Dropdown Widget Placeholder Text
- minimum order item for certain products exempting 2 other products (in bulk)
- Is it possible to checkout with 2 different shipping options on a single order? [closed]
- Sender e-mail address, for new order email to customer, is suddenly wrong [closed]
- Pass class to Woocommerce shortcode [relative_products] [closed]
- Undo WooCommerce CSV import
- A Woo commerce extension has deleted my old theme.How to undo? [closed]
- Woocommerce Advanced Shipping (WAS) condition is not being called when selecting “Ship to different address” [closed]
- Strip string from $_product->get_title() to get a cleaner mini-cart
- All URLs Redirect to Main Page
- Product page attributes dropdown show price
- Smart Design for Blog + Woocommerce + LearnDash + Forum/Bodyboss
- Ajax add to cart not updating Elementor mini cart totals
- I want to store user password (during registration) in an other table in the same database in addition to the user table MD5 Hash
- How to edit the default woo-commerce Store page meta title tag “Products”
- Custom Email via Hook only for completed order
- Need help with woocommerce roles
- Change WooCommerce product and variation prices programatically without affecting performance
- Help to locate a woocommerce hook method
- woocommerce_product_quick_edit_save hook not fired
- Changing Title Tag on Shop Archive Page (current solution reverting to Title of First Product in Loop)
- Why does wc_get_products($arg) return no products when $arg = ‘average_rating’ => 5.0
- Query product’s image path by category WooCommerce database?
- Delete comma in front of currency woocommerce
- How update price for variable product
- currentURL is not defined
- Add button linked to single product page on order detail page
- WordPress not loggin user and redirecting after custom registration
- syntax error – woocommerce
- How to on/off woocommerce filter with redux framework [closed]
- Cross-sells on WooCommerce product page
- Admin Order adding an extra product on add_line_item
- Get WP All Export row ID
- WooCommerce – missing products when viewed by tag
- Allow authors to use their own PayPal account and payment process automation [closed]
- Can a woocommerce hook alter the UI of a website?
- cannot create product attribute (taxonomy) and add terms on the same execution
- Redirecting logged in users to custom URL
- wp-login – unable to redirect user to a custom login url
- How do I get my image for my product to not be blurry
- Product Variation Auto Select when only one 1 and mark the option [closed]