Avoiding choosing holidays and weekend days on date questions

More
11 months 2 weeks ago #161130 by terryaulenbach
terryaulenbach replied the topic: Avoiding choosing holidays and weekend days on date questions
Thanks again, Tony. This worked great after I fixed my typos :)

Please Log in or Create an account to join the conversation.

More
2 months 3 weeks ago #172684 by terryaulenbach
terryaulenbach replied the topic: Avoiding choosing holidays and weekend days on date questions
Hey, Tony. This code has been working great for us... until we upgraded to 3.12 last week. Then something weird started happening. Although it appears that surveys are being submitted with all data intact, rather than loading the end URL after a submit, the page is being reloaded with all the answers missing. So to the end user it looks like they just lost everything. When I do a "Check logic" on the 2 date questions (only one or the other comes up based on certain logic) I get what you see in the attachment. If you need to see the actual survey is there a way I can PM you the URL?

Attachments:

Please Log in or Create an account to join the conversation.

More
2 months 3 weeks ago #172701 by tpartner
tpartner replied the topic: Avoiding choosing holidays and weekend days on date questions
Are there any JavaScript errors in the console?

Does the survey submit correctly if you remove the JavaScript from the date questions?

Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.

Please Log in or Create an account to join the conversation.

More
2 months 3 weeks ago #172724 by terryaulenbach
terryaulenbach replied the topic: Avoiding choosing holidays and weekend days on date questions
There is something that pops up in the console upon submit:

VM392 pjax.min.js:1 Uncaught TypeError: Cannot read property 'match' of null
at Pjax.loadContent (VM392 pjax.min.js:1)
at Pjax.<anonymous> (VM392 pjax.min.js:1)
at XMLHttpRequest.request.onreadystatechange (VM392 pjax.min.js:1)
loadContent @ VM392 pjax.min.js:1
(anonymous) @ VM392 pjax.min.js:1
request.onreadystatechange @ VM392 pjax.min.js:1
XMLHttpRequest.send (async)
module.exports @ VM392 pjax.min.js:1
loadUrl @ VM392 pjax.min.js:1
(anonymous) @ VM392 pjax.min.js:1
(anonymous) @ VM392 pjax.min.js:1
Navigated to surveys.acadiau.ca/index.php/XXXXX (survey ID blocked out)
jquery-migrate-3.0.0.min.js:2 JQMIGRATE: Migrate is installed, version 3.0.0

Please Log in or Create an account to join the conversation.

More
2 months 3 weeks ago #172726 by tpartner
tpartner replied the topic: Avoiding choosing holidays and weekend days on date questions
Does the survey behave properly if you remove the date question JavaScript?

Try disabling AJAX mode in the theme options.


Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
Attachments:

Please Log in or Create an account to join the conversation.

More
2 months 3 weeks ago #172727 by terryaulenbach
terryaulenbach replied the topic: Avoiding choosing holidays and weekend days on date questions
Tony, once again you have saved the day. Disabling Ajax in the theme settings has fixed the problem. Coincidentally I am visiting my brother in Ajax, Ontario tonight :) Can you tell me why Ajax was causing this issue?

Terry

Please Log in or Create an account to join the conversation.

More
2 months 3 weeks ago #172733 by tpartner
tpartner replied the topic: Avoiding choosing holidays and weekend days on date questions
No, I can't say exactly but the pjax errors indicate a problem with loading the page via AJAX.

(those of us from the Ottawa area consider Ajax to be Toronto :) )

Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.

Please Log in or Create an account to join the conversation.

More
2 months 3 weeks ago #172734 by holch
holch replied the topic: Avoiding choosing holidays and weekend days on date questions
So Canadians are so crazy about Ajax that they built a whole city in its honor???? ;-)

I'm not a LimeSurvey GmbH member. I answer at the LimeSurvey forum in my spare time. No support via private message.
Some helpful links: Manual (EN) | Question Types | Workarounds

Please Log in or Create an account to join the conversation.

More
2 months 3 weeks ago #172735 by tpartner
tpartner replied the topic: Avoiding choosing holidays and weekend days on date questions
"City" may be over-stating it. :)

Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.

Please Log in or Create an account to join the conversation.

More
2 months 3 weeks ago #172736 by holch
holch replied the topic: Avoiding choosing holidays and weekend days on date questions
Well, then the Dutch are still the most Ajax-loving nation. Have named a football club after it. ;-)

I'm not a LimeSurvey GmbH member. I answer at the LimeSurvey forum in my spare time. No support via private message.
Some helpful links: Manual (EN) | Question Types | Workarounds

Please Log in or Create an account to join the conversation.

More
2 months 3 weeks ago #172851 by terryaulenbach
terryaulenbach replied the topic: Avoiding choosing holidays and weekend days on date questions
I always thought Ajax was for cleaning the bathroom.
The following user(s) said Thank You: LouisGac

Please Log in or Create an account to join the conversation.

Start now!

Just create your account and start using Limesurvey today.

Register now
Join our Newsletter!