diff --git a/html/cgi-bin/ids.cgi b/html/cgi-bin/ids.cgi
index 1cf5b8dec..5d2da2185 100644
--- a/html/cgi-bin/ids.cgi
+++ b/html/cgi-bin/ids.cgi
@@ -96,7 +96,7 @@ if (-e "/etc/snort/snort.conf") {
open(FILE, "/etc/snort/snort.conf") or die 'Unable to read snort config file.';
@snortconfig = ;
close(FILE);
- open(FILE, ">/etc/snort/snort.conf") or die 'Unable to write snort config file.';
+ open(FILE, "/etc/snort/snort.conf") or die 'Unable to write snort config file.';
my @rules = `cd /etc/snort/rules/ && ls *.rules`; # With this loop the rule might be display with correct rulepath set
foreach (@rules) {