Home Forums WoodMart support forum Show a seperate header on order confirmation page

Show a seperate header on order confirmation page

Viewing 12 posts - 1 through 12 (of 12 total)
  • Author
    Posts
  • #538093

    refa
    Participant

    Hi,

    I am using Woodmart theme with multiple headers for the homepage, cart page, and checkout page. I want to show a different header only for the order confirmation page/thank you page after the order is confirmed (Thank you, your order has been received page) how to do that? Please check the screenshot for your reference.

    If a user manually inputs the URL with “siteurl/checkout/order-received/” he can get the order received page, but it shouldn’t allow them to access that page.

    Also, is there any option to change the design of the order confirmation page?

    If the order/payment failed which page customer will be redirected to? How do I customize that page? Please assist.

    Thank you,

    • This topic was modified 11 months, 2 weeks ago by refa.
    • This topic was modified 11 months, 2 weeks ago by refa. Reason: I attached the screenshots on public area, I should've added it on private content
    Attachments:
    You must be logged in to view attached files.
    #538132

    Artem Temos
    Keymaster

    Hello,

    WooCommerce thank you page is actually not a separate page but checkout. It means that all settings for checkout page will be the same for Thank you page. It is the same page but with different content.

    Kind Regards

    #538306

    refa
    Participant

    But what if I want to show a separate header based on the URL? The URL is different for both the checkout and order status page, so I want to show a different header based on the URL/checkout/ should show separately, and /checkout/status should show a different header. How can I achieve this?

    #538371

    Artem Temos
    Keymaster

    Try to add the following PHP code snippet to the child theme functions.php file to set a custom header for the thank you page

    add_filter('woodmart_get_current_header_id', function ( $id ) {
        if ( is_checkout() && ! empty( is_wc_endpoint_url( 'order-received' ) ) ) {
           return 'header_225478'; // Specify the id of the desired header.
        }
    
        return $id;
    });

    You can get the header ID as per screenshot

    • This reply was modified 11 months, 2 weeks ago by Artem Temos.
    #538478

    refa
    Participant

    I tried but still the same. Also is it possible to use Elementor header?

    #538487

    Artem Temos
    Keymaster

    This code is for our header builder only. If you are using Elementor PRO, then you need to consult with plugin’s developers for help on this matter.

    #538496

    refa
    Participant

    Thank you for the clarification. I tried it with woodmart default header only.

    #538504

    Artem Temos
    Keymaster

    You are welcome. Feel free to contact us if you have any further questions.

    #538507

    refa
    Participant

    I tried it with default woodmart header only but the code is not working, on ‘order-status’ page the new header is not showing.

    #538509

    Artem Temos
    Keymaster

    Did you try to disable Elementor’s header for checkout?

    #538514

    refa
    Participant

    Working, thank you. I want to show an elementor pop-up when I click on the header logo. Will it work with the default theme header?

    #538530

    Artem Temos
    Keymaster

    There is no such functionality by default. It might be possible with additional code customization but we don’t have a solution for this.

Viewing 12 posts - 1 through 12 (of 12 total)