- This topic has 13 replies, 3 voices, and was last updated 4 months, 2 weeks ago by
David.
-
AuthorPosts
-
September 2, 2020 at 2:54 am #1427499
Jeff
This is not a topic where any responsibility lies with GeneratePress. It’s more a Woocommerce issue and I’m throwing it out here because I simply can’t figure it out and numerous searches online have not amounted to anything. I don’t mind if I get put on the back burner on this one. I hope you find my issue somewhat interesting and something that will be helpful to others – assuming there’s a solution.
My website is for a single product with several customizations including color and engraving information. For that reason, I added the Flexible Products Fields plugin which works great for my needs.
However, I feel that I’ve ended up with one step too many for the customer and I’d like to simplify things for them. I have a “Shop” page which then lists my one product and asks them to press a button to customize the one item. IOW, my “Shop” page is nothing more than a request for the customer to hit another button in order to customize the single product that I offer (which they must do).
I could modify the menu such that selecting the Shop page takes them directly to the modification page but there’s a problem. If the cart is cleared there’s a button they can select which takes them back to the “real” Shop page – not the modification page. That would create confusion.
What I would like to do is this: Hitting the Shop button brings the customer directly to the customization page. Not two pages with unnecessary steps – just one. And from there, after the customizations, they go to the Cart page and from there they go to the Check-Out page. And no buttons appear that lead them to the redundant real Shop page where all they do there is hit another button.
I can’t figure out how to get rid of the unnecessary Shop page. I would like the Shop page to become the customization page. I’m aware of the $80 Woocommerce one page check-out extension but in spite of it’s very high price their documentation states it is not compatible with the Flexible Products Field plugin.
Any thoughts would be appreciated.
September 2, 2020 at 6:39 am #1427744David
StaffCustomer SupportHi there,
add this PHP Snippet to your site:
function wc_empty_cart_redirect_url() { return 'http://yourdomain.com/your-page/'; } add_filter( 'woocommerce_return_to_shop_redirect', 'wc_empty_cart_redirect_url' );
It will redirect the Shop link to the URL you add above.
https://docs.generatepress.com/article/adding-php/
Documentation: http://docs.generatepress.com/
Adding CSS: http://docs.generatepress.com/article/adding-css/September 2, 2020 at 8:19 pm #1428614Jeff
Hi David,
Thank you for the PHP but I can’t get it to work. I’ve tried some variations but every time the “Return to Shop” button in the empty cart is pressed it goes to the true Shop page rather than the customization page.
I’ve altered the menu so that Shop goes to the customization page and it’s in that state now. Can you take a look and see if I’m missing something? Thanks.
Jeff
September 3, 2020 at 1:24 am #1428855David
StaffCustomer SupportHow was the code added to the site ?
Documentation: http://docs.generatepress.com/
Adding CSS: http://docs.generatepress.com/article/adding-css/September 3, 2020 at 2:07 pm #1429913Jeff
I did it here: Customize > Additional CSS
My code there ends like this:
}
#add_payment_method table.cart img,
.woocommerce-cart table.cart img,
.woocommerce-checkout table.cart img {
width: 200px !important;
}function wc_empty_cart_redirect_url() {
return ‘my url’;
}
add_filter ( ‘woocommerce_return_to_shop_redirect’, ‘wc_empty_cart_redirect_url’ );
/* End GeneratePress Site CSS */September 3, 2020 at 2:17 pm #1429931Jeff
Disregard this reply.
September 3, 2020 at 3:02 pm #1429986Leo
StaffCustomer SupportAre you all good on this?
David’s function here is not CSS:
https://generatepress.com/forums/topic/simplifying-a-single-product-woocommerce-website/#post-1427744It’s PHP and should be added using one of these methods:
Adding PHP: https://docs.generatepress.com/article/adding-php/Documentation: http://docs.generatepress.com/
Adding CSS: http://docs.generatepress.com/article/adding-css/September 3, 2020 at 3:15 pm #1429996Jeff
Aha. It works. Thanks for the link to Code Snippets. Learned a lot today.
September 4, 2020 at 1:25 am #1430349David
StaffCustomer SupportGlad we could be of help
Documentation: http://docs.generatepress.com/
Adding CSS: http://docs.generatepress.com/article/adding-css/September 4, 2020 at 3:06 am #1430463Jeff
David, I’ve closed this as solved. Thanks very much for your help. May I ask, what part of Vancouver Island are you located? I’m very familiar. Spent many summers on Nootka Island. But been all over.
September 4, 2020 at 3:52 am #1430502David
StaffCustomer SupportYou’re welcome.
Tom is from the Island – i am not sure where exactly – he likes to move around π
I actually live and work in the United Kingdom.Documentation: http://docs.generatepress.com/
Adding CSS: http://docs.generatepress.com/article/adding-css/September 4, 2020 at 3:55 am #1430506Jeff
Lol. Got it! Thanks for getting back.
September 4, 2020 at 3:56 am #1430507Jeff
And now I know why you’re on the “late” shift!
September 4, 2020 at 4:13 am #1430519David
StaffCustomer SupportSomeone has too π Lucky for GP i don’t sleep much so we still get a lot of team time with the 7-8hr time difference.
Documentation: http://docs.generatepress.com/
Adding CSS: http://docs.generatepress.com/article/adding-css/ -
AuthorPosts
- You must be logged in to reply to this topic.