diff options
author | Scott Ullrich <sullrich@pfsense.org> | 2005-02-25 23:43:10 +0000 |
---|---|---|
committer | Scott Ullrich <sullrich@pfsense.org> | 2005-02-25 23:43:10 +0000 |
commit | 98b779400b1c27851ebfefcb599ec24a7de749e3 (patch) | |
tree | 8c1f0bb85f6748fa24f60d3d35a93a9bd0a088de /etc | |
parent | e3f41a28e4616e6c82923f560989a36a5447e8a6 (diff) | |
download | pfsense-98b779400b1c27851ebfefcb599ec24a7de749e3.zip pfsense-98b779400b1c27851ebfefcb599ec24a7de749e3.tar.gz |
If line begins with #, unset it
Diffstat (limited to 'etc')
-rw-r--r-- | etc/inc/pfsense-utils.inc | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/etc/inc/pfsense-utils.inc b/etc/inc/pfsense-utils.inc index 42c3e1b..5128eca 100644 --- a/etc/inc/pfsense-utils.inc +++ b/etc/inc/pfsense-utils.inc @@ -77,6 +77,12 @@ function return_filename_as_array($filename) { if(!file_exists($filename)) return $file; $text = return_filename_as_string($filename); $text_split = split("\n", $text); + $counter = 0; + foreach($text_split as $line) { + if(strpos($line, "#") == 0) + unset($text_split($counter)); + $counter++; + } return $text_split; } |