Support Joomla!

1.5 Template Project

The Joomla! Documentation Working Group is running a project to develop detailed reference and tutorial material on Joomla! 1.5 templates.  There is a project page on the documentation wiki where you can see the work in progress and help us by contributing your knowledge.

Who's Online

We have 106 guests online

Help Site License

The Joomla! Help Site content is copyright © 2005 - 2008 by the individual contributors and can be used in accordance with the Creative Commons License, Attribution NonCommercial ShareAlike 2.5. Some parts of this website may be subject to other licenses.
Home arrow FAQs

APACHE: How do I change PHP settings using .htaccess?
Author(s):Rliskey
Experience level:Beginner
Contributors:Joomla! version:1.0
Date added:Monday, 26 March 2007Date last changed:Friday, 06 July 2007
 

Introduction
This FAQ explains how to set boolean PHP configuration directives using php_flag. The format for php_flag is: php_flag name on|off

Directions
1. Open the .htaccess file located in your site's home directory, or if you don't have one, create a blank one now.

2. Add any of the following code samples to your .htaccess file, each on it's own line.

Prevent Global Variable Injection Attacks

php_flag register_globals off


Prevent Cross Site Scripting (XSS) Attacks

php_flag allow_url_fopen off


Prevent Code Injection Attacks

php_flag magic_quotes_gpc on

Note that although the magic_quotes_gpc directive adds a layer of security, for performance reasons it is not considered a best practice. If you have verified that your site correctly filters and validates all user data (and every production site really should), then there is no need to add this directive. If you have any doubt, add it.

3. Save the .htaccess file in your site's home directory.

4. Test your site's front end and back end.


Last Updated Friday, 06 July 2007
Tags
< Prev   Next >

Powered by EasyFAQ © 2006 Joomla-addons.org