News Feed
Jobs Feed
Sections




News Archive
Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

Jani Hartikainen's Blog:
Sending files better Apache mod_xsendfile and PHP
March 06, 2009 @ 12:57:34

Jani Hartikainen has a suggestions of a way to "send files better" in his latest post by using the mod_xsendfile module for Apache and a bit of PHP.

I have previously written a quick post on making files downloadable through PHP scripts. The example in the post reads the file itself into a variable, and as pointed out in the comments, it's not necessarily a very good idea especially if you deal with large files. Recently at work, we needed a reliable way to send files to users' browser, and I decided to take a look at mod_xsendfile, as suggested by Tom Graham.

He starts with some of the benefits of using the xsendfile method over other, more traditional ways. Moving on, he gets to the good stuff - download, installation and a code example of how to use the module (via a X-Sendfile header).

3 comments voice your opinion now!
send file better module apache xsendfile example


blog comments powered by Disqus

Similar Posts

Kristina Chodorow's Blog: Writing a PHP Extension (Four Part Series)

Padraic Brady's Blog: Example Zend Framework Blog Application Tutorial: Parts 1-8 Revisited

PHPClasses.org: 26 Ways to Show that PHP Can Be Better Than PHP

Ben Ramsey\'s Blog: Peruser MPM for Apache

Matthew Weier O'Phinney's Blog: Module Bootstraps in Zend Framework: Do's and Don'ts


Community Events











Don't see your event here?
Let us know!


facebook application framework opinion podcast unittest hack security introduction hhvm support package release composer performance install component language symfony2 database

All content copyright, 2014 PHPDeveloper.org :: info@phpdeveloper.org - Powered by the Solar PHP Framework