-
Notifications
You must be signed in to change notification settings - Fork 13
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Single-page webform won't complete (when 'page_num' is equal to 'page_count') #170
Comments
jenlampton
changed the title
Webform won't complete
Webform won't complete (custom code use-case)
Oct 29, 2020
jenlampton
pushed a commit
to jenlampton/webform
that referenced
this issue
Oct 29, 2020
…equal to page count.
I've filed a PR at #171, but It needs to be tested on multi-page webforms to see if there are any adverse effects. |
You could also put in debugs and look at the incrementing numbers for both page_num and page_count to see how they change with each page. That might reveal why it's set this way. |
jenlampton
changed the title
Webform won't complete (custom code use-case)
Single-page webform won't complete (when 'page_num' is equal to 'page_count')
Aug 15, 2022
robertgarrigos
added a commit
to robertgarrigos/webform
that referenced
this issue
Dec 5, 2022
Issue backdrop-contrib#170: Check if current page is greater than or equal to page co…
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I'm having a problem with a webform that won't complete when it's submitted, it just keeps reloading the same page.
Here's my use case: I have [some reason] that I need to attach the submit handler to the submit button, rather than doing it in
['#submit']
, but when I add them both here, the form won't complete.My code:
I get to this part of the code in
webform_client_form_pages()
and it fails......because 'page_num' is equal to 'page_count'. Then, when
webform_client_form_submit()
fires, it bails out immediately because$form_state['webform_completed']
is FALSE.Switching the greater-than check to greater-than-or-equal-to fixes my problem, but I wonder if there are risks to making this change? Why was it expected to be greater?
(On this site I only have single-page webforms)
The text was updated successfully, but these errors were encountered: