| 제목 | lib zip질문이요~ | ||
|---|---|---|---|
| 글쓴이 | 유승민 | 작성시각 | 2013/06/04 11:33:33 | 
|  | |||
| $folder = $this->input->post('folder', true); $path = '/static/img/photoGallery/'.$folder; $this->zip->read_dir($path); // Download the file to your desktop. Name it "my_backup.zip" $this->zip->download($folder.'.zip'); $path는 맞는 경로 들어가구요.. 근데 다운로드가 안되네용! 해당 디렉토리 퍼미션은 777입니다. 보니까 | |||
| 다음글 | frameset으로 나눠진 페이지를 호출하려면? (1) | ||
| 이전글 | hook 에서 에러처리 질문드립니다. (1) | ||
| 
                                변종원(웅파)
                                /
                                2013/06/04 11:58:43 /
                                추천
                                0
                             | 
| 
                                유승민
                                /
                                2013/06/04 13:24:56 /
                                추천
                                0
                             
                                ci log 확인해봤는데 별 다른 에러는 없네요.. 아마도 ajax로 다운로드 부분을 실행시켜서 발생하는 문제가 아닐까 싶네요.. 컨트롤러 호출하는 ajax부분 $.ajax({     type : "POST",     url : (baseURL + URL),     data : {"folder" : this.value},     dataType : "json",     contentType : "application/x-www-form-urlencoded;charset=UTF-8",     success : function(data){      console.log(data);     }    }); 호출 된 컨트롤러부분 $folder = $this->input->post('folder', true);   $path = 'static/img/photoGallery/'.$folder.'/';   $this->zip->read_dir($path);   // Download the file to your desktop. Name it "my_backup.zip"   $this->zip->download($folder.'.zip'); 다운로드 헬퍼 확인해보니까 헤더타입 변경해서 파일 다운로드 시키는거같은데.. 맞나요?? | 
| 
                                유승민
                                /
                                2013/06/04 13:55:36 /
                                추천
                                0
                             
                                 ajax부분 제거하고 submit으로 수정하였습니다. 감사합니다. | 
ci log 보세요.
해당 페이지에서 다른 출력이 있는지도 보시구요. 다운로드라 다른 출력이 있으면 에러 납니다.