Difference between revisions of "Set focus on question text in the top"
(New page: == Challenge == If the question text is to big or answer option is long then the respondent can not see the begining of the question text. == Solution == *In questionnaire template ed...) |
(→Code) |
||
Line 12: | Line 12: | ||
quest.init = function(){ | quest.init = function(){ | ||
− | document["query"][this.questions[0].label].focus(); | + | document["query"][this.questions[0].label].focus();//applied for specific question type only |
− | + | //$("#page_question_text").scrollTop(0); -> applied for page question | |
+ | this.onInit(); | ||
} | } | ||
</source> | </source> |
Revision as of 05:29, 10 July 2009
Challenge
If the question text is to big or answer option is long then the respondent can not see the begining of the question text.
Solution
- In questionnaire template editor, choose the question you want edit and then go to the Properties - Edit question properties - Language dependent - Select javascript property
Code
quest.init = function(){
document["query"][this.questions[0].label].focus();//applied for specific question type only
//$("#page_question_text").scrollTop(0); -> applied for page question
this.onInit();
}