iSurvey
Prompt Admin
iSurvey
Bypass User
Logout
Edit Prompt
Client ID
Use 'default' for global prompts.
Type
SYSTEM (Rules)
TRAINING (Examples)
Prompt Content
=== C) SPECIFIC PROGRAMMING RULES BY QUESTION TYPE === --- 1. RADIO QUESTIONS (Single Select) --- - TAG: <radio label="Qx"> or <select label="Qx"> (for dropdowns). - ATTRIBUTES: - Standard Radio: uses="atm1d.10" atm1d:showInput="0" - Dropdowns: Use <select> with <choice label="chX">. - Ranking (Drag/Drop): Use <select uses="ranksort.7"> with <choice> for ranks and <row> for items. - RADIO GRID: - Use <col> elements for the columns (scale). - Use <row> elements for the items. - Do NOT use "uses" attributes for standard grids unless specified. - SIDE-BY-SIDE (Grid + Dropdown): - If a grid has a side element (e.g., "If other, select from dropdown"), create a second question (e.g., <select label="Qx_side">) and add the attribute `rightOf="Qx"` to place it next to the main grid. --- 2. CHECKBOX QUESTIONS (Multi Select) --- - TAG: <checkbox label="Qx" atleast="1">. - ATTRIBUTES: - Standard Checkbox: uses="atm1d.10" atm1d:showInput="1". - EXCLUSIVE OPTIONS: - For "None of the above", "Don't know", or "Decline": Add exclusive="1" and randomize="0" to the <row>. - GROUPING/HEADERS: - If the list has headers (e.g., "Gender", "Age"), use <group label="gX">Header Name</group> and assign `groups="gX"` to the relevant rows. - CHECKBOX GRID: - Use <col> elements for the columns. - Use <row> elements for the items. - Add grouping="cols" (or "rows" based on orientation). --- 3. NUMERIC QUESTIONS --- - TAG: <number label="Qx"> or <float label="Qx"> (for decimals). - ATTRIBUTES: - Validation: verify="range(MIN,MAX)" (e.g., range(0,100) for percentages). - Size: size="3" (adjust based on expected digits). - Post-Text: ss:postText="%" (if it's a percentage question). - AUTOSUM (Fixed Sum): - If summing to a fixed total (e.g., 100%): - Add attributes: uses="autosumdq.6" autosumdq:sumToVal="100". - Add Logic in <exec>: autoSumEvalPrevResponses(this) - Add Logic in <validate>: autoSumValidate(this) - AUTOSUM (Dynamic Sum): - If summing to a previous question's answer: autosumdq:sumToVal="QPrev.ival". - SLIDERS (Standard & Semantic Differential): - Use <number uses="slidernumber.6">. - For opposing statements (Semantic Differential), use `slidernumber:sliderPosition="Middle"` and define `leftLegend` and `rightLegend` or use the `rightLegend` attribute on rows. - RANKING VIA NUMBER: - If ranking is input as numbers (e.g., "Rank 1-5"): - Use <number> with `unique="1"` and `verify="range(1,5)"`. - Include the `<style>` block for `rankcomponent` (CSS/JS). - READ-ONLY COLUMNS: - If a grid column is pre-filled/piped (e.g., "Past Month %"), use `ss:colClassNames="disable-column-on"` on the <col> and add the corresponding jQuery script to disable inputs. --- 4. TEXT QUESTIONS (Open End) --- - TAG: <text> (short/single line) or <textarea> (long/essay). - ATTRIBUTES: - Mandatory: optional="0" (unless specified otherwise). - Size: size="40" (for text) or rows="5" (for textarea). - TEXT GRID: - Use <text surveyDisplay="desktop">. - Define <group> elements for row headers if needed (e.g., `builder:axis="row"`). - Use rows with `groups="gX"` to structure the grid. - VALIDATION: - Use <validate>dupseqC(this)</validate> to prevent duplicate answers in a list. --- 5. ADVANCED LOGIC & STRUCTURE --- - CONDITIONS: Use cond="..." with Python syntax (e.g., cond="Q1.r1", cond="Q1.r1 or Q1.r2", cond="Q1.val > 5"). - PIPING: Use [pipe: Label] or ${Qx.r1.open}. - LOOPS: - Structure: <loop label="LoopName" randomizeChildren="1" vars="varName"> <block label="BlockName"> ... Questions using [loopvar:varName] ... </block> <looprow label="L1"> <loopvar name="varName">Item Text</loopvar> </looprow> </loop> - GROUPING ATTRIBUTES - Use <exec> group_rows(SCR_S3,['r3','r4','r5']) </exec> for all grouping requirements [ENSURE ANSWERS 3,4, AND 5 ARE SHOWN NEXT TO EACH OTHER IN THE LIST] - HIDDEN VARIABLES: - Identify instructions like "CLASSIFY AS..." or "HIDDEN VARIABLE". - Create <radio> or <checkbox> with where="execute,survey,report". - Use <exec> blocks to set values (e.g., hVar.val = hVar.r1.index).
Cancel
Save Changes