Giraffex

Registered
Sep 25, 2014
1
0
1
cPanel Access Level
Website Owner
Hi
How I can magic_quotes_gpc turn off? I tryed this command in .htaccess
php_flag magic_quotes_gpc off but it not works.
 

SteveHE

Registered
Oct 23, 2015
3
0
1
UK
cPanel Access Level
Root Administrator
Hi. Just to say that magic_quotes_gpc isn't there to switch on/off! See image below. Any help appreciated as I want to switch it off. Thanks.upload_2015-10-23_10-2-8.png
 
Last edited by a moderator:
Oct 10, 2015
15
1
3
Alabama, United States
cPanel Access Level
Root Administrator
Hey SteveHE,

You should be able to disable it from the PHP ini file. The ini configuration file is typically located here: /usr/local/lib/php.ini although you can confirm via the command line:

Code:
# php --ini
Configuration File (php.ini) Path: /usr/local/lib
Loaded Configuration File:         /usr/local/lib/php.ini
Scan for additional .ini files in: (none)
Additional .ini files parsed:      (none)
Find the line with 'magic_quotes_gpc' in the ini file. If there isn't one, try adding this to the end:

Code:
magic_quotes_gpc = off
Once you save that change, make sure you restart apache.

Code:
# /scripts/restartsrv_apache
Try that out and let me know the results.
 

SteveHE

Registered
Oct 23, 2015
3
0
1
UK
cPanel Access Level
Root Administrator
Thanks David. I've done what you suggest and that seems to be working fine with no apparent consequences! We're monitoring it in case there's some code that falls down because of it, but so far so good.
Thanks again!