View Issue Details
| ID | Project | Category | View Status | Date Submitted | Last Update |
|---|---|---|---|---|---|
| 04956 | Bug reports | Survey taking | public | 2011-02-15 16:41 | 2011-05-04 19:51 |
| Reporter | tpartner | Assigned To | texens | ||
| Priority | normal | Severity | minor | ||
| Status | closed | Resolution | fixed | ||
| Product Version | 1.91RC3 | ||||
| Target Version | 1.91RC4 | Fixed in Version | 1.91 | ||
| Summary | 04956: Problems with the file upload user interface | ||||
| Description | 1) Cannot delete uploaded file - after uploading a file, then trying to delete it, I get an error "Warning: fopen(tmp/upload/) [function.fopen]: failed to open stream: No such file or directory in C:\xampp\htdocs\limeSurveyTest\delete.php on line 55" 2) After uploading a file, moving on to another group and then returning to the file-upload group, the table displaying the file details does not appear. It only re-appears after opening the modaldialog again. 3) There are some alerts that I'm not sure should appear - in modaldialog.js, lines 93, 107, 111 | ||||
| Tags | No tags attached. | ||||
| Attached Files | 04956_stable_mod.diff (1,440 bytes)
Index: qanda.php
===================================================================
--- qanda.php (revision 10017)
+++ qanda.php (working copy)
@@ -3849,6 +3849,18 @@
});
</script>';
+ $answer .= '<script type="text/javascript">
+ $(document).ready(function(){
+ var fieldname = "'.$ia[1].'";
+ var filecount = $("#"+fieldname+"_filecount").val();
+ var json = $("#"+fieldname).val();
+ var show_title = "'.$qidattributes["show_title"].'";
+ var show_comment = "'.$qidattributes["show_comment"].'";
+ var pos = "'.($pos?1:0).'";
+ displayUploadedFiles(json, filecount, fieldname, show_title, show_comment, pos);
+ });
+ </script>';
+
$inputnames[] = $ia[1];
$inputnames[] = $ia[1]."_filecount";
return array($answer, $inputnames);
Index: scripts/modaldialog.js
===================================================================
--- scripts/modaldialog.js (revision 10017)
+++ scripts/modaldialog.js (working copy)
@@ -121,7 +121,13 @@
var jsonobj;
var i;
- if (jsonstring !== '')
+ if (jsonstring == '[]') {
+ var display ='';
+ $('#'+fieldname+'_uploadedfiles').html(display);
+ return;
+ }
+
+ if (jsonstring !== '')
{
jsonobj = eval('(' + jsonstring + ')');
var display = '<table width="100%"><tr><th align="center" width="20%"> </th>'; | ||||
| Bug heat | 10 | ||||
| Complete LimeSurvey version number (& build) | 9786 | ||||
| I will donate to the project if issue is resolved | No | ||||
| Browser | FireFox | ||||
| Database type & version | mySQL - 5.1.41 | ||||
| Server OS (if known) | Win 7 | ||||
| Webserver software & version (if known) | Apache - 2.2.14 | ||||
| PHP Version | PHP - 5.3.1 | ||||
|
Hi texens, I thought it would be easier to group these together but I can move them into separate bugs if you like. Let me know if you need more details. |
|
|
I also ran into issue #1, didn't try issue #2 and #3 yet. Its easier to have them all at one place :) If I need any more details, I'll let you know. Thanks for testing :) There was a major code overhaul last week to overcome a design issue (that resulted in failure when we have more than one question on the same page) and a couple things are broken right now :| |
|
|
What's the status on this? Didn't you resolve it already? If yes, please set to resolved. |
|
|
I don't know if it corresponds on what you wanted to do but I really need the file upload so I have done the following modification In uploader.js In modalDialog.js Think it works ... |
|
|
Issues 1 and 3 mentioned above in the description - fixed in r9979. |
|
|
Hi texens, I have uploaded a diff file to correct two issues :
If anybody can review the file, it would be great :-) P.S. @texens, shouldn't variables pos, show_title, show_comment, maxfiles, filecount and many other be integers(they are string currently, i guess). |
|
|
Issue fixed in r10028. |
|
| Date Modified | Username | Field | Change |
|---|---|---|---|
| 2011-02-15 16:41 | tpartner | New Issue | |
| 2011-02-15 16:42 | tpartner | Assigned To | => texens |
| 2011-02-15 16:42 | tpartner | Status | new => assigned |
| 2011-02-15 16:44 | tpartner | Note Added: 14184 | |
| 2011-02-16 14:28 | texens | Note Added: 14201 | |
| 2011-03-08 14:57 | c_schmitz | Note Added: 14337 | |
| 2011-03-23 11:16 | bquiller | Note Added: 14523 | |
| 2011-04-12 14:32 | texens | Note Added: 14798 | |
| 2011-04-22 17:27 |
|
File Added: 04956_stable_mod.diff | |
| 2011-04-22 17:35 |
|
Note Added: 14856 | |
| 2011-05-01 17:58 | texens | Note Added: 14897 | |
| 2011-05-01 17:58 | texens | Status | assigned => resolved |
| 2011-05-01 17:58 | texens | Resolution | open => fixed |
| 2011-05-04 19:51 | c_schmitz | Status | resolved => closed |
| 2011-05-04 19:51 | c_schmitz | Fixed in Version | => 1.91 |