I want to turn off PHP's magic quotes. I don't have access to php.ini.
When I tried to add php_flag magic_quotes_gpc off
to my .htaccess file, I get a 500 internal server error. This is what my .htaccess file looks like:
AddType x-mapp-php5 .php
php_flag magic_quotes_gpc off
Then I tried to use ini_set('magic_quotes_gpc', 'O')
, but that had no effect.
How do I turn magic quotes off?
======================== =============== MY SOLUTION ============================ (rename your php.ini to php5.ini)
and in the top (!), add these:
then in .htaccess, add this (in the top):
p.s. change
/home/your_path/to/
correctly (you can see that path by executing the<?php phpinfo(); ?>
command from a typical .php file.)