On Friday 19 April 2002 15:58, Erik Price wrote: > On Friday, April 19, 2002, at 04:10 AM, Jacob Wyke wrote: > > Why use .inc as a file extenstion when you can use .php ?? > > What are the advantages/disadvantages to using .inc? > > Is one more secure? > > Which is faster? > > Which is consider a better pratice? > > It's just to help me organize which files I use as included files (.inc) > and which files are actual PHP scripts that can be requested with a URI > (.php). > > Also, I set an Apache directive to refuse requests for any file with the > .inc extension, so my database connection info, password, etc is > (theoretically) safe from being served directly. > > > Erik
Those files should be placed outside DocumentRoot (if you control the server). Then set include_path in php.ini to include that dir, and you're done. No need to rely on apache for this. -- Meir Kriheli -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php