Welcome to the LimeSurvey Community Forum

Ask the community, share ideas, and connect with other LimeSurvey users!

Display percentage on Assessment

More
8 years 2 months ago #155493 by marektondryk
I have problem with progress bar and counting hide/equation questions.
I use tip from: www.limesurvey.org/de/foren/design-issue...ith-hidden-questions
I put code in description of each 6 groups of questions but equation questions (set to hide) are displayed and progess bar counting "empty" equation questions....
The topic has been locked.
More
8 years 2 months ago #155495 by tpartner
What LimeSurvey version and template are you using?

Can you give a link to a short test survey.

Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
The topic has been locked.
More
8 years 2 months ago #155496 by marektondryk
LS 2.64.7+170404 customized ubuntu_orange template
badanie.coachabilityindex.pl/index.php/329683
The topic has been locked.
More
8 years 2 months ago - 8 years 2 months ago #155526 by marektondryk
Code:
<script type="text/javascript" charset="utf-8">     
  $(document).ready(function() {
    var progressValue = 32;
    $('.progress-bar').css({
      'transition': 'width 0s ease 0s',
      'width': progressValue+'%'
    }).attr('aria-valuenow', progressValue).text(progressValue+'%');
  });
</script>

What does "progressValue=32" mean?
Last edit: 8 years 2 months ago by marektondryk. Reason: correction
The topic has been locked.
More
8 years 2 months ago #155527 by tpartner
Sorry, I am not going to try and debug where there is a 20 second timer on every page.

Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
The topic has been locked.
More
8 years 2 months ago - 8 years 2 months ago #155529 by marektondryk
Sorry Tony, time is set off.
There is short version of survey.
2 groups of questions (10 questions+10 hidden questions in each group).

____________________
<script type="text/javascript" charset="utf-8">
$(document).ready(function() {
var progressValue = 32;
$('.progress-bar').css({
'transition': 'width 0s ease 0s',
'width': progressValue+'%'
}).attr('aria-valuenow', progressValue).text(progressValue+'%');
});
</script>
______________________
I put this code in description od each group.

Would You like to try agin? I have no idea what is going there...... :(
Please.........
badanie.coachabilityindex.pl/index.php/298654?lang=pl
Last edit: 8 years 2 months ago by marektondryk.
The topic has been locked.
More
8 years 2 months ago #155567 by tpartner
Now the survey requires a token so I cannot access it - sorry, but I give up.

Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
The topic has been locked.
More
8 years 2 months ago #155571 by marektondryk
Link in the post above is for the short version with 2 groups of questions and without token....
OK... Tony thanks for Your gooddwill...
The topic has been locked.
More
8 years 2 months ago #155652 by tpartner
I don't see that script in the source of the page. It must be in an element that is present on the page. So, if you place it in the group description, you must enable "Show group description" in the survey settings. Alternatively, you can place the script in the source of a question.

More info on using JavaScript in your survey - www.limesurvey.org/manual/Workarounds:_M...tc..29_in_LimeSurvey

Sample survey attached:

File Attachment:

File Name: limesurvey...6-07.lss
File Size:14.46 KB

Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
The topic has been locked.
More
8 years 5 days ago #157776 by marektondryk

LouisGac wrote: just for information, in the next LS major release the assessments page will be easy to customise from any template (even the calculation of scores):

github.com/LimeSurvey/LimeSurvey/blob/de...ews/assessments.twig


Louis when next LS major release will be publish?
How can I use this script?
github.com/LimeSurvey/LimeSurvey/blob/de...ews/assessments.twig
Where should I put this code?
The topic has been locked.
Moderators: tpartnerholch

Lime-years ahead

Online-surveys for every purse and purpose