Currently, I am running CentOS 7 with php 7. For the life of me, I can't get mod_rewrite working.
I am testing by using this code
if (function_exists("apache_get_modules")) {
$modules = apache_get_modules();
$mod_rewrite = in_array("mod_rewrite",$modules);
if($mod_rewrite)
{
$result[] = '<span class="label label-success"><i class="icon-ok icon-white"></i> mod_rewrite is enabled</span>';
$score++;
}
else
$result[] = '<span class="label label-warning"><i class="icon-remove icon-white"></i> mod_rewrite is not enabled</span>';
}
else
$result[] = '<span class="label label-warning"><i class="icon-remove icon-white"></i> mod_rewrite is not enabled</span>';
And it show "Mod_Rewrite is not enabled"
Eventhough I have added AllowOverride All to my Virtual Host in httpd.conf file
<Directory "/home/mailingmm/public_html">
AllowOverride All
SSILegacyExprParser On
</Directory>
Could you show me how to enable mod_rewrite? and how to test if mod_rewrite is on?
Thanks