x

Основни глави

  1. Get started
  2. Workspace
  3. Editor
  4. Question types
  5. Share
  6. Results
  7. Configuration
  8. Installation and updates
  9. Profile and personal settings
  10. Account and billing
  11. FAQs
  12. Development
 Actions

Теми на въпроса

From LimeSurvey Manual
This page is a translated version of the page Question themes and the translation is 31% complete.

Въведение

Темата на въпроса е вариант на тип на въпроса със свой собствен външен вид. Темите на въпроса могат да се създават само върху основни типове на въпроса. В редактора темите на въпроса са изброени заедно с типовете на въпроса: например Избор на списък с изображения (радио) и Бутони за един възможен отговор под Един възможен отговор, както и Бутони за множество възможности и Избор на изображение с множество възможности под Множество възможности.

Темата на въпроса променя един въпрос. За да промените външния вид на цялото проучване, използвайте настройките на темата на проучването. За промяна на външния вид на всички въпроси от даден тип чрез CSS вижте Редактор на теми.

Използване на тема на въпроса

Нов редактор:

  1. Изберете въпроса.
  2. В раздела Просто на настройките на въпроса щракнете върху Вид.
  3. Изберете темата на въпроса, например Бутони за един възможен отговор. За да я намерите по-бързо, въведете името ѝ в полето за търсене.
Списък с типове на въпроса в новия редактор с номерирани маркери при Вид, полето за търсене и темите на въпроса за Един възможен отговор и Множество възможности
  1. Вид в настройките на въпроса отваря списъка.
  2. Полето за търсене намира тип на въпроса или тема по името ѝ.
  3. Теми на въпроса за Един възможен отговор: Избор на списък с изображения (радио) и Бутони за един възможен отговор.
  4. Теми на въпроса за Множество възможности: Бутони за множество възможности и Избор на изображение с множество възможности.

Класически редактор: отворете въпроса и щракнете върху бутона с типа на въпроса до Тип на въпроса. Прозорецът Избор на тип въпрос изброява темите на въпроса в групите на техните типове на въпроса, под собствените им имена: например Бутони за Bootstrap и Избор на списък с изображения (радио) под Въпроси с един възможен отговор. Изберете темата и щракнете върху Избери.

Управление на темите на въпроса

Администраторите намират темите на въпроса на сайта за проучвания под Конфигурация ⇒ Теми, в раздела Теми на въпроса.

Меню Конфигурация с маркирани Теми под Разширени

Страница Теми с маркиран раздел Теми на въпроса над списъка с типове на въпроса и теми

Списъкът съдържа по един запис за всеки тип на въпроса плюс темите на въпроса:

  • Вид: Тип на въпроса за типовете на въпроса, Основна тема за темите на въпроса, които идват с LimeSurvey, и Потребителска тема за темите на въпроса, които сте инсталирали. Използвайте филтъра под заглавието на колоната, за да покажете само един вид.
  • Разширява се: кодът на типа на въпроса, върху който е изградена темата на въпроса, например L за Списък (Радио бутони). Вижте Типове на въпроса.
  • Видимост: превключва всеки запис на Включено или Изключено.

Списък с теми на въпроса, филтриран по Вид Основна тема, с кодове в Разширява се и превключватели за Видимост

Видимост

Темите на въпроса и типовете на въпроса са видими по подразбиране, но могат да бъдат изключени. След изключване те вече не се предлагат в списъка с типове на въпроса в редактора. Въпросите, които вече ги използват, продължават да работят.

Конфигурация ⇒ Теми ⇒ Теми на въпроса ⇒ Видимост

Question themes list with the Visibility column highlighted and the arrays/5point question type switched Off

The following screenshots of the question type selector of the classic editor show Array (5 point choice) with its visibility "On" (left) and "Off" (right).

Select question type list of the classic editor with Array (5 point choice) shown on the left and missing on the right

A question theme is only offered as a question type when its config.xml sets show_as_question_type (see Engine).

Uninstall a question theme

  1. Go to Configuration ⇒ Themes ⇒ Question themes.
  2. Tick the box of each question theme you want to uninstall.
  3. Click Uninstall in the bar at the bottom of the list and confirm.

Question themes list with the Range-Slider user theme selected and the Uninstall button in the bar at the bottom

Only question themes you installed yourself (type User theme) can be uninstalled. Question types and core themes can't be uninstalled, and neither can a question theme that is used in a survey or extended by another question theme.

An uninstalled question theme is no longer offered in the editor. If its files are still on the survey site, it is listed under Available question themes below the list, with an Install button.

Broken question themes

If there are errors while loading the available question themes, they are listed under Broken question themes with the error message.

Install a question theme

Click Upload & install at the top of the Themes page while the Question themes tab is open, and select the ZIP file of the theme. The theme is installed and available at once.

Before you compress the theme folder to a ZIP file, it must have this structure:

NAME/survey/questions/answer/QUESTIONTYPENAME/config.xml

For example, the core theme Bootstrap buttons for List (radio) has its config.xml in bootstrap_buttons/survey/questions/answer/listradio/.

When you import a question theme made for an older version of LimeSurvey, it is converted to the current format: <custom_attributes> becomes <attributes>, a <compatibility> section is added, and missing metadata is copied from the question type the theme extends.

The core question themes are in themes/question/ of your LimeSurvey installation, the question themes you install in upload/themes/question/.

Question type codes and CSS classes

The code of each question type (used in Extends and in <questionType>) and the CSS class of its question container are listed in Theme editor: question type classes.

Configuration

The configuration of a question theme is in its config.xml. The core question themes in the folder themes/question/ of the LimeSurvey source code are good examples.

Metadata

The metadata describe the question theme. These settings are also saved in the database.

<metadata>
    <name>bootstrap_buttons</name>
    <type>question_theme</type>
    <title>Bootstrap buttons</title>
    <creationDate>22/05/2018</creationDate>
    <author>LimeSurvey GmbH</author>
    <authorEmail>info@limesurvey.org</authorEmail>
    <authorUrl>http://www.limesurvey.org</authorUrl>
    <copyright>Copyright (C) 2005 - 2018 LimeSurvey Gmbh, Inc. All rights reserved.</copyright>
    <license>GNU General Public License version 2 or later</license>
    <version>1.0</version>
    <apiVersion>1</apiVersion>
    <description>New implementation of the Bootstrap buttons question theme</description>
    <questionType>L</questionType>
    <group>Single choice questions</group>
    <subquestions>0</subquestions>
    <answerscales>1</answerscales>
    <hasdefaultvalues>1</hasdefaultvalues>
    <assessable>1</assessable>
    <class>list-radio</class>
</metadata>
Tag Type Mandatory Description
name string x The name of the extension
type string x Type of the extension; can be "plugin", "theme", etc; see below
title string x The title that is displayed in the frontend
creationDate date (YYYY-MM-DD) Date the extension was created
lastUpdate date (YYYY-MM-DD) Date of the latest update
author string x Plugin author
authorUrl url x URL to author web page, necessary so that customers can contact author for support
copyright string x Copyright Information
license string x Extension licence
version string as semantic version x Extension version number
apiVersion string x Api version number
description string x Information that will be shown as help text
questionType string x The question type the theme is associated with
group string x The group inside the selector it should be assigned to
subquestions string x If or how many subquestion scales should be displayed
answerscales string x If or how many answer scales should be displayed
hasdefaultvalues string x If the theme has default values
assessable string x If the theme can be used for assessments (quiz)
class string x The HTML class name for the theme

Compatibility

The <compatibility> section lists the LimeSurvey versions the theme works with, one <version> tag each, for example 7.0.

Files

The <files> section lists the CSS and JavaScript files and the preview image. The CSS and JavaScript files are loaded via the asset manager.

General attributes

General attributes are the question settings that are predefined and the same for all question themes. No new ones can be added. To show or hide certain settings for a question theme, add or remove the attribute.

Attributes

Attributes are settings you give a question theme, and you can customize them. They are shown in the question settings of the editor.

Tag Description
name The internal name
category The category in which the attribute is displayed. This can also be a new one.
sortorder The position of the attribute inside its category: the smallest number comes first
inputtype What type the input should be rendered as
options The choices of a button group or dropdown
default The default value for the input field
help The help text
caption The label of the setting in the editor
i18n The setting can have a different value per survey language
readonly The setting can't be changed
readonly_when_active The setting can't be changed when the survey is active
expression The setting can contain ExpressionScript

Engine

Configuration for special load options.

Tag Type Mandatory Description
load_core_css boolean If core CSS should be loaded
load_core_js boolean If core JavaScript should be loaded
show_as_template boolean If the theme should be loaded
show_as_question_type boolean If the theme should be listed in the question type selector

FAQ

Does a question theme change the whole survey?

No. A question theme changes one question. To change the look of the whole survey, use the theme options.

Why can't I find a question theme in the list?

Check its Visibility on the Question themes tab under Configuration ⇒ Themes. Visibility switches each theme on or off.

Can I install my own question theme?

Yes. Click Upload & install at the top of the Themes page while the Question themes tab is open, and select the ZIP file of the theme.

Тази страница може да е преведена машинно и да съдържа грешки. Покажи английския оригинал · Подобри този превод