View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
04672 | Bug reports | Survey taking | public | 2010-10-12 20:36 | 2010-10-24 17:21 |
Reporter | luke | Assigned To | c_schmitz | ||
Priority | high | Severity | partial_block | ||
Status | closed | Resolution | fixed | ||
Product Version | 1.90+ | ||||
Fixed in Version | 1.90+ | ||||
Summary | 04672: Date field losing responses | ||||
Description | Responses already entered are not showing on the screen when using the Previous/Next buttons. | ||||
Steps To Reproduce |
| ||||
Additional Information | The problem also occurs when using the "calendar" mode (instead of the dropdowns as in the attached survey). In step 6, a valid response gets changed to some random date. | ||||
Tags | No tags attached. | ||||
Attached Files | date_fields_test.lss (14,994 bytes)
<?xml version="1.0" encoding="UTF-8"?> <document> <LimeSurveyDocType>Survey</LimeSurveyDocType> <DBVersion>143</DBVersion> <languages> <language>en</language> </languages> <groups> <fields> <fieldname>gid</fieldname> <fieldname>sid</fieldname> <fieldname>group_name</fieldname> <fieldname>group_order</fieldname> <fieldname>description</fieldname> <fieldname>language</fieldname> </fields> <rows> <row> <gid><![CDATA[27]]></gid> <sid><![CDATA[46143]]></sid> <group_name><![CDATA[g1]]></group_name> <group_order><![CDATA[0]]></group_order> <description><![CDATA[]]></description> <language><![CDATA[en]]></language> </row> <row> <gid><![CDATA[28]]></gid> <sid><![CDATA[46143]]></sid> <group_name><![CDATA[g2]]></group_name> <group_order><![CDATA[1]]></group_order> <description><![CDATA[]]></description> <language><![CDATA[en]]></language> </row> </rows> </groups> <questions> <fields> <fieldname>qid</fieldname> <fieldname>parent_qid</fieldname> <fieldname>sid</fieldname> <fieldname>gid</fieldname> <fieldname>type</fieldname> <fieldname>title</fieldname> <fieldname>question</fieldname> <fieldname>preg</fieldname> <fieldname>help</fieldname> <fieldname>other</fieldname> <fieldname>mandatory</fieldname> <fieldname>question_order</fieldname> <fieldname>language</fieldname> <fieldname>scale_id</fieldname> <fieldname>same_default</fieldname> </fields> <rows> <row> <qid><![CDATA[68]]></qid> <parent_qid><![CDATA[0]]></parent_qid> <sid><![CDATA[46143]]></sid> <gid><![CDATA[27]]></gid> <type><![CDATA[D]]></type> <title><![CDATA[q1]]></title> <question><![CDATA[]]></question> <preg><![CDATA[]]></preg> <help><![CDATA[]]></help> <other><![CDATA[N]]></other> <mandatory><![CDATA[N]]></mandatory> <question_order><![CDATA[0]]></question_order> <language><![CDATA[en]]></language> <scale_id><![CDATA[0]]></scale_id> <same_default><![CDATA[0]]></same_default> </row> <row> <qid><![CDATA[69]]></qid> <parent_qid><![CDATA[0]]></parent_qid> <sid><![CDATA[46143]]></sid> <gid><![CDATA[28]]></gid> <type><![CDATA[T]]></type> <title><![CDATA[q3]]></title> <question><![CDATA[]]></question> <preg><![CDATA[]]></preg> <help><![CDATA[]]></help> <other><![CDATA[N]]></other> <mandatory><![CDATA[N]]></mandatory> <question_order><![CDATA[0]]></question_order> <language><![CDATA[en]]></language> <scale_id><![CDATA[0]]></scale_id> <same_default><![CDATA[0]]></same_default> </row> </rows> </questions> <question_attributes> <fields> <fieldname>qaid</fieldname> <fieldname>qid</fieldname> <fieldname>attribute</fieldname> <fieldname>value</fieldname> </fields> <rows> <row> <qaid><![CDATA[393]]></qaid> <qid><![CDATA[68]]></qid> <attribute><![CDATA[dropdown_dates]]></attribute> <value><![CDATA[1]]></value> </row> <row> <qaid><![CDATA[394]]></qaid> <qid><![CDATA[68]]></qid> <attribute><![CDATA[dropdown_dates_year_min]]></attribute> <value><![CDATA[]]></value> </row> <row> <qaid><![CDATA[395]]></qaid> <qid><![CDATA[68]]></qid> <attribute><![CDATA[dropdown_dates_year_max]]></attribute> <value><![CDATA[]]></value> </row> <row> <qaid><![CDATA[396]]></qaid> <qid><![CDATA[68]]></qid> <attribute><![CDATA[hidden]]></attribute> <value><![CDATA[0]]></value> </row> <row> <qaid><![CDATA[397]]></qaid> <qid><![CDATA[68]]></qid> <attribute><![CDATA[page_break]]></attribute> <value><![CDATA[0]]></value> </row> <row> <qaid><![CDATA[398]]></qaid> <qid><![CDATA[69]]></qid> <attribute><![CDATA[array_filter]]></attribute> <value><![CDATA[]]></value> </row> <row> <qaid><![CDATA[399]]></qaid> <qid><![CDATA[69]]></qid> <attribute><![CDATA[array_filter_exclude]]></attribute> <value><![CDATA[]]></value> </row> <row> <qaid><![CDATA[400]]></qaid> <qid><![CDATA[69]]></qid> <attribute><![CDATA[display_rows]]></attribute> <value><![CDATA[]]></value> </row> <row> <qaid><![CDATA[401]]></qaid> <qid><![CDATA[69]]></qid> <attribute><![CDATA[hidden]]></attribute> <value><![CDATA[0]]></value> </row> <row> <qaid><![CDATA[402]]></qaid> <qid><![CDATA[69]]></qid> <attribute><![CDATA[maximum_chars]]></attribute> <value><![CDATA[]]></value> </row> <row> <qaid><![CDATA[403]]></qaid> <qid><![CDATA[69]]></qid> <attribute><![CDATA[page_break]]></attribute> <value><![CDATA[0]]></value> </row> <row> <qaid><![CDATA[404]]></qaid> <qid><![CDATA[69]]></qid> <attribute><![CDATA[text_input_width]]></attribute> <value><![CDATA[]]></value> </row> <row> <qaid><![CDATA[405]]></qaid> <qid><![CDATA[69]]></qid> <attribute><![CDATA[time_limit]]></attribute> <value><![CDATA[]]></value> </row> <row> <qaid><![CDATA[406]]></qaid> <qid><![CDATA[69]]></qid> <attribute><![CDATA[time_limit_action]]></attribute> <value><![CDATA[1]]></value> </row> <row> <qaid><![CDATA[407]]></qaid> <qid><![CDATA[69]]></qid> <attribute><![CDATA[time_limit_disable_next]]></attribute> <value><![CDATA[0]]></value> </row> <row> <qaid><![CDATA[408]]></qaid> <qid><![CDATA[69]]></qid> <attribute><![CDATA[time_limit_disable_prev]]></attribute> <value><![CDATA[0]]></value> </row> <row> <qaid><![CDATA[409]]></qaid> <qid><![CDATA[69]]></qid> <attribute><![CDATA[time_limit_countdown_message]]></attribute> <value><![CDATA[]]></value> </row> <row> <qaid><![CDATA[410]]></qaid> <qid><![CDATA[69]]></qid> <attribute><![CDATA[time_limit_timer_style]]></attribute> <value><![CDATA[]]></value> </row> <row> <qaid><![CDATA[411]]></qaid> <qid><![CDATA[69]]></qid> <attribute><![CDATA[time_limit_message_delay]]></attribute> <value><![CDATA[]]></value> </row> <row> <qaid><![CDATA[412]]></qaid> <qid><![CDATA[69]]></qid> <attribute><![CDATA[time_limit_message]]></attribute> <value><![CDATA[]]></value> </row> <row> <qaid><![CDATA[413]]></qaid> <qid><![CDATA[69]]></qid> <attribute><![CDATA[time_limit_message_style]]></attribute> <value><![CDATA[]]></value> </row> <row> <qaid><![CDATA[414]]></qaid> <qid><![CDATA[69]]></qid> <attribute><![CDATA[time_limit_warning]]></attribute> <value><![CDATA[]]></value> </row> <row> <qaid><![CDATA[415]]></qaid> <qid><![CDATA[69]]></qid> <attribute><![CDATA[time_limit_warning_display_time]]></attribute> <value><![CDATA[]]></value> </row> <row> <qaid><![CDATA[416]]></qaid> <qid><![CDATA[69]]></qid> <attribute><![CDATA[time_limit_warning_message]]></attribute> <value><![CDATA[]]></value> </row> <row> <qaid><![CDATA[417]]></qaid> <qid><![CDATA[69]]></qid> <attribute><![CDATA[time_limit_warning_style]]></attribute> <value><![CDATA[]]></value> </row> <row> <qaid><![CDATA[418]]></qaid> <qid><![CDATA[69]]></qid> <attribute><![CDATA[time_limit_warning_2]]></attribute> <value><![CDATA[]]></value> </row> <row> <qaid><![CDATA[419]]></qaid> <qid><![CDATA[69]]></qid> <attribute><![CDATA[time_limit_warning_2_display_time]]></attribute> <value><![CDATA[]]></value> </row> <row> <qaid><![CDATA[420]]></qaid> <qid><![CDATA[69]]></qid> <attribute><![CDATA[time_limit_warning_2_message]]></attribute> <value><![CDATA[]]></value> </row> <row> <qaid><![CDATA[421]]></qaid> <qid><![CDATA[69]]></qid> <attribute><![CDATA[time_limit_warning_2_style]]></attribute> <value><![CDATA[]]></value> </row> </rows> </question_attributes> <surveys> <fields> <fieldname>sid</fieldname> <fieldname>admin</fieldname> <fieldname>expires</fieldname> <fieldname>startdate</fieldname> <fieldname>adminemail</fieldname> <fieldname>private</fieldname> <fieldname>faxto</fieldname> <fieldname>format</fieldname> <fieldname>template</fieldname> <fieldname>language</fieldname> <fieldname>additional_languages</fieldname> <fieldname>datestamp</fieldname> <fieldname>usecookie</fieldname> <fieldname>notification</fieldname> <fieldname>allowregister</fieldname> <fieldname>allowsave</fieldname> <fieldname>autonumber_start</fieldname> <fieldname>autoredirect</fieldname> <fieldname>allowprev</fieldname> <fieldname>printanswers</fieldname> <fieldname>ipaddr</fieldname> <fieldname>refurl</fieldname> <fieldname>publicstatistics</fieldname> <fieldname>publicgraphs</fieldname> <fieldname>listpublic</fieldname> <fieldname>htmlemail</fieldname> <fieldname>tokenanswerspersistence</fieldname> <fieldname>assessments</fieldname> <fieldname>usecaptcha</fieldname> <fieldname>usetokens</fieldname> <fieldname>bounce_email</fieldname> <fieldname>attributedescriptions</fieldname> <fieldname>emailresponseto</fieldname> <fieldname>tokenlength</fieldname> </fields> <rows> <row> <sid><![CDATA[46143]]></sid> <admin><![CDATA[Your Name]]></admin> <expires><![CDATA[]]></expires> <startdate><![CDATA[]]></startdate> <adminemail><![CDATA[your@email.org]]></adminemail> <private><![CDATA[Y]]></private> <faxto><![CDATA[]]></faxto> <format><![CDATA[G]]></format> <template><![CDATA[ANX]]></template> <language><![CDATA[en]]></language> <additional_languages><![CDATA[]]></additional_languages> <datestamp><![CDATA[N]]></datestamp> <usecookie><![CDATA[N]]></usecookie> <notification><![CDATA[0]]></notification> <allowregister><![CDATA[N]]></allowregister> <allowsave><![CDATA[Y]]></allowsave> <autonumber_start><![CDATA[0]]></autonumber_start> <autoredirect><![CDATA[N]]></autoredirect> <allowprev><![CDATA[Y]]></allowprev> <printanswers><![CDATA[N]]></printanswers> <ipaddr><![CDATA[N]]></ipaddr> <refurl><![CDATA[N]]></refurl> <publicstatistics><![CDATA[N]]></publicstatistics> <publicgraphs><![CDATA[N]]></publicgraphs> <listpublic><![CDATA[N]]></listpublic> <htmlemail><![CDATA[Y]]></htmlemail> <tokenanswerspersistence><![CDATA[N]]></tokenanswerspersistence> <assessments><![CDATA[N]]></assessments> <usecaptcha><![CDATA[D]]></usecaptcha> <usetokens><![CDATA[N]]></usetokens> <bounce_email><![CDATA[your@email.org]]></bounce_email> <attributedescriptions><![CDATA[]]></attributedescriptions> <emailresponseto><![CDATA[]]></emailresponseto> <tokenlength><![CDATA[15]]></tokenlength> </row> </rows> </surveys> <surveys_languagesettings> <fields> <fieldname>surveyls_survey_id</fieldname> <fieldname>surveyls_language</fieldname> <fieldname>surveyls_title</fieldname> <fieldname>surveyls_description</fieldname> <fieldname>surveyls_welcometext</fieldname> <fieldname>surveyls_endtext</fieldname> <fieldname>surveyls_url</fieldname> <fieldname>surveyls_urldescription</fieldname> <fieldname>surveyls_email_invite_subj</fieldname> <fieldname>surveyls_email_invite</fieldname> <fieldname>surveyls_email_remind_subj</fieldname> <fieldname>surveyls_email_remind</fieldname> <fieldname>surveyls_email_register_subj</fieldname> <fieldname>surveyls_email_register</fieldname> <fieldname>surveyls_email_confirm_subj</fieldname> <fieldname>surveyls_email_confirm</fieldname> <fieldname>surveyls_dateformat</fieldname> </fields> <rows> <row> <surveyls_survey_id><![CDATA[46143]]></surveyls_survey_id> <surveyls_language><![CDATA[en]]></surveyls_language> <surveyls_title><![CDATA[date validation test by Luke]]></surveyls_title> <surveyls_description><![CDATA[]]></surveyls_description> <surveyls_welcometext><![CDATA[]]></surveyls_welcometext> <surveyls_endtext><![CDATA[]]></surveyls_endtext> <surveyls_url><![CDATA[]]></surveyls_url> <surveyls_urldescription><![CDATA[]]></surveyls_urldescription> <surveyls_email_invite_subj><![CDATA[Invitation to participate in survey]]></surveyls_email_invite_subj> <surveyls_email_invite><![CDATA[Dear {FIRSTNAME},<br /><br />You have been invited to participate in a survey.<br /><br />The survey is titled:<br />"{SURVEYNAME}"<br /><br />"{SURVEYDESCRIPTION}"<br /><br />To participate, please click on the link below.<br /><br />Sincerely,<br /><br />{ADMINNAME} ({ADMINEMAIL})<br /><br />----------------------------------------------<br />Click here to do the survey:<br />{SURVEYURL}<br /><br />If you do not want to participate in this survey and don't want to receive any more invitations please click the following link:<br />{OPTOUTURL}]]></surveyls_email_invite> <surveyls_email_remind_subj><![CDATA[Reminder to participate in survey]]></surveyls_email_remind_subj> <surveyls_email_remind><![CDATA[Dear {FIRSTNAME},<br /><br />Recently we invited you to participate in a survey.<br /><br />We note that you have not yet completed the survey, and wish to remind you that the survey is still available should you wish to take part.<br /><br />The survey is titled:<br />"{SURVEYNAME}"<br /><br />"{SURVEYDESCRIPTION}"<br /><br />To participate, please click on the link below.<br /><br />Sincerely,<br /><br />{ADMINNAME} ({ADMINEMAIL})<br /><br />----------------------------------------------<br />Click here to do the survey:<br />{SURVEYURL}<br /><br />If you do not want to participate in this survey and don't want to receive any more invitations please click the following link:<br />{OPTOUTURL}]]></surveyls_email_remind> <surveyls_email_register_subj><![CDATA[Survey registration confirmation]]></surveyls_email_register_subj> <surveyls_email_register><![CDATA[Dear {FIRSTNAME},<br /><br />You, or someone using your email address, have registered to participate in an online survey titled {SURVEYNAME}.<br /><br />To complete this survey, click on the following URL:<br /><br />{SURVEYURL}<br /><br />If you have any questions about this survey, or if you did not register to participate and believe this email is in error, please contact {ADMINNAME} at {ADMINEMAIL}.]]></surveyls_email_register> <surveyls_email_confirm_subj><![CDATA[Confirmation of completed survey]]></surveyls_email_confirm_subj> <surveyls_email_confirm><![CDATA[Dear {FIRSTNAME},<br /><br />This email is to confirm that you have completed the survey titled {SURVEYNAME} and your response has been saved. Thank you for participating.<br /><br />If you have any further questions about this email, please contact {ADMINNAME} at {ADMINEMAIL}.<br /><br />Sincerely,<br /><br />{ADMINNAME}]]></surveyls_email_confirm> <surveyls_dateformat><![CDATA[1]]></surveyls_dateformat> </row> </rows> </surveys_languagesettings> </document> patch04672.patch (1,014 bytes)
Index: qanda.php =================================================================== --- qanda.php (revision 9220) +++ qanda.php (working copy) @@ -154,6 +154,7 @@ // if $currentgid is not null (Group by group survey), the fieldname depends on the groupId function retrieveJSidname($cd,$currentgid=null) { + global $dbprefix, $connect, $dropdownthreshold; if (preg_match("/^\+{0,1}[0-9]+X([0-9]+)X(.*)$/",$cd[2]) == 0) @@ -1549,8 +1550,11 @@ if (trim($qidattributes['dropdown_dates'])!=0) { if (!empty($_SESSION[$ia[1]])) - { - list($currentyear, $currentmonth, $currentdate) = explode('-', $_SESSION[$ia[1]]); + { @list($currentyear, $currentmonth, $currentdate) = explode('-', $_SESSION[$ia[1]]); + if($currentmonth=="") + { + list($currentdate,$currentmonth,$currentyear) = explode('.',$_SESSION[$ia[1]]); + } } else { $currentdate=''; $currentmonth=''; | ||||
Bug heat | 14 | ||||
Complete LimeSurvey version number (& build) | 0000 | ||||
I will donate to the project if issue is resolved | |||||
Browser | |||||
Database type & version | demo server | ||||
Server OS (if known) | demo server | ||||
Webserver software & version (if known) | demo server | ||||
PHP Version | demo server | ||||
I can reproduce the problem. After having gone back to the welcome screen and clicking next to get to the date question, the following errors are shown on top at the date questions: Notice: Undefined offset: 1 in C:\xampp\htdocs\limeSOURCE\limesurvey_svn\qanda.php on line 1572 |
|
Anishseth, could you please post the patch details here or send me a private message on forums? I need to fix this bug in my 1.87ver based survey (I can not upgrade as my code is already customized). Please let me know. Thanks. |
|
Hey Luke, I am uploading the patch here, however it is just a temporary workaround, a proper patch will be committed soon. |
|
anishseth, but when i found 04671 resolving. Seem to work with this one TOO. Now LS don't change $_POST varaible. Can you confirm the resolution in 9259, please. |
|
Hey Shnoulle, I am unable to infer what you wanna say in the first line, As far as the second and third line is concerned, i have checked it and as far as i know it is still not working the way it should in the rev 9259. Correct me if i am wrong.Thanks. |
|
Hi anishseth, sorry, i made an error, i don't read whole bug reprot, and i don't see if we came at start .... Sorry ! |
|
Hey Luke, I am afraid that upgrade is the only option. |
|
anishseth, are you saying that the patch will not be a "one liner" ? |
|
no, i am saying that the patch is based on other changes in 1.90 and cannot be backported (at least not with reasonable effort) |
|
I think I've fixed this in patch 9289. Thibault |
|
Hey Thibault, The loosing date was fixed and committed earlier i think, however the weird date coming out still needs to be fixed, and is not fixed in 9289. Anish |
|
Fixed in rev 9294 |
|
1.90plus version released. |
|
Date Modified | Username | Field | Change |
---|---|---|---|
2010-10-12 20:36 | luke | New Issue | |
2010-10-12 21:13 | luke | File Added: date_fields_test.lss | |
2010-10-14 09:20 |
|
Assigned To | => user7171 |
2010-10-14 09:20 |
|
Status | new => assigned |
2010-10-14 15:07 | Mazi | Note Added: 13179 | |
2010-10-14 18:22 |
|
File Added: patch04672.patch | |
2010-10-14 22:52 | c_schmitz | File Deleted: patch04672.patch | |
2010-10-15 00:42 | luke | Issue Monitored: luke | |
2010-10-15 00:44 | luke | Note Added: 13196 | |
2010-10-15 08:55 |
|
File Added: patch04672.patch | |
2010-10-15 08:56 |
|
Note Added: 13197 | |
2010-10-15 08:56 |
|
Note Edited: 13197 | |
2010-10-16 21:27 | DenisChenu | Note Added: 13215 | |
2010-10-16 21:27 | DenisChenu | Status | assigned => resolved |
2010-10-16 21:27 | DenisChenu | Fixed in Version | => 1.90+ |
2010-10-16 21:27 | DenisChenu | Resolution | open => fixed |
2010-10-16 23:13 |
|
Note Added: 13220 | |
2010-10-16 23:17 | c_schmitz | Status | resolved => assigned |
2010-10-18 12:54 | DenisChenu | Note Added: 13230 | |
2010-10-18 17:11 |
|
Note Added: 13232 | |
2010-10-18 18:39 | luke | Note Added: 13234 | |
2010-10-20 13:29 |
|
Note Added: 13288 | |
2010-10-20 13:54 | c_schmitz | Note Edited: 13288 | |
2010-10-20 22:14 | lemeur | Note Added: 13292 | |
2010-10-20 22:14 | lemeur | Status | assigned => feedback |
2010-10-21 16:09 |
|
Note Added: 13300 | |
2010-10-21 21:20 | c_schmitz | Note Added: 13302 | |
2010-10-21 21:20 | c_schmitz | Status | feedback => resolved |
2010-10-21 21:20 | c_schmitz | Assigned To | user7171 => c_schmitz |
2010-10-24 17:21 | c_schmitz | Note Added: 13325 | |
2010-10-24 17:21 | c_schmitz | Status | resolved => closed |
2010-10-25 00:18 | c_schmitz | Category | Survey at Runtime => Survey taking |
2021-08-03 18:52 | guest | Bug heat | 12 => 14 |