vierundzwanzig wrote:
I tried to create a question/answer with the donate example (LimeSurvey 1.92RC2 Build 12162 from SVN). If you want to enter a "$" sign the validation for the numeric question type seems to prevent you from entering anything that is not a number. It doesn't seem to matter if you set "Integer only" to "Yes" or "No".
The expression seems to work but if I'm correct it only works for the numeric input question type at the moment. I tried using a short free text with the same expression and the "Question Validation Equation" and "Question Validation Tip" don't work. There's no tip and it doesn't matter what you enter, it seems to be always true.
Not sure why it didn't work for you. Here is a working version using Short Text. You are correct that you can't enter a dollar sign in a Numeric Question type.
vierundzwanzig wrote:
There seems to be no option to hide the "Question Validation Tip". If you enter a custom tip it also looks kind of strange:
"The question must meet these criteria: Please donate at least $50.00."
Perhaps we can overriede the "The question must meet these criteria:" if a "Question Validation Tip" is set/used.
Since there are many different possible validation tips now (related to min/max answers; min/max values for each answer; min/max/equals values for sum of answers; regular expression validation; equation-based validation), we may want to extend the functionality of "hide_tip" to let users specify which types of tips they want to show/hide. You are correct that at the moment, those tips can not be hidden, but that is an easy coding change if, for example, the community says we should never show the regular expression or equation-based validation equations, instead requiring people to enter something into "help" to explain the validation in human-readable terms.
vierundzwanzig wrote:
If you want to use expressions in the question text or answer you have to use curly braces. But if you use them in the advance question settings you don't use them. This might confuse some users because there is no hint telling them that you don't use curly braces in here.
You are correct, and I need to update the documentation. You ONLY use curly braces in question/answer/help text. You don't use curly braces in the relevance equation, or any of the advanced question settings.
The reason for this is that relevance and advanced question settings are always expressions. Curly braces are only used to separate display strings from expressions.
-Tom