- Posts: 16
- Thank you received: 0
Welcome to the LimeSurvey Community Forum
Ask the community, share ideas, and connect with other LimeSurvey users!
Java Script in Questions not working
- lemmon
- Topic Author
- Offline
- New Member
Less
More
5 years 4 months ago #176280
by lemmon
Java Script in Questions not working was created by lemmon
Hello LimeSurvey Community
I am new here, and also have become more active with LS recently. Great tool, thanks so much for this.
Now my question: I am trying to implement a consent forum at the beginning of my survey, and tried this:
www.limesurvey.org/forum/can-i-do-this-w...if-consent-not-given
Unfortunately, it does not work. I tried some variations to no avail. I have disabled "Filter HTML for XSS" in general settings. Then I downloaded the "Default Values In One Scale Of A Dual-scale Array Question" from here:
manual.limesurvey.org/Workarounds:_Manip...s_in_array_questions
This doesn't work either. The following example works:
<script type="text/javascript" charset="utf-8">
$(document).on('ready pjax:complete',function() {
alert("Test!");
});
</script>
Any ideas why the consent script above doesn't work, and neither the default value example above? I am on version 3.14.10+180924, tried both Chrome and IE.
I am new here, and also have become more active with LS recently. Great tool, thanks so much for this.
Now my question: I am trying to implement a consent forum at the beginning of my survey, and tried this:
www.limesurvey.org/forum/can-i-do-this-w...if-consent-not-given
Unfortunately, it does not work. I tried some variations to no avail. I have disabled "Filter HTML for XSS" in general settings. Then I downloaded the "Default Values In One Scale Of A Dual-scale Array Question" from here:
manual.limesurvey.org/Workarounds:_Manip...s_in_array_questions
This doesn't work either. The following example works:
<script type="text/javascript" charset="utf-8">
$(document).on('ready pjax:complete',function() {
alert("Test!");
});
</script>
Any ideas why the consent script above doesn't work, and neither the default value example above? I am on version 3.14.10+180924, tried both Chrome and IE.
The topic has been locked.
- tpartner
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 10611
- Thank you received: 3691
5 years 4 months ago #176284
by tpartner
Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
Replied by tpartner on topic Java Script in Questions not working
Both of the scripts you tried are for a LimeSurvey version more than 4 years old.
What exactly are you trying to do?
What exactly are you trying to do?
Cheers,
Tony Partner
Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
The topic has been locked.
- jelo
- Offline
- Platinum Member
Less
More
- Posts: 5070
- Thank you received: 1263
5 years 4 months ago #176313
by jelo
With the current LS 3.X version you can use the privacy data policy feature.
The meaning of the word "stable" for users
www.limesurvey.org/forum/development/117...ord-stable-for-users
Replied by jelo on topic Java Script in Questions not working
forum? Or form?lemmon wrote: implement a consent forum
With the current LS 3.X version you can use the privacy data policy feature.
The meaning of the word "stable" for users
www.limesurvey.org/forum/development/117...ord-stable-for-users
Attachments:
The following user(s) said Thank You: lemmon
The topic has been locked.
- lemmon
- Topic Author
- Offline
- New Member
Less
More
- Posts: 16
- Thank you received: 0
5 years 4 months ago #176329
by lemmon
Replied by lemmon on topic Java Script in Questions not working
Thank you for your response, tpartner. I will study the js differences between the versions. I was trying to implement a consent solution based on the first link in my post.
Jelo, many thanks for bringing to my attention that LS3 now has consent functionality built it. This is exactly what I need, and for now I will use that.
Jelo, many thanks for bringing to my attention that LS3 now has consent functionality built it. This is exactly what I need, and for now I will use that.
The topic has been locked.