• Hi
    I made a mistake before (H don’t remember actually what I did!) and since then template pages got a -2 in the end of each one (like checkout-2). Now when a customer apply a successful buy when it gets back to the website there will be a 404 page so the customer can not see the successful buy message. Is there anyway to correct this error?

    https://wordpress.org/plugins/woocommerce/

Viewing 15 replies - 1 through 15 (of 19 total)
  • You probably clicked the button to reinstall the WooCommerce pages when they were already installed.

    – make sure the pages bin is empty
    – visit each WC template page and edit the permalink to remove the -2. You’ll find the permalink just under the title.
    – go to Admin page > WooCommerce > Settings > Products tab > Display, and make sure your shop page is selected in the shop page drop down
    – go to Admin page > WooCommerce > Settings > Checkout and make sure your cart and checkout pages are correctly set in their respective drop downs
    – just below these drop downs, check that the order received field is not blank. If your site is English, the field would say “order-received”
    – go to Admin page > Settings > permalinks and click save changes
    Should be OK…

    Thread Starter tahoom

    (@tahoom)

    Thanks lorro
    What is page bin? I did all of others you said but the problem didn’t resolve.

    Admin page > Pages > All Pages: at top just under “Pages Add new” it will tell you how many pages of each type you have: All, Published, Private, Bin. If your old WooCommerce pages are in the bin, you cannot reuse the slug, hence the need to permanently delete these from the bin.

    Thread Starter tahoom

    (@tahoom)

    Thanks again
    I’m using wordpress in another language. There isn’t any pages in bin.
    Woocommerce template pages are:
    – shop
    – cart
    – wishlist
    – my-account
    – checkout
    Is there any other template pages? When someone pays the money in the BANK page what page usually the customer gets back to my website? Now I see the 404 page and don’t know the page.

    After money is paid, the customer is directed to the checkout page but with the endpoint set in the order received field on the checkout settings tab, so usually:
    /checkout/order-received/
    (though may vary depending on your language and permalink settings)
    You may see this referred to as the thank-you page.

    Have a look in the database. Login in to cPanel or your equivalent, start phpMySql, choose your WordPress database, and search the post_meta table for _wp_old_slug values. Delete any WC ones. Sometimes these are not cleaned up properly and can cause unwanted redirects. Google “_wp_old_slug” for more info.

    Thread Starter tahoom

    (@tahoom)

    /checkout/order-received/
    the “order-received” must be a page? or this is just a phrase? I have this phrase (translated in my language) under the order received, I must do anything else for that to work?
    (I didn’t do anything for old slugs for now)

    The checkout/order-received/ page is the same page as the checkout/ page, it just behaves differently because of the end point.

    Thread Starter tahoom

    (@tahoom)

    sorry I’m confused, so I must have a page with address checkout/order-received/ ? and it’s content must be same as checkout page? and then the order received page will be shown?

    Nope, the checkout page and the checkout/order-received/ urls lead to the same page. “checkout” is the url, and “order-received” is the endpoint (even though it looks like part of the url).

    The shortcode on the checkout page can tell if there is an endpoint or not. If it finds the endpoint “order-receieved”, it switches its behaviour accordingly.

    Thread Starter tahoom

    (@tahoom)

    The shortcode for “order-received” is available in woocommerce checkout template. Is it possible the problem occurs because I use a translated phrase for “order-received” and it’s not available in woocommerce?(I searched for the translated phrase by string-locator plugin and didn’t find that phrase)

    I don’t think so. The “order-received” in the template is the name of the variable. The value of the variable is set at Admin page > WooCommerce > Settings > Checkout tab, order-received field. On my dev site, I was able to set the order-received field to éåæ and it worked fine, so a translated phrase should work fine too.

    This is not a translated phrase so you won’t find it in your string-locator plugin. You must translate the phrase yourself and put your translated text in the order-received field in settings.

    Does the checkout page work OK? If that’s not working, then order-received won’t.

    If the checkout page works OK, and order-received doesn’t, try clearing any cached pages and deactivating any cache plugin. Also try reseting permalinks. Also try a name which does not have any latin characters.

    Thread Starter tahoom

    (@tahoom)

    checkout page has some kind of problem:
    – The header is not shown where the site logo and menus are available.

    I’m using W3 total cache, could the problem where order-received isn’t working be a problem with cache plugin (for minify settings)?

    I should delete any cached pages and minified css and js and deactivate the plugin until problem-solving and development is complete.

    Thread Starter tahoom

    (@tahoom)

    You right, there must be a problem with cache plugin. I couldn’t solve the problem yet but obviously there is a conflict between woocommerce and W3 total cache.
    Thanks a lot.

    Thread Starter tahoom

    (@tahoom)

    I couldn’t solve this problem and the problem I described before with no reply:
    https://wordpress.org/support/topic/fake-top-sales?replies=5

    Is there any way to completely refresh woocommerce without loosing products and settings? (settings are not really important I can do them again but products must remain with no changes)
    First I wanna delete all orders history and probably solve this problem.

Viewing 15 replies - 1 through 15 (of 19 total)

The topic ‘wrong template pages due to a mistake’ is closed to new replies.