Display percentage on Assessment

More
4 months 2 weeks ago #155493 by marektondryk
marektondryk replied the topic: Display percentage on Assessment
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....

Please Log in to join the conversation.

More
4 months 2 weeks ago #155495 by tpartner
tpartner replied the topic: Display percentage on Assessment
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.

Please Log in to join the conversation.

More
4 months 2 weeks ago #155496 by marektondryk
marektondryk replied the topic: Display percentage on Assessment
LS 2.64.7+170404 customized ubuntu_orange template
badanie.coachabilityindex.pl/index.php/329683

Please Log in to join the conversation.

More
4 months 2 weeks ago - 4 months 2 weeks ago #155526 by marektondryk
marektondryk replied the topic: Display percentage on Assessment
<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: 4 months 2 weeks ago by marektondryk. Reason: correction

Please Log in to join the conversation.

More
4 months 2 weeks ago #155527 by tpartner
tpartner replied the topic: Display percentage on Assessment
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.

Please Log in to join the conversation.

More
4 months 2 weeks ago - 4 months 2 weeks ago #155529 by marektondryk
marektondryk replied the topic: Display percentage on Assessment
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: 4 months 2 weeks ago by marektondryk.

Please Log in to join the conversation.

More
4 months 2 weeks ago #155567 by tpartner
tpartner replied the topic: Display percentage on Assessment
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.

Please Log in to join the conversation.

More
4 months 2 weeks ago #155571 by marektondryk
marektondryk replied the topic: Display percentage on Assessment
Link in the post above is for the short version with 2 groups of questions and without token....
OK... Tony thanks for Your gooddwill...

Please Log in to join the conversation.

More
4 months 2 weeks ago #155652 by tpartner
tpartner replied the topic: Display percentage on Assessment
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 - manual.limesurvey.org/Workarounds:_Manip...tc..29_in_LimeSurvey

Sample survey attached:

File Attachment:

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

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

Please Log in to join the conversation.

More
2 months 2 days ago #157776 by marektondryk
marektondryk replied the topic: Display percentage on Assessment

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?

Please Log in to join the conversation.

Start now!

Just create your account and start using Limesurvey today.

Register now