CodeIgniter Forums
How to download dxf files(drawing files) using php - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20)
+--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23)
+--- Thread: How to download dxf files(drawing files) using php (/showthread.php?tid=41683)



How to download dxf files(drawing files) using php - El Forum - 05-13-2011

[eluser]JasmineFlower[/eluser]
hi,

In my codeigniter having folder(Fence). In one of my php page displays the folder(Fence) files.I gave a link for all these files.I need to download these files with Save As dialog box by click the link.the file format is .dxf format that means AUTOCAD drawing files.

How can i download these files ?


How to download dxf files(drawing files) using php - El Forum - 05-14-2011

[eluser]InsiteFX[/eluser]
These would need to be added to the application/config/mimes.php file.
Also you may need to have your hosting provider add these on the server mime types.
Code:
'dwf' => array('drawing/x-dwf', 'model/vnd.dwf'),
'dwg' => array('application/acad', 'image/vnd.dwg', 'image/x-dwg'),
'dxf' => array('application/dxf', 'image/vnd.dwg', 'image/x-dwg'),
// if last in the array remove the last comma!

InsiteFX


How to download dxf files(drawing files) using php - El Forum - 05-14-2011

[eluser]toopay[/eluser]
After that, you can use download helper : take a look at User Guide