View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
11966 | Bug reports | Survey taking | public | 2016-11-30 09:05 | 2017-02-03 14:13 |
Reporter | seancarlos | Assigned To | c_schmitz | ||
Priority | none | Severity | minor | ||
Status | closed | Resolution | no change required | ||
Product Version | 2.55.x | ||||
Summary | 11966: Warning "Please check the format of your answer" appears even when regex answer validation is correct | ||||
Description | During data entry in a regex validated field the warning message "Please check the format of your answer" appears in red while the user types their answer. The message color changes to yellow - and remains - once the user has supplied a valid answer. Expected behavior: the message should disappear. (Using default template.) This is a minor issue with major impact: confused users. | ||||
Additional Information | This appears to be a regression: see bug 5823 for previous solution. I added .em_regex_validation.good { to template.css and the problem appears to be fixed. | ||||
Tags | No tags attached. | ||||
Attached Files | |||||
Bug heat | 4 | ||||
Complete LimeSurvey version number (& build) | 2.56.1+161118 | ||||
I will donate to the project if issue is resolved | No | ||||
Browser | Google Chrome 54.0.2840.100 (Official Build) (64-bit) | ||||
Database type & version | 260 | ||||
Server OS (if known) | Linux? (Dreamhost) | ||||
Webserver software & version (if known) | Apache | ||||
PHP Version | 5.5 | ||||
Please provide a little .lss file with one question demonstrating the issue. |
|
OK, got it : it's more a sentence issue than a bug. For example : for numeric : we have "Only numbers may be entered in this field." https://github.com/LimeSurvey/LimeSurvey/blob/master/application/helpers/expressions/em_manager_helper.php#L3133 it's OK in all case (if input contain only num : no issue) 2 solution :
PS : better to use https://manual.limesurvey.org/Question_type_-_Short_free_text#Whole_question_validation_equation_.28em_validation_q.29 because you can put the string you want. |
|
I suspect I didn't explain the problem very well. In the specific example REGEX evaluates input for a valid email address format. This works perfectly. The problem is the "Please check the format of your answer" message remains on the screen, changing from red to yellow, once the user input passes the regex test. If the input passes the regex test, the warning text shouldn't become yellow, it should disappear. This isn't a text messaging problem (but thank you for the tip in the PS above). |
|
I just tried the "Whole question validation equation (em_validation_q)" as suggested in the PS note above. During data entry, the custom message appears in red, next to a red exclamation mark. Once the entry passes the regex test, the message disappears, BUT the exclamation mark remains and becomes yellow, similar to the issue I reported in this bug. The html: <div id="vmsg_1194_q_fn_validation" class="em_q_fn_validation emtip good">
Question validation equation: Question validation tip (en): For me this is low priority, I "fixed" it by using a modified template; I'm just documenting this should it be useful to others. |
|
For Question validation tip (en): {if((isempty(q09) or regexMatch('/^(\w[-.+\w]\w@\w[-._\w]\w.\w{2,3})$/',q09)),'You email adress seems valid','Please enter a valid email address.')} :) |
|
Date Modified | Username | Field | Change |
---|---|---|---|
2016-11-30 09:05 | seancarlos | New Issue | |
2016-11-30 11:11 | DenisChenu | Note Added: 42280 | |
2016-11-30 13:46 | c_schmitz | Assigned To | => c_schmitz |
2016-11-30 13:46 | c_schmitz | Status | new => feedback |
2016-11-30 13:46 | c_schmitz | Note Edited: 42280 | |
2016-11-30 15:35 | seancarlos | File Added: limesurvey_survey_888.lss | |
2016-11-30 15:35 | seancarlos | Status | feedback => assigned |
2016-11-30 15:58 | DenisChenu | Note Added: 42297 | |
2016-11-30 17:36 | seancarlos | Note Added: 42302 | |
2016-12-01 10:46 | seancarlos | Note Added: 42305 | |
2016-12-06 17:22 | DenisChenu | Note Added: 42416 | |
2017-02-03 14:13 | c_schmitz | Status | assigned => closed |
2017-02-03 14:13 | c_schmitz | Resolution | open => no change required |