View Issue Details

This bug affects 1 person(s).
 6
IDProjectCategoryView StatusLast Update
05043Bug reportsImport/Exportpublic2011-04-11 11:30
Reporterdionet Assigned ToDenisChenu  
PrioritynormalSeverityminor 
Status closedResolutionfixed 
Product Version1.91RC5 
Fixed in Version1.91RC6 
Summary05043: HTML UI defect when importing surveys
Description

The import survey function that displayed a message when the import failed wasn't implemented in the HTTP part, so the page looked broken.

I've attached a patch that fixes the problem.

Steps To Reproduce

Open Administration Panel, create a new survey, click Import and select an invalid file.

TagsNo tags attached.
Attached Files
htmlfix.diff (667 bytes)   
Index: admin/importsurvey.php
===================================================================
--- admin/importsurvey.php	(revision 9890)
+++ admin/importsurvey.php	(working copy)
@@ -110,6 +110,13 @@
         unlink($sFullFilepath);    
     }
 }
+elseif (isset($bImportFailed) && $bImportFailed==true && $importingfrom == "http")
+{
+    $importsurvey .= "<strong>".$clang->gT("Error")."</strong><br />\n";
+    $importsurvey .= $clang->gT("Import failed. You specified an invalid file.")."\n";
+    $importsurvey .= "</div><br />\n";
+    
+}
 elseif (isset($bImportFailed) && $bImportFailed==true)
 {
     echo "\n".$clang->gT("Error")."\n\n";
htmlfix.diff (667 bytes)   
Bug heat6
Complete LimeSurvey version number (& build)9890
I will donate to the project if issue is resolvedNo
Browser
Database type & versionMySQL 5.1.49
Server OS (if known)Ubuntu 10.10
Webserver software & version (if known)Apache/2.2.16
PHP Version5.3.3

Users monitoring this issue

There are no users monitoring this issue.

Activities

Mazi

Mazi

2011-03-21 00:34

updater   ~14482

Shnoulle, can you check the problem and attached patch?

DenisChenu

DenisChenu

2011-03-21 08:52

developer   ~14494

OK,

And have some other correction for HTML alert (replacing alert by the new html .

I trye to look for this thurday.

DenisChenu

DenisChenu

2011-03-27 16:08

developer   ~14557

Hello,

I look for the patch , and this one work good, but i think there are some problem.

Actually , we have http_importsurvey.php with the import function, and at the end of this one : include("importsurvey.php");

I don't understand....

I can put all import functionnality in http_importsurvey.php, and remove importsurvey.php .
OR
Put the function in importsurvey.php , and after construct the page in html with a returned array : more long and complex.

And there are another problem:
<div class='messagebox ui-corner-all'> start in http_importsurvey.php and end in importsurvey.php .

I think the best is to put whole import survey traitment in http_importsurvey.php.

Carsten, i need your advice, after you can put it to me.

c_schmitz

c_schmitz

2011-03-29 19:34

administrator   ~14603

Shnoulle, I agree. PLease go ahead.

DenisChenu

DenisChenu

2011-04-03 18:31

developer   ~14637

Fixed in 9946 and 9948 for dev version

Maybe had to remove or review importsurvey.php file to be standalone

c_schmitz

c_schmitz

2011-04-11 11:30

administrator   ~14752

1.91RC6 released.

Issue History

Date Modified Username Field Change
2011-03-19 17:16 dionet New Issue
2011-03-19 17:16 dionet File Added: htmlfix.diff
2011-03-21 00:33 Mazi Assigned To => DenisChenu
2011-03-21 00:33 Mazi Status new => assigned
2011-03-21 00:34 Mazi Note Added: 14482
2011-03-21 08:52 DenisChenu Note Added: 14494
2011-03-27 16:08 DenisChenu Note Added: 14557
2011-03-27 16:08 DenisChenu Assigned To DenisChenu => c_schmitz
2011-03-29 19:34 c_schmitz Note Added: 14603
2011-03-29 19:35 c_schmitz Assigned To c_schmitz => DenisChenu
2011-04-03 18:31 DenisChenu Note Added: 14637
2011-04-03 18:31 DenisChenu Status assigned => resolved
2011-04-03 18:31 DenisChenu Fixed in Version => 1.91RC6
2011-04-03 18:31 DenisChenu Resolution open => fixed
2011-04-11 11:30 c_schmitz Note Added: 14752
2011-04-11 11:30 c_schmitz Status resolved => closed