WordPress.org

Ready to get started?Download WordPress

Forums

WordPress Simple Paypal Shopping Cart
[resolved] checkout functions return 404 error all of the sudden (27 posts)

  1. Viktor Nagornyy
    Member
    Posted 1 year ago #

    So for some reason checkout page functions (changing quantity and deleting product) return 404 error on the checkout page, the URL remains the same for checkout page. It seems to be some sort of ajax issue.

    This started happening on last 3.5 version, so I upgraded everything WP and all other plugins. I disabled W3TC completely, default htaccess and even disabled Better WP Security, still 404 issue continues.

    URL of product page so you can and see what happens:
    http://thislittlesoapofmine.com/product/naturally-gentle-bath-soap/

    Would really appreciate help.

    http://wordpress.org/plugins/wordpress-simple-paypal-shopping-cart/

  2. mra13
    Member
    Plugin Author

    Posted 1 year ago #

    I just checked it on your site and it works fine. I am guessing you had a temporary caching issue. Please reply to this thread if you are still seeing the issue.

  3. Viktor Nagornyy
    Member
    Posted 1 year ago #

    Nope, still getting an error. I tried different OS/browser configurations on separate machines. Still getting 404 if deleting product or changing quantity. A friend of mine mentioned that it could be error with form post method since its redirecting to 404.

  4. tomfrom
    Member
    Posted 1 year ago #

    Im also having the same issue on my website and im getting the same problems on viktorix's website. Has anyone got a fix for this?

  5. mra13
    Member
    Plugin Author

    Posted 1 year ago #

    can you please post a link to the page where you have the product?

  6. tomfrom
    Member
    Posted 1 year ago #

    sorry

    http://www.amphorea-buckets.co.uk/products/plastic-oval-buckets/

    try adding the first product on that page and changing the quantity or removing the item.

  7. Viktor Nagornyy
    Member
    Posted 1 year ago #

    I can confirm same issue on tomfrom's website as mine.

  8. mbrsolution
    Member
    Posted 1 year ago #

    Hello @tomfrom, I did as you mentioned above and I don't get any errors however I don't see any shopping cart. I only see the image of the product and nothing else.

    Kind regards

  9. tomfrom
    Member
    Posted 1 year ago #

    thats part of this problem though, if you click the add to cart button and it doesnt show you the shopping cart you can click 'view cart' on the product page at the top. the problem seems to be viewing the cart and also updating it

  10. mbrsolution
    Member
    Posted 1 year ago #

    Hi @tomfrom, is this the first time you install the plugin? What version of wordpress are you using? What theme are you using? Do you have any cache plugin?

    It looks like either the configuration is not set correctly or there could be a conflict with the theme or a plugin.

    What shortcode are you adding to the page or post?

    Kind regards

  11. tomfrom
    Member
    Posted 1 year ago #

    Im using 3.4.2 and yes its the first time im using the plugin. Im using the twenty eleven theme and theres no cache plugins. Im actually updating the site for someone else.

    Im using the PHP method to include the button and the normal shortcode to show the shopping cart.

    I have tried deactivating some of the other plugins but ive not had any luck.

    Thanks again

    Tom

  12. mbrsolution
    Member
    Posted 1 year ago #

    Your WordPress 3.4.2 version is old. Have you tried to upgrade WordPress to version 3.5.2? Or maybe even 3.6 but I would wait a bit more and do more testing before upgrading to 3.6. WordPress 3.5.2 should be your current version.

    Of course always do a backup before you upgrade.

    Try to add the shortcode without adding the php just to test and see if there are other conflicts.

  13. Viktor Nagornyy
    Member
    Posted 1 year ago #

    My website uses latest WP and plugins versions and still has this issue, so it's not that. Also, no caching plugins. Issue just showed up.

  14. mbrsolution
    Member
    Posted 1 year ago #

    Hi @viktorix are you using the same theme as @tomfrom?

  15. Viktor Nagornyy
    Member
    Posted 1 year ago #

    no, its a different theme. originally, it was buttercream theme and we customized it.

  16. tomfrom
    Member
    Posted 1 year ago #

    Ive just tested this on a new install of wordpress and everything seems fine. I need to get access to the htaccess file and see if theres anything in there causing a problem, i think it will either be a plugin conflict, htaccess issue or out of date wordpress install

  17. mbrsolution
    Member
    Posted 1 year ago #

    Hi @tomfrom, as I suspected. I am sure once you find out what the culprit is you will enjoy this great plugin :)

    @viktorix, have you tried the default WordPress theme to see if that works?

  18. jeremyspouken
    Member
    Posted 1 year ago #

    This commonly happens when you are using a reserved name on one of your form elements or you have a custom post type and one of your form element names collides.

    So if you have a Custom Post Type named Product this plugin will fail and you will get a 404. I replicated it and used Fiddler to make sure this was actually happening.

    Happened to me on one of my sites today and my site has WooCommerce installed which has a Product Custom Post Type.

  19. jeremyspouken
    Member
    Posted 1 year ago #

    Quick and dirty fix on my clients site:

    I edited the plugins code and replaced the product form elements name to wsc_product and all relevant code.

    Example:
    <input type="hidden" name="wsc_product" value="$25.00 Gift Certificate">

    Here is my site
    http://www.fitrightnw.com/gift-certificate/

    Works like a charm.

    Hope this helps.

  20. eukaryoter
    Member
    Posted 1 year ago #

    Thank you, jeremyspouken!

    Works like a charm for me now aswell when I deactivated WooCommerce which made me the Products CPT.

  21. jeremyspouken
    Member
    Posted 1 year ago #

    Glad that helped.

  22. tomfrom
    Member
    Posted 12 months ago #

    Im still having this problem, ive updated to wordpres 3.6 and dissabled all other plugins so i know its not any problems with that.

    I am however using custom post types to display information about each product but i dont have any named 'product'

    they are:
    item_name
    item_number
    nominal_volume
    brimful_volume
    dimension
    d1
    handle
    packing_unit
    pdf
    product_name
    product_price

    I have noticed that if the product name in WSC is the same as the name for the product post, the shopping cart will go to the product page when updated, if i change the name of the product so its not the same as the product page title then a 404 page will load, so it sounds similar to the problem jeremyspouken describes above.

    anyone have any ideas on how i could fix this? im going to try changing the permalinks, page titles and custom post type lables to see if anything fixes it.

  23. tomfrom
    Member
    Posted 12 months ago #

    If i dont enter a product name everything works as expected...

  24. tomfrom
    Member
    Posted 12 months ago #

    Followed jeremyspouken's advice and replaced 'product' with 'wsc_product' in wp_shopping_cart.php where needed ($POST_('product') and input name="product"). Working perfectly! thanks jeremyspouken

    mra13 could you add this fix to future releases of your plugin? thanks :)

  25. Viktor Nagornyy
    Member
    Posted 11 months ago #

    Fix works great. Just make sure you replace all instances!

  26. mra13
    Member
    Plugin Author

    Posted 11 months ago #

    Thank you. I will make this change in a future release of this plugin.

  27. tomfrom
    Member
    Posted 11 months ago #

    Hello mra13, i think you have implemented this fix into your latest version, i updated the plugin today but the fault came back, ive reverted to my modified version for now, just letting you know!

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic