Forum › Forums › Unipark › My Html code is not working › Reply To: My Html code is not working
Inside the App there is not possible to put the style in a CSS document which it will be the best practice (like in a Webpage) to edit the questions and answers that Unipark offers.
It is possible, but i agree with you that it is NOT easy to find or to undestand. You need to modify the user.css. You find that file via “Survey Menu > Layout > Pro-Editor -> [Scroll down to bottom] > user.css”. This file is normally empty (only a comment) but there you can put your css rules. Every question gets its own classes based on the question id, so you can style the hole question or subelements using css selectors. Assuming a question id of 12341234 you can use “.question-{id}” or “.nameq_{id}” to select the question.
Since I dont like it to jump between html/question and the user.css file I mostly add a 998 question element to the page where I need to style something and use jQuery on page load with selectors to apply the styling. The advantage (imho) is that you have the styling information directly on the same page with styled element (in questionnaire editor), a small disadvantage is the fact that you use javascript to apply styling data and that its changed on client side after its rendered the first time. But since you can use the user.css its a question of performance vs. maintainability where I would always choose the latter.
The reason that you have a piece of working html/css that works outside from unipark but not inside might be, that the unipark stylesheets have rules for base elements that matches your elements too and therefore not only your css rules are applied to the element but some unipark rules as well which may break the layout.
To help you further I need more information, f.e. you activate your questionnaire for public viewing and sent me the link as private message so I can have a look at it.