Developer forum

Forum » Templates » Go to the next step at checkout

Go to the next step at checkout

Tomas Gomez
Reply

Hi,

Our client wants a custom checkout so we modified a checkout template, but the "Next step" button is not working. It sends the form and refresh the page but the same step appears again.

In the shopping cart settings, we unchecked the "Enable step validation" but not working yet (https://doc.dynamicweb.com/forum/rapido/rapido/form-validation-on-checkout-browser-back)

Besides the form, is there any other setting we have to configure? What are we doing wrong?

The code of the form is:

<form name="ordersubmit" id="ordersubmit" method="post" autocomplete="off" style="max-width: 65rem; margin-left: auto;" hidden>
        <input type="text" id="CurrentStep" name='@GetString("CartV2.CurrentStepButtonName")' value='@GetString("CartV2.CurrentStepButtonName")'>
        [ all the custom inputs ]
        <button type="submit" name='@GetString("CartV2.NextStepButtonName")' id='@GetString("CartV2.NextStepButtonName")'>Next</button>
</form>

Replies

 
Shiwanka Chathuranga Dynamicweb Employee
Shiwanka Chathuranga
Reply
This post has been marked as an answer

check cart log and see if you can find any clue

Votes for this answer: 1
 
Tomas Gomez
Reply

Hi Shiwanka,

Thanks for the tip! 

Comparing the logs of a completed order versus an uncompleted cart (see attached images), the uncompleted cart has a Field validation error. 

How can I know which field triggers the error?

Could it be the CurrentSetp input field? When i leave empty its value then sometimes the order is completed and sometimes not.

Regards,
Tomas

cart_with_error.png order_completed.png
 
Shiwanka Chathuranga Dynamicweb Employee
Shiwanka Chathuranga
Reply
This post has been marked as an answer

any validations under here in cart app?

Votes for this answer: 1
 
Shiwanka Chathuranga Dynamicweb Employee
Shiwanka Chathuranga
Reply
This post has been marked as an answer

also you can impliment this to check which field has validation error

https://doc.dynamicweb.com/template-tags/ecommerce/shopping-cart/receipt/validationerrors

 

Votes for this answer: 1
 
Tomas Gomez
Reply

Bingo!

Thanks a lot :-)

 

You must be logged in to post in the forum