Linux - ServerThis forum is for the discussion of Linux Software used in a server related context.
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
I've written my own authentication through PHP using MySQL. I've used auto_prepend_file and auto_append_file to include my authentication on every html page, as well as putting a banner and menu on all the pages on the server. This works well for the html content, since content contributors don't have to include the standard code. If the contributed html is too complex. however, it doesn't work well. Long term, I need to go more toward a Content Management System, but that's a longer story.
I have the same concern as original poster; How do I use PHP authentication to limit access to non-HTML documents? I can use rewrite rules to change a request for other files to a php script, but I don't quite understand how to setup the headers and push the non-HTML (binary?) data.