Don't write multiple rewrite rule blocks to htaccess. fixes #1661

git-svn-id: http://svn.automattic.com/wordpress/trunk@2886 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
ryan 2005-09-16 03:25:22 +00:00
parent a691288ccd
commit dd14bda3ae
1 changed files with 2 additions and 2 deletions

View File

@ -963,9 +963,9 @@ function insert_with_markers($filename, $marker, $insertion) {
if ($markerdata) {
$state = true;
foreach($markerdata as $markerline) {
if (strstr($markerline, "# BEGIN {$marker}\n")) $state = false;
if (strstr($markerline, "# BEGIN {$marker}")) $state = false;
if ($state) fwrite($f, "{$markerline}\n");
if (strstr($markerline, "# END {$marker}\n")) {
if (strstr($markerline, "# END {$marker}")) {
fwrite($f, "# BEGIN {$marker}\n");
if(is_array($insertion)) foreach($insertion as $insertline) fwrite($f, "{$insertline}\n");
fwrite($f, "# END {$marker}\n");