Welcome, Guest
Username: Password: Remember me

TOPIC: Condition based on hidden questions

Condition based on hidden questions 3 years 1 month ago #65435

Hello folks!

I created a question (javascript) for randomization (1 or 2):

<script type="text/javascript" charset="utf-8">
$(document).ready(function() {
var randNumber = Math.floor(Math.random()*2 + 1);
$('input#answer99596X71X499').val(randNumber);
});
</script>

This question I hided in the advanced options.


No I want to show other question based on the result of the randomization (which is hide). This is not possible. And in the result section there is no result for the hidden question. How can I solve this problem?


Thank you, lovely community!
The administrator has disabled public write access.

Re: Condition based on hidden questions 3 years 1 month ago #65437

  • holch
  • holch's Avatar
  • OFFLINE
  • LimeSurvey Team
  • Posts: 2851
  • Thank you received: 358
  • Karma: 124
What is hidden in the advanced options is hidden and does not show up anywhere nor can it be stored nor can it be manipulated, as far as I know.

In order to be able to play with the question you have to hide it via CSS, as far as I know.
Have a look at the manual! It is a really valuable source for information. Here some helpful links:
Manual (EN) | Question Types | Question Attributes | Workarounds

If you found this answer helpful and it saved you some time please consider a donation to the project to keep Limesurvey going!
The administrator has disabled public write access.

Re: Condition based on hidden questions 3 years 1 month ago #65444

  • TMSWhite
  • TMSWhite's Avatar
  • OFFLINE
  • LimeSurvey Team
  • Posts: 759
  • Thank you received: 82
  • Karma: 36
In LimeSurvey 1.92, there is an Equation question type, which can be hidden yet does store a value (in the database too), so it can be used to control randomization. More details here.
The administrator has disabled public write access.
Moderators: ITEd
Time to create page: 0.110 seconds
Donation Image