'http'/", "'auth_type' => 'http_auth'", $text, 1); $text = preg_replace("/'auth_type' => 'form'/", "'auth_type' => 'http_auth'", $text, 1); $text = preg_replace("/'http_auth_auto_register' => true/", "'http_auth_auto_register' => false", $text, 1); file_put_contents($path, $text); echo "ok\n";