View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
05071 | Bug reports | Import/Export | public | 2011-03-31 21:34 | 2011-03-31 21:54 |
Reporter | csnook | Assigned To | c_schmitz | ||
Priority | normal | Severity | minor | ||
Status | closed | Resolution | fixed | ||
Product Version | 1.90+ | ||||
Fixed in Version | 2.00a1 | ||||
Summary | 05071: xmlwriter error should be reported at install time, be more informative, and use proper mime type | ||||
Description | When a user exports a survey on a system that doesn't have a working php XMLwriter class, Limesurvey delivers the error message with the mimetype appropriate for a correct Limesurvey export file, causing the browser to save the file rather than display the error message. This results in silent backup failure. When a user attempts to copy a survey on a system that doesn't have libxml2 installed, they do see the error saying that their PHP build doesn't support XMLwriter, even if XMLwriter is in fact supported in their build, as is the default on almost all modern distributions. This leads troubleshooting down the wrong path. When php is initialized at web server startup, php checks to see if xmlwriter can be initialized. If libxml2 is not installed, php removes the xmlwriter info from its configuration state. phpinfo() will actually lie and say that php was configured with --disable-xmlwriter, even if it was actually built with --enable-xmlwriter=shared. Once the administrator has figured out that libxml2 is needed and installed it, the same error message will appear until the web server is restarted, leading the administrator to think that something is more fundamentally wrong with the xmlwriter class. Since php -i shows --enable-xmlwriter=shared, they may think that they've already done all that should be necessary to enable it. Server restarts are a big deal in many environments, and not done lightly, so the administrator may not be inclined to do it unless they know it's necessary. | ||||
Steps To Reproduce | 1) Install a minimal CentOS system, plus php, httpd, and mysql-server | ||||
Additional Information | The installer should check for functioning xmlwriter support and warn at install time if it's absent, so this problem doesn't suddenly crop up long after Limesurvey is believed to be up and running, particularly given that it allows for silent user-level backup failure. Returning the error message with the export file mimetype is a bug. When an error like that occurs, the user should be directed to an html error page with the appropriate mimetype to cause it to be displayed in the browser, rather than returned in what the user thinks is an XML file that they have no reason to browse. The error message ambiguity is more PHP's fault for lying about config info, not Limesurvey's fault, but Limesurvey could save administrators a lot of headache with a more helpful error message. It's particularly annoying because it's possible to encounter this problem after Limesurvey has been up and running for a while and it's been deployed. | ||||
Tags | No tags attached. | ||||
Bug heat | 0 | ||||
Complete LimeSurvey version number (& build) | 9642 | ||||
I will donate to the project if issue is resolved | Yes | ||||
Browser | Firefox 3.6.16 | ||||
Database type & version | mysql-server-5.0.77-4.el5_5.4 | ||||
Server OS (if known) | CentOS 5.5 | ||||
Webserver software & version (if known) | httpd-2.2.3-43.el5.centos.3 | ||||
PHP Version | php-5.1.6-27.el5_5.3 | ||||